Skip to content

Commit bae593b

Browse files
committed
KVM: VMX: Remove restriction that PMU version > 0 for PERF_CAPABILITIES
Drop the restriction that the PMU version is non-zero when handling writes to PERF_CAPABILITIES now that KVM unconditionally checks for PDCM support. Link: https://lore.kernel.org/r/20240802185511.305849-6-seanjc@google.com Signed-off-by: Sean Christopherson <seanjc@google.com>
1 parent c2eb2d0 commit bae593b

File tree

1 file changed

+0
-2
lines changed

1 file changed

+0
-2
lines changed

arch/x86/kvm/vmx/vmx.c

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2456,8 +2456,6 @@ int vmx_set_msr(struct kvm_vcpu *vcpu, struct msr_data *msr_info)
24562456
vmx->pt_desc.guest.addr_a[index / 2] = data;
24572457
break;
24582458
case MSR_IA32_PERF_CAPABILITIES:
2459-
if (data && !vcpu_to_pmu(vcpu)->version)
2460-
return 1;
24612459
if (data & PMU_CAP_LBR_FMT) {
24622460
if ((data & PMU_CAP_LBR_FMT) !=
24632461
(kvm_caps.supported_perf_cap & PMU_CAP_LBR_FMT))

0 commit comments

Comments
 (0)