diff options
author | Paolo Bonzini <pbonzini@redhat.com> | 2023-04-26 21:53:36 +0200 |
---|---|---|
committer | Paolo Bonzini <pbonzini@redhat.com> | 2023-04-26 21:53:36 +0200 |
commit | 48b1893ae38bd6d46a9dcfc7b85c70a143fb8cab (patch) | |
tree | d69a46c054bf8a8558b17cdb9510ae5285296ba6 /arch/x86/kvm/cpuid.c | |
parent | Merge tag 'kvm-x86-mmu-6.4' of https://github.com/kvm-x86/linux into HEAD (diff) | |
parent | KVM: selftests: Test the PMU event "Instructions retired" (diff) | |
download | linux-48b1893ae38bd6d46a9dcfc7b85c70a143fb8cab.tar.xz linux-48b1893ae38bd6d46a9dcfc7b85c70a143fb8cab.zip |
Merge tag 'kvm-x86-pmu-6.4' of https://github.com/kvm-x86/linux into HEAD
KVM x86 PMU changes for 6.4:
- Disallow virtualizing legacy LBRs if architectural LBRs are available,
the two are mutually exclusive in hardware
- Disallow writes to immutable feature MSRs (notably PERF_CAPABILITIES)
after KVM_RUN, and overhaul the vmx_pmu_caps selftest to better
validate PERF_CAPABILITIES
- Apply PMU filters to emulated events and add test coverage to the
pmu_event_filter selftest
- Misc cleanups and fixes
Diffstat (limited to 'arch/x86/kvm/cpuid.c')
-rw-r--r-- | arch/x86/kvm/cpuid.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/x86/kvm/cpuid.c b/arch/x86/kvm/cpuid.c index 6972e0be60fa..b944492faefa 100644 --- a/arch/x86/kvm/cpuid.c +++ b/arch/x86/kvm/cpuid.c @@ -414,7 +414,7 @@ static int kvm_set_cpuid(struct kvm_vcpu *vcpu, struct kvm_cpuid_entry2 *e2, * KVM_SET_CPUID{,2} again. To support this legacy behavior, check * whether the supplied CPUID data is equal to what's already set. */ - if (vcpu->arch.last_vmentry_cpu != -1) { + if (kvm_vcpu_has_run(vcpu)) { r = kvm_cpuid_check_equal(vcpu, e2, nent); if (r) return r; |