]> xenbits.xensource.com Git - xen.git/commit
x86/EFI: further correct FPU state handling around runtime calls
authorJan Beulich <jbeulich@suse.com>
Tue, 26 Jun 2018 13:23:08 +0000 (15:23 +0200)
committerJan Beulich <jbeulich@suse.com>
Tue, 26 Jun 2018 13:23:08 +0000 (15:23 +0200)
commit23839a0fa0bbe78c174cd2bb49083e153f0f99df
tree34cb373c549b2ed47b6c1d1b0d8616808a236ecd
parentbbc721a82c9480e8083ffe315505af072b43b12f
x86/EFI: further correct FPU state handling around runtime calls

We must not leave a vCPU with CR0.TS clear when it is not in fully eager
mode and has not touched non-lazy state. Instead of adding a 3rd
invocation of stts() to vcpu_restore_fpu_eager(), consolidate all of
them into a single one done at the end of the function.

Rename the function at the same time to better reflect its purpose, as
the patches touches all of its occurences anyway.

The new function parameter is not really well named, but
"need_stts_if_not_fully_eager" seemed excessive to me.

Signed-off-by: Jan Beulich <jbeulich@suse.com>
Reviewed-by: Andrew Cooper <andrew.cooper3@citrix.com>
Reviewed-by: Paul Durrant <paul.durrant@citrix.com>
xen/arch/x86/domain.c
xen/arch/x86/hvm/emulate.c
xen/arch/x86/i387.c
xen/common/efi/runtime.c
xen/include/asm-x86/i387.h