]> git.ipfire.org Git - thirdparty/kernel/stable.git/commitdiff
Revert "KVM: x86: expose MSR_TSC_AUX to userspace"
authorBen Hutchings <ben@decadent.org.uk>
Mon, 6 Mar 2017 19:09:14 +0000 (19:09 +0000)
committerBen Hutchings <ben@decadent.org.uk>
Thu, 16 Mar 2017 02:27:26 +0000 (02:27 +0000)
This reverts commit a79ed0ed3763b3558b74e7d65fdd8c0215b5b6a2, which was
commit 9dbe6cf941a6fe82933aef565e4095fb10f65023 upstream.  It depends on
several other large commits to work, and without them causes a regression.

References: https://bugzilla.redhat.com/show_bug.cgi?id=1408333
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
Cc: Eric Wheeler <kvm@lists.ewheeler.net>
arch/x86/kvm/x86.c

index 62cb77359d3a8ef5948badb1ab9fb688e3c81077..7dcb958a805488d1d022098c5fb6013ad0dfd3b5 100644 (file)
@@ -892,7 +892,7 @@ static u32 msrs_to_save[] = {
        MSR_CSTAR, MSR_KERNEL_GS_BASE, MSR_SYSCALL_MASK, MSR_LSTAR,
 #endif
        MSR_IA32_TSC, MSR_IA32_CR_PAT, MSR_VM_HSAVE_PA,
-       MSR_IA32_FEATURE_CONTROL, MSR_IA32_BNDCFGS, MSR_TSC_AUX,
+       MSR_IA32_FEATURE_CONTROL, MSR_IA32_BNDCFGS
 };
 
 static unsigned num_msrs_to_save;
@@ -3994,17 +3994,16 @@ static void kvm_init_msr_list(void)
 
                /*
                 * Even MSRs that are valid in the host may not be exposed
-                * to the guests in some cases.
+                * to the guests in some cases.  We could work around this
+                * in VMX with the generic MSR save/load machinery, but it
+                * is not really worthwhile since it will really only
+                * happen with nested virtualization.
                 */
                switch (msrs_to_save[i]) {
                case MSR_IA32_BNDCFGS:
                        if (!kvm_x86_ops->mpx_supported())
                                continue;
                        break;
-               case MSR_TSC_AUX:
-                       if (!kvm_x86_ops->rdtscp_supported())
-                               continue;
-                       break;
                default:
                        break;
                }