summaryrefslogtreecommitdiffstats
path: root/arch/x86/include/asm/fpu-internal.h
diff options
context:
space:
mode:
authorIngo Molnar <mingo@kernel.org>2015-04-23 17:34:20 +0200
committerIngo Molnar <mingo@kernel.org>2015-05-19 15:47:26 +0200
commitaf2d94fddcf41e879908b35a8a5308fb94e989c5 (patch)
tree903b84bbf46b3720b5e51505baa4bbb40e1fee2b /arch/x86/include/asm/fpu-internal.h
parent11f2d50b10289f49676ec07bf3fef932473ef6d5 (diff)
downloadlinux-af2d94fddcf41e879908b35a8a5308fb94e989c5.tar.bz2
x86/fpu: Use 'struct fpu' in fpu_reset_state()
Migrate this function to pure 'struct fpu' usage. Reviewed-by: Borislav Petkov <bp@alien8.de> Cc: Andy Lutomirski <luto@amacapital.net> 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/include/asm/fpu-internal.h')
-rw-r--r--arch/x86/include/asm/fpu-internal.h6
1 files changed, 2 insertions, 4 deletions
diff --git a/arch/x86/include/asm/fpu-internal.h b/arch/x86/include/asm/fpu-internal.h
index 2d7934e4e394..579f7d0a399d 100644
--- a/arch/x86/include/asm/fpu-internal.h
+++ b/arch/x86/include/asm/fpu-internal.h
@@ -380,10 +380,8 @@ static inline void restore_init_xstate(void)
* Reset the FPU state in the eager case and drop it in the lazy case (later use
* will reinit it).
*/
-static inline void fpu_reset_state(struct task_struct *tsk)
+static inline void fpu_reset_state(struct fpu *fpu)
{
- struct fpu *fpu = &tsk->thread.fpu;
-
if (!use_eager_fpu())
drop_fpu(fpu);
else
@@ -460,7 +458,7 @@ static inline void switch_fpu_finish(struct task_struct *new, fpu_switch_t fpu)
if (fpu.preload) {
if (unlikely(restore_fpu_checking(new_fpu)))
- fpu_reset_state(new);
+ fpu_reset_state(new_fpu);
}
}