]> git.baikalelectronics.ru Git - kernel.git/commit
KVM: fix XSAVE bit scanning
authorAndre Przywara <andre.przywara@amd.com>
Wed, 30 Mar 2011 13:01:45 +0000 (15:01 +0200)
committerAvi Kivity <avi@redhat.com>
Wed, 6 Apr 2011 10:15:55 +0000 (13:15 +0300)
commitbb63f3e43ce26d2c1c553df2b077233824c7764c
tree4e7e725a5acbcbc9125bb792637658a08dc11ead
parentd338c9249ccb7b074a642705ae3f76b42d7f0dad
KVM: fix XSAVE bit scanning

When KVM scans the 0xD CPUID leaf for propagating the XSAVE save area
leaves, it assumes that the leaves are contigious and stops at the
first zero one. On AMD hardware there is a gap, though, as LWP uses
leaf 62 to announce it's state save area.
So lets iterate through all 64 possible leaves and simply skip zero
ones to also cover later features.

Signed-off-by: Andre Przywara <andre.przywara@amd.com>
Signed-off-by: Avi Kivity <avi@redhat.com>
arch/x86/kvm/x86.c