Home Home > GIT Browse > SLE11-SP4
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJiri Slaby <jslaby@suse.cz>2018-06-14 15:26:36 +0200
committerJiri Slaby <jslaby@suse.cz>2018-06-14 15:26:36 +0200
commit968a7efc366899d2386318ccfa98eb26bd1ed7c0 (patch)
treefe01af5edb0e16cc4ca4e1379e75b0671b058bcb
parent8b7370de41dccbeaba80e111eabaa40211196693 (diff)
x86-non-upstream-eager-fpu 32bit fix (bnc#1087086
CVE-2018-3665). suse-commit: 027b03e5dccb40c0ce150e3852ef5b9591aaed56
-rw-r--r--arch/x86/kernel/i387.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/arch/x86/kernel/i387.c b/arch/x86/kernel/i387.c
index 858b995f18bf..81f6dd569318 100644
--- a/arch/x86/kernel/i387.c
+++ b/arch/x86/kernel/i387.c
@@ -585,7 +585,7 @@ int save_i387_xstate_ia32(void __user *buf)
* This will cause a "finit" to be triggered by the next
* attempted FPU operation by the 'current' process.
*/
- clear_used_math();
+ drop_init_fpu(tsk);
if (!HAVE_HWFP) {
return fpregs_soft_get(current, NULL,
@@ -682,10 +682,7 @@ int restore_i387_xstate_ia32(void __user *buf)
clear_fpu(tsk);
if (!buf) {
- if (used_math()) {
- clear_fpu(tsk);
- clear_used_math();
- }
+ drop_init_fpu(tsk);
return 0;
} else