]> git.ipfire.org Git - thirdparty/linux.git/commit
KVM: nSVM: Disable PMU MSR interception as appropriate while running L2
authorSean Christopherson <seanjc@google.com>
Sat, 6 Dec 2025 00:17:08 +0000 (16:17 -0800)
committerSean Christopherson <seanjc@google.com>
Thu, 8 Jan 2026 19:52:15 +0000 (11:52 -0800)
commit3b36160d9406863812883c96c1efc8bc5c04e2cc
treefc95d22553adea2f9f0624fd1af6618aa286389c
parent88ebc2a3199cb5f16aff20673ed97b63a4295989
KVM: nSVM: Disable PMU MSR interception as appropriate while running L2

Add MSRs that might be passed through to L1 when running with a mediated
PMU to the nested SVM's set of to-be-merged MSR indices, i.e. disable
interception of PMU MSRs when running L2 if both KVM (L0) and L1 disable
interception.  There is no need for KVM to interpose on such MSR accesses,
e.g. if L1 exposes a mediated PMU (or equivalent) to L2.

Tested-by: Xudong Hao <xudong.hao@intel.com>
Tested-by: Manali Shukla <manali.shukla@amd.com>
Link: https://patch.msgid.link/20251206001720.468579-33-seanjc@google.com
Signed-off-by: Sean Christopherson <seanjc@google.com>
arch/x86/kvm/svm/nested.c