KVM: nVMX: vmcs12 checks on nested entry
authorNadav Har'El <nyh@il.ibm.com>
Wed, 25 May 2011 20:12:04 +0000 (23:12 +0300)
committerAvi Kivity <avi@redhat.com>
Tue, 12 Jul 2011 08:45:16 +0000 (11:45 +0300)
commit7c1779384a2b2479722e90778721c40811e1b7a7
tree586847b6e8b562a1c8118138533735b7f7104248
parent4704d0befb0721274bda863192c4782febb6b94c
KVM: nVMX: vmcs12 checks on nested entry

This patch adds a bunch of tests of the validity of the vmcs12 fields,
according to what the VMX spec and our implementation allows. If fields
we cannot (or don't want to) honor are discovered, an entry failure is
emulated.

According to the spec, there are two types of entry failures: If the problem
was in vmcs12's host state or control fields, the VMLAUNCH instruction simply
fails. But a problem is found in the guest state, the behavior is more
similar to that of an exit.

Signed-off-by: Nadav Har'El <nyh@il.ibm.com>
Signed-off-by: Marcelo Tosatti <mtosatti@redhat.com>
arch/x86/include/asm/vmx.h
arch/x86/kvm/vmx.c