diff options
author | Ingo Molnar <mingo@kernel.org> | 2015-04-30 17:15:32 +0200 |
---|---|---|
committer | Ingo Molnar <mingo@kernel.org> | 2015-05-19 15:48:09 +0200 |
commit | c47ada305de3803517ae64aa50686f644c5456fa (patch) | |
tree | a1cbdef798651ea1804c43bb2b99d66639ff662e /arch/x86/include/asm/fpu/internal.h | |
parent | 0c306bcfba288296dc34d00d514546915234bc90 (diff) | |
download | lwn-c47ada305de3803517ae64aa50686f644c5456fa.tar.gz lwn-c47ada305de3803517ae64aa50686f644c5456fa.zip |
x86/fpu: Harmonize FPU register state types
Use these consistent names:
struct fregs_state # was: i387_fsave_struct
struct fxregs_state # was: i387_fxsave_struct
struct swregs_state # was: i387_soft_struct
struct xregs_state # was: xsave_struct
union fpregs_state # was: thread_xstate
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/include/asm/fpu/internal.h')
-rw-r--r-- | arch/x86/include/asm/fpu/internal.h | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/arch/x86/include/asm/fpu/internal.h b/arch/x86/include/asm/fpu/internal.h index db6c24ba6d3d..7fdc90b9dd86 100644 --- a/arch/x86/include/asm/fpu/internal.h +++ b/arch/x86/include/asm/fpu/internal.h @@ -22,20 +22,20 @@ extern unsigned int mxcsr_feature_mask; -extern union thread_xstate init_fpstate; +extern union fpregs_state init_fpstate; extern void fpu__init_cpu(void); extern void fpu__init_system_xstate(void); extern void fpu__init_cpu_xstate(void); extern void fpu__init_system(struct cpuinfo_x86 *c); -extern void fpstate_init(union thread_xstate *state); +extern void fpstate_init(union fpregs_state *state); #ifdef CONFIG_MATH_EMULATION -extern void fpstate_init_soft(struct i387_soft_struct *soft); +extern void fpstate_init_soft(struct swregs_state *soft); #else -static inline void fpstate_init_soft(struct i387_soft_struct *soft) {} +static inline void fpstate_init_soft(struct swregs_state *soft) {} #endif -static inline void fpstate_init_fxstate(struct i387_fxsave_struct *fx) +static inline void fpstate_init_fxstate(struct fxregs_state *fx) { fx->cwd = 0x37f; fx->mxcsr = MXCSR_DEFAULT; @@ -133,12 +133,12 @@ extern void fpstate_sanitize_xstate(struct fpu *fpu); err; \ }) -static inline int copy_fregs_to_user(struct i387_fsave_struct __user *fx) +static inline int copy_fregs_to_user(struct fregs_state __user *fx) { return user_insn(fnsave %[fx]; fwait, [fx] "=m" (*fx), "m" (*fx)); } -static inline int copy_fxregs_to_user(struct i387_fxsave_struct __user *fx) +static inline int copy_fxregs_to_user(struct fxregs_state __user *fx) { if (config_enabled(CONFIG_X86_32)) return user_insn(fxsave %[fx], [fx] "=m" (*fx), "m" (*fx)); @@ -149,7 +149,7 @@ static inline int copy_fxregs_to_user(struct i387_fxsave_struct __user *fx) return user_insn(rex64/fxsave (%[fx]), "=m" (*fx), [fx] "R" (fx)); } -static inline int copy_kernel_to_fxregs(struct i387_fxsave_struct *fx) +static inline int copy_kernel_to_fxregs(struct fxregs_state *fx) { if (config_enabled(CONFIG_X86_32)) return check_insn(fxrstor %[fx], "=m" (*fx), [fx] "m" (*fx)); @@ -161,7 +161,7 @@ static inline int copy_kernel_to_fxregs(struct i387_fxsave_struct *fx) "m" (*fx)); } -static inline int copy_user_to_fxregs(struct i387_fxsave_struct __user *fx) +static inline int copy_user_to_fxregs(struct fxregs_state __user *fx) { if (config_enabled(CONFIG_X86_32)) return user_insn(fxrstor %[fx], "=m" (*fx), [fx] "m" (*fx)); @@ -173,12 +173,12 @@ static inline int copy_user_to_fxregs(struct i387_fxsave_struct __user *fx) "m" (*fx)); } -static inline int copy_kernel_to_fregs(struct i387_fsave_struct *fx) +static inline int copy_kernel_to_fregs(struct fregs_state *fx) { return check_insn(frstor %[fx], "=m" (*fx), [fx] "m" (*fx)); } -static inline int copy_user_to_fregs(struct i387_fsave_struct __user *fx) +static inline int copy_user_to_fregs(struct fregs_state __user *fx) { return user_insn(frstor %[fx], "=m" (*fx), [fx] "m" (*fx)); } |