diff options
| -rw-r--r-- | arch/x86/kernel/fpu/core.c | 4 | ||||
| -rw-r--r-- | arch/x86/kernel/fpu/init.c | 2 |
2 files changed, 4 insertions, 2 deletions
diff --git a/arch/x86/kernel/fpu/core.c b/arch/x86/kernel/fpu/core.c index d25097c3fc1d..d5804adfa6da 100644 --- a/arch/x86/kernel/fpu/core.c +++ b/arch/x86/kernel/fpu/core.c | |||
| @@ -409,8 +409,10 @@ static inline void copy_init_fpstate_to_fpregs(void) | |||
| 409 | { | 409 | { |
| 410 | if (use_xsave()) | 410 | if (use_xsave()) |
| 411 | copy_kernel_to_xregs(&init_fpstate.xsave, -1); | 411 | copy_kernel_to_xregs(&init_fpstate.xsave, -1); |
| 412 | else | 412 | else if (static_cpu_has(X86_FEATURE_FXSR)) |
| 413 | copy_kernel_to_fxregs(&init_fpstate.fxsave); | 413 | copy_kernel_to_fxregs(&init_fpstate.fxsave); |
| 414 | else | ||
| 415 | copy_kernel_to_fregs(&init_fpstate.fsave); | ||
| 414 | } | 416 | } |
| 415 | 417 | ||
| 416 | /* | 418 | /* |
diff --git a/arch/x86/kernel/fpu/init.c b/arch/x86/kernel/fpu/init.c index 9ee7e307b18f..bd08fb77073d 100644 --- a/arch/x86/kernel/fpu/init.c +++ b/arch/x86/kernel/fpu/init.c | |||
| @@ -134,7 +134,7 @@ static void __init fpu__init_system_generic(void) | |||
| 134 | * Set up the legacy init FPU context. (xstate init might overwrite this | 134 | * Set up the legacy init FPU context. (xstate init might overwrite this |
| 135 | * with a more modern format, if the CPU supports it.) | 135 | * with a more modern format, if the CPU supports it.) |
| 136 | */ | 136 | */ |
| 137 | fpstate_init_fxstate(&init_fpstate.fxsave); | 137 | fpstate_init(&init_fpstate); |
| 138 | 138 | ||
| 139 | fpu__init_system_mxcsr(); | 139 | fpu__init_system_mxcsr(); |
| 140 | } | 140 | } |
