Also, the allowed/required CR0/CR4 bits may not be the same for the vCPU as for the physical hardware, so more than just CR4.VMXE may have to be checked. On Thu, Apr 27, 2017 at 8:00 AM, Jim Mattson <jmattson@xxxxxxxxxx> wrote: > On Thu, Apr 27, 2017 at 4:25 AM, Paolo Bonzini <pbonzini@xxxxxxxxxx> wrote: >> >> >> On 27/04/2017 10:29, David Hildenbrand wrote: >>>> arch/x86/kvm/vmx.c | 55 ++++++++---------------------------------------------- >>>> 1 file changed, 8 insertions(+), 47 deletions(-) >>> Nice! So we really only have to check vmxon / pointer / features for >>> vmxon and for the others only vmxon. >> >> Still not good, CR4.VMXE has to be checked because we always run the >> guest with CR4.VMXE set (see section 23.8 in the SDM). > > Ah, yes, Of course. > >> >> Paolo >> >>> Reviewed-by: David Hildenbrand <david@xxxxxxxxxx>