From: Jan Beulich Date: Tue, 26 Jun 2018 06:54:14 +0000 (+0200) Subject: x86/HVM: attempts to emulate FPU insns need to set fpu_initialised X-Git-Tag: 4.11.0-rc7~7 X-Git-Url: http://xenbits.xensource.com/gitweb?a=commitdiff_plain;h=1c88cadbe57b5c3a5bfb35507fea1ba6eafee219;p=people%2Fdwmw2%2Fxen.git x86/HVM: attempts to emulate FPU insns need to set fpu_initialised My original way of thinking here was that this would be set anyway at the point state gets reloaded after the adjustments hvmemul_put_fpu() does, but the flag should already be set before that - after all the guest may never again touch the FPU before e.g. getting migrated/saved. Signed-off-by: Jan Beulich Reviewed-by: Andrew Cooper Acked-by: Paul Durrant Release-acked-by: Juergen Gross master commit: 3310e3cd648f3713c824790bd71d8ec405a09d05 master date: 2018-06-26 08:41:08 +0200 --- diff --git a/xen/arch/x86/hvm/emulate.c b/xen/arch/x86/hvm/emulate.c index 03a4944e88..7ecee12ffc 100644 --- a/xen/arch/x86/hvm/emulate.c +++ b/xen/arch/x86/hvm/emulate.c @@ -2053,6 +2053,7 @@ static int hvmemul_get_fpu( * masking of all exceptions by FNSTENV.) */ save_fpu_enable(); + curr->fpu_initialised = true; curr->fpu_dirtied = true; if ( (fpu_ctxt->fcw & 0x3f) != 0x3f ) {