diff options
author | Ingo Molnar <mingo@kernel.org> | 2015-04-24 02:07:15 +0200 |
---|---|---|
committer | Ingo Molnar <mingo@kernel.org> | 2015-05-19 15:47:29 +0200 |
commit | c69e098b1f90c0d520c4d5b5bff9f2ede95b13a8 (patch) | |
tree | 13ae867c328bb463770664f2f69d44d4438ff21a /arch/x86/kernel/fpu/core.c | |
parent | f9bc977fe734772a7ca4a467fe4fd74e1ea3a849 (diff) | |
download | linux-c69e098b1f90c0d520c4d5b5bff9f2ede95b13a8.tar.bz2 |
x86/fpu: Use 'struct fpu' in fpu__copy()
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/kernel/fpu/core.c')
-rw-r--r-- | arch/x86/kernel/fpu/core.c | 13 |
1 files changed, 5 insertions, 8 deletions
diff --git a/arch/x86/kernel/fpu/core.c b/arch/x86/kernel/fpu/core.c index 9aaba6abfae3..a84358575235 100644 --- a/arch/x86/kernel/fpu/core.c +++ b/arch/x86/kernel/fpu/core.c @@ -240,15 +240,12 @@ static void fpu_copy(struct fpu *dst_fpu, struct fpu *src_fpu) } } -int fpu__copy(struct task_struct *dst, struct task_struct *src) +int fpu__copy(struct fpu *dst_fpu, struct fpu *src_fpu) { - struct fpu *dst_fpu = &dst->thread.fpu; - struct fpu *src_fpu = &src->thread.fpu; - - dst->thread.fpu.counter = 0; - dst->thread.fpu.has_fpu = 0; - dst->thread.fpu.state = NULL; - dst->thread.fpu.last_cpu = -1; + dst_fpu->counter = 0; + dst_fpu->has_fpu = 0; + dst_fpu->state = NULL; + dst_fpu->last_cpu = -1; if (src_fpu->fpstate_active) { int err = fpstate_alloc(dst_fpu); |