]> git.baikalelectronics.ru Git - kernel.git/commit
KVM: x86: Check for host supported fields in shadow vmcs
authorBandan Das <bsd@redhat.com>
Mon, 21 Apr 2014 19:20:14 +0000 (15:20 -0400)
committerPaolo Bonzini <pbonzini@redhat.com>
Mon, 28 Apr 2014 09:14:51 +0000 (11:14 +0200)
commitd872a23f966f8de2f14dc9043325ace5d13c1964
treedd1d04f0273b4cdc23d3882395e31e0d2ed4c4c2
parenta3968e4f656de5233afccb07db18ad3c302e743d
KVM: x86: Check for host supported fields in shadow vmcs

We track shadow vmcs fields through two static lists,
one for read only and another for r/w fields. However, with
addition of new vmcs fields, not all fields may be supported on
all hosts. If so, copy_vmcs12_to_shadow() trying to vmwrite on
unsupported hosts will result in a vmwrite error. For example, commit
4feceea1d3967b8 introduced GUEST_BNDCFGS, which is not supported
by all processors. Filter out host unsupported fields before
letting guests use shadow vmcs

Signed-off-by: Bandan Das <bsd@redhat.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
arch/x86/kvm/vmx.c