On 25/02/16 11:24, Jan Beulich wrote: >>>> On 25.02.16 at 11:58, <david.vra...@citrix.com> wrote: >> @@ -261,7 +261,15 @@ void xsave(struct vcpu *v, uint64_t mask) >> "=m" (*ptr), \ >> "a" (lmask), "d" (hmask), "D" (ptr)) >> >> - if ( word_size <= 0 || !is_pv_32bit_vcpu(v) ) >> + if ( fip_width == 8 ) >> + { >> + XSAVE("0x48,"); >> + } >> + else if ( fip_width == 4 ) >> + { >> + XSAVE(""); >> + } >> + else > > Both conditions would now better also check mask & XSTATE_FP, > since going these routes (and namely bypassing the FIP check, as > was done before) is fine when FP state is not being saved.
Is this what you mean? --- a/xen/arch/x86/xstate.c +++ b/xen/arch/x86/xstate.c @@ -261,7 +261,7 @@ void xsave(struct vcpu *v, uint64_t mask) "=m" (*ptr), \ "a" (lmask), "d" (hmask), "D" (ptr)) - if ( fip_width == 8 ) + if ( fip_width == 8 || !(mask & XSTATE_FP) ) { XSAVE("0x48,"); } David _______________________________________________ Xen-devel mailing list Xen-devel@lists.xen.org http://lists.xen.org/xen-devel