]> www.infradead.org Git - users/jedix/linux-maple.git/commit
KVM: x86/pmu: Add a helper to enable bits in FIXED_CTR_CTRL
authorSean Christopherson <seanjc@google.com>
Sat, 8 Jun 2024 00:08:19 +0000 (17:08 -0700)
committerSean Christopherson <seanjc@google.com>
Tue, 11 Jun 2024 16:35:58 +0000 (09:35 -0700)
commit3b65a692a5c78d597d23a2838e91d7bf8ef49291
treed38d44a4b99b977aadd858a08997a03d3bb4d5bc
parent75430c412a3139c29404459ab1216a07d1280428
KVM: x86/pmu: Add a helper to enable bits in FIXED_CTR_CTRL

Add a helper, intel_pmu_enable_fixed_counter_bits(), to dedup code that
enables fixed counter bits, i.e. when KVM clears bits in the reserved mask
used to detect invalid MSR_CORE_PERF_FIXED_CTR_CTRL values.

No functional change intended.

Cc: Dapeng Mi <dapeng1.mi@linux.intel.com>
Reviewed-by: Dapeng Mi <dapeng1.mi@linux.intel.com>
Link: https://lore.kernel.org/r/20240608000819.3296176-1-seanjc@google.com
Signed-off-by: Sean Christopherson <seanjc@google.com>
arch/x86/kvm/vmx/pmu_intel.c