2014-11-21 00:31:27

by Wanpeng Li

[permalink] [raw]
Subject: Re: KVM causes #GP on XRSTORS

Hi Nadav,
On Thu, Nov 20, 2014 at 06:34:04PM +0200, Nadav Amit wrote:
>Fenghua,
>
>I got KVM (v3.17) crashing on a machine that supports XRSTORS - It appears to get a #GP when it is trying to load the guest FPU.
>One reason for the #GP is that XCOMP_BV[63] is zeroed on the guest_fpu, but I am not sure it is the only problem.
>Was KVM ever tested with XRSTORS?

Current kvm and qemu use standard format and xsaves/xrstors should use
compact format, in addition, vmx is still not enabled for xsaves/xrstors
in kvm.

Regards,
Wanpeng Li

>
>Thanks,
>Nadav
>
>--
>To unsubscribe from this list: send the line "unsubscribe kvm" in
>the body of a message to [email protected]
>More majordomo info at http://vger.kernel.org/majordomo-info.html


2014-11-21 01:09:41

by Nadav Amit

[permalink] [raw]
Subject: Re: KVM causes #GP on XRSTORS


> On Nov 21, 2014, at 02:10, Wanpeng Li <[email protected]> wrote:
>
> Hi Nadav,
> On Thu, Nov 20, 2014 at 06:34:04PM +0200, Nadav Amit wrote:
>> Fenghua,
>>
>> I got KVM (v3.17) crashing on a machine that supports XRSTORS - It appears to get a #GP when it is trying to load the guest FPU.
>> One reason for the #GP is that XCOMP_BV[63] is zeroed on the guest_fpu, but I am not sure it is the only problem.
>> Was KVM ever tested with XRSTORS?
>
> Current kvm and qemu use standard format and xsaves/xrstors should use
> compact format, in addition, vmx is still not enabled for xsaves/xrstors
> in kvm.

Sorry, but I don’t quite understand. Should KVM work on a machine that supports xsaves/xrstors?
I am not referring to whether KVM exposes the capability to the guest, but to whether KVM should work at all.

Thanks,
Nadav