public inbox for kvm@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] x86: Fix allowed IA32_VMX_VMCS_ENUM values
@ 2019-04-15 22:21 nadav.amit
  2019-04-15 23:29 ` Sean Christopherson
  2019-04-16  8:28 ` Paolo Bonzini
  0 siblings, 2 replies; 3+ messages in thread
From: nadav.amit @ 2019-04-15 22:21 UTC (permalink / raw)
  To: Paolo Bonzini; +Cc: kvm, Nadav Amit

From: Nadav Amit <nadav.amit@gmail.com>

According to the SDM, IA32_VMX_VMCS_ENUM indicates to software the
highest index value used in the encoding of any field supported by the
processor: Bits 9:1 contain the highest index value used for any VMCS
encoding.

Signed-off-by: Nadav Amit <nadav.amit@gmail.com>
---
 x86/vmx.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/x86/vmx.c b/x86/vmx.c
index 6ba56bc..f713ada 100644
--- a/x86/vmx.c
+++ b/x86/vmx.c
@@ -1470,7 +1470,7 @@ static void test_vmx_caps(void)
 
 	val = rdmsr(MSR_IA32_VMX_VMCS_ENUM);
 	report("MSR_IA32_VMX_VMCS_ENUM",
-	       (val & 0x3e) >= 0x2a &&
+	       (val & 0x1fe) >= 0x2a &&
 	       (val & 0xfffffffffffffc01Ull) == 0);
 
 	val = rdmsr(MSR_IA32_VMX_EPT_VPID_CAP);
-- 
2.17.1


^ permalink raw reply related	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2019-04-16  8:28 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-04-15 22:21 [PATCH] x86: Fix allowed IA32_VMX_VMCS_ENUM values nadav.amit
2019-04-15 23:29 ` Sean Christopherson
2019-04-16  8:28 ` Paolo Bonzini

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox