[kvm-unit-tests PATCH 02/14] x86: msr: Exclude GS/FS_BASE MSRs from 32-bit builds

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Don't test GS/FS_BASE and KERNEL_GS_BASE on 32-bit builds, the MSRs are
64-bit only and should #GP when accessed on 32-bit vCPUs.

Fixes: 7d36db3 ("Initial commit from qemu-kvm.git kvm/test/")
Signed-off-by: Sean Christopherson <seanjc@xxxxxxxxxx>
---
 x86/msr.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/x86/msr.c b/x86/msr.c
index ce5dabe..757156d 100644
--- a/x86/msr.c
+++ b/x86/msr.c
@@ -36,6 +36,7 @@ struct msr_info msr_info[] =
     { .index = 0x00000277, .name = "MSR_IA32_CR_PAT",
       .val_pairs = {{ .valid = 1, .value = 0x07070707, .expected = 0x07070707}}
     },
+#ifdef __x86_64__
     { .index = 0xc0000100, .name = "MSR_FS_BASE",
       .val_pairs = {{ .valid = 1, .value = addr_64, .expected = addr_64}}
     },
@@ -45,7 +46,6 @@ struct msr_info msr_info[] =
     { .index = 0xc0000102, .name = "MSR_KERNEL_GS_BASE",
       .val_pairs = {{ .valid = 1, .value = addr_64, .expected = addr_64}}
     },
-#ifdef __x86_64__
     { .index = 0xc0000080, .name = "MSR_EFER",
       .val_pairs = {{ .valid = 1, .value = 0xD00, .expected = 0xD00}}
     },
-- 
2.31.1.498.g6c1eba8ee3d-goog




[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux