summaryrefslogtreecommitdiffstats
path: root/arch/x86/kernel/signal.c
diff options
context:
space:
mode:
authorIngo Molnar <mingo@kernel.org>2015-04-30 07:12:46 +0200
committerIngo Molnar <mingo@kernel.org>2015-05-19 15:48:05 +0200
commitfbce7782467553d09cfde39473d23bde4ad78270 (patch)
tree80010c081a5ebf198ebdf0bf2bd8bceb93b03e8f /arch/x86/kernel/signal.c
parent82c0e45eb5c839a8cee3d8d8a82d0592c4f42773 (diff)
downloadop-kernel-dev-fbce7782467553d09cfde39473d23bde4ad78270.zip
op-kernel-dev-fbce7782467553d09cfde39473d23bde4ad78270.tar.gz
x86/fpu: Merge fpu__reset() and fpu__clear()
With recent cleanups and fixes the fpu__reset() and fpu__clear() functions have become almost identical in functionality: the only difference is that fpu__reset() assumed that the fpstate was already active in the eagerfpu case, while fpu__clear() activated it if it was inactive. This distinction almost never matters, the only case where such fpstate activation happens if if the init thread (PID 1) gets exec()-ed for the first time. So keep fpu__clear() and change all fpu__reset() uses to fpu__clear() to simpify the logic. ( In a later patch we'll further simplify fpu__clear() by making sure that all contexts it is called on are already active. ) Cc: Andy Lutomirski <luto@amacapital.net> Cc: Borislav Petkov <bp@alien8.de> Cc: Dave Hansen <dave.hansen@linux.intel.com> Cc: Fenghua Yu <fenghua.yu@intel.com> Cc: H. Peter Anvin <hpa@zytor.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Oleg Nesterov <oleg@redhat.com> Cc: Peter Zijlstra <peterz@infradead.org> Cc: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: Ingo Molnar <mingo@kernel.org>
Diffstat (limited to 'arch/x86/kernel/signal.c')
-rw-r--r--arch/x86/kernel/signal.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/x86/kernel/signal.c b/arch/x86/kernel/signal.c
index 9554ca6..7c08795 100644
--- a/arch/x86/kernel/signal.c
+++ b/arch/x86/kernel/signal.c
@@ -667,7 +667,7 @@ handle_signal(struct ksignal *ksig, struct pt_regs *regs)
* Ensure the signal handler starts with the new fpu state.
*/
if (fpu->fpstate_active)
- fpu__reset(fpu);
+ fpu__clear(fpu);
}
signal_setup_done(failed, ksig, stepping);
}
OpenPOWER on IntegriCloud