diff options
Diffstat (limited to 'arch/x86')
-rw-r--r-- | arch/x86/kernel/i387_64.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/arch/x86/kernel/i387_64.c b/arch/x86/kernel/i387_64.c index 56c1f11471..bfaff28fb1 100644 --- a/arch/x86/kernel/i387_64.c +++ b/arch/x86/kernel/i387_64.c | |||
@@ -92,13 +92,14 @@ int save_i387(struct _fpstate __user *buf) | |||
92 | if (task_thread_info(tsk)->status & TS_USEDFPU) { | 92 | if (task_thread_info(tsk)->status & TS_USEDFPU) { |
93 | err = save_i387_checking((struct i387_fxsave_struct __user *)buf); | 93 | err = save_i387_checking((struct i387_fxsave_struct __user *)buf); |
94 | if (err) return err; | 94 | if (err) return err; |
95 | task_thread_info(tsk)->status &= ~TS_USEDFPU; | ||
95 | stts(); | 96 | stts(); |
96 | } else { | 97 | } else { |
97 | if (__copy_to_user(buf, &tsk->thread.i387.fxsave, | 98 | if (__copy_to_user(buf, &tsk->thread.i387.fxsave, |
98 | sizeof(struct i387_fxsave_struct))) | 99 | sizeof(struct i387_fxsave_struct))) |
99 | return -1; | 100 | return -1; |
100 | } | 101 | } |
101 | return 1; | 102 | return 1; |
102 | } | 103 | } |
103 | 104 | ||
104 | /* | 105 | /* |