Unverified Commit 34c4be6c authored by openeuler-ci-bot's avatar openeuler-ci-bot Committed by Gitee
Browse files

!7226 x86/fpu: Invalidate FPU state correctly on exec()

parents 720afbe5 5b2841c2
Loading
Loading
Loading
Loading
+1 −2
Original line number Diff line number Diff line
@@ -19,8 +19,7 @@
 * FPU state for a task MUST let the rest of the kernel know that the
 * FPU registers are no longer valid for this task.
 *
 * Either one of these invalidation functions is enough. Invalidate
 * a resource you control: CPU if using the CPU for something else
 * Invalidate a resource you control: CPU if using the CPU for something else
 * (with preemption disabled), FPU for the current task, or a task that
 * is prevented from running by the current task.
 */
+1 −1
Original line number Diff line number Diff line
@@ -659,7 +659,7 @@ static void fpu_reset_fpregs(void)
	struct fpu *fpu = &current->thread.fpu;

	fpregs_lock();
	fpu__drop(fpu);
	__fpu_invalidate_fpregs_state(fpu);
	/*
	 * This does not change the actual hardware registers. It just
	 * resets the memory image and sets TIF_NEED_FPU_LOAD so a