* [PATCH]FPU context corrupted after resume
@ 2005-09-15 2:44 Shaohua Li
0 siblings, 0 replies; only message in thread
From: Shaohua Li @ 2005-09-15 2:44 UTC (permalink / raw)
To: lkml; +Cc: akpm, Pavel Machek
Hi,
mxcsr_feature_mask_init isn't needed in suspend/resume time (we can use boot
time mask). And actually it's harmful, as it clear task's saved fxsave in resume.
This bug is widely seen by users using zsh.
Signed-off-by: Shaohua Li<shaohua.li@intel.com>
---
linux-2.6.13-root/arch/i386/power/cpu.c | 1 -
linux-2.6.13-root/arch/x86_64/kernel/suspend.c | 1 -
2 files changed, 2 deletions(-)
diff -puN arch/i386/power/cpu.c~fpu_reinit_after_resume arch/i386/power/cpu.c
--- linux-2.6.13/arch/i386/power/cpu.c~fpu_reinit_after_resume 2005-09-14 09:35:13.000000000 +0800
+++ linux-2.6.13-root/arch/i386/power/cpu.c 2005-09-14 11:00:55.000000000 +0800
@@ -74,7 +74,6 @@ do_fpu_end(void)
/* restore FPU regs if necessary */
/* Do it out of line so that gcc does not move cr0 load to some stupid place */
kernel_fpu_end();
- mxcsr_feature_mask_init();
}
diff -puN arch/x86_64/kernel/suspend.c~fpu_reinit_after_resume arch/x86_64/kernel/suspend.c
--- linux-2.6.13/arch/x86_64/kernel/suspend.c~fpu_reinit_after_resume 2005-09-14 11:02:21.000000000 +0800
+++ linux-2.6.13-root/arch/x86_64/kernel/suspend.c 2005-09-14 11:02:41.000000000 +0800
@@ -82,7 +82,6 @@ do_fpu_end(void)
/* restore FPU regs if necessary */
/* Do it out of line so that gcc does not move cr0 load to some stupid place */
kernel_fpu_end();
- mxcsr_feature_mask_init();
}
void __restore_processor_state(struct saved_context *ctxt)
_
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2005-09-15 2:38 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-09-15 2:44 [PATCH]FPU context corrupted after resume Shaohua Li
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.