]> git.baikalelectronics.ru Git - kernel.git/commit
KVM: cpuid: set CPUID(EAX=0xd,ECX=1).EBX correctly
authorPaolo Bonzini <pbonzini@redhat.com>
Wed, 3 Dec 2014 13:38:01 +0000 (14:38 +0100)
committerPaolo Bonzini <pbonzini@redhat.com>
Fri, 5 Dec 2014 12:57:17 +0000 (13:57 +0100)
commit24a769ec441bee3c6b325269705a02263c981d64
treee8577d48dd317052835aaddeac35a94eb2bf45b4
parented97ef67f927b779fadbff4e400a16e9e0aa2c47
KVM: cpuid: set CPUID(EAX=0xd,ECX=1).EBX correctly

This is the size of the XSAVES area.  This starts providing guest support
for XSAVES (with no support yet for supervisor states, i.e. XSS == 0
always in guests for now).

Wanpeng Li suggested testing XSAVEC as well as XSAVES, since in practice
no real processor exists that only has one of them, and there is no
other way for userspace programs to compute the area of the XSAVEC
save area.  CPUID(EAX=0xd,ECX=1).EBX provides an upper bound.

Suggested-by: Radim Krčmář <rkrcmar@redhat.com>
Reviewed-by: Radim Krčmář <rkrcmar@redhat.com>
Tested-by: Wanpeng Li <wanpeng.li@linux.intel.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
arch/x86/kvm/cpuid.c