lkml.org 
[lkml]   [2022]   [Jun]   [1]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: [PATCH 1/2] KVM: vmx, pmu: accept 0 for absent MSRs when host-initiated
From
On 5/31/22 20:37, Sean Christopherson wrote:
>> +
>> /*
>> * Writing depth MSR from guest could either setting the
>> * MSR or resetting the LBR records with the side-effect.
>> @@ -535,6 +542,8 @@ static int intel_pmu_set_msr(struct kvm_vcpu *vcpu, struct msr_data *msr_info)
>> case MSR_ARCH_LBR_CTL:
>> if (!arch_lbr_ctl_is_valid(vcpu, data))
>> break;
>> + if (!guest_cpuid_has(vcpu, X86_FEATURE_ARCH_LBR))
>> + return 0;
>
> Similar bug here.
>
> Can we just punt this out of kvm/queue until its been properly reviewed?

Yes, I agree. I have started making some changes and pushed the result
to kvm/arch-lbr-for-weijiang.

Most of the MSR handling is rewritten (and untested).

The nested VMX handling was also completely broken so I just removed it.
Instead, KVM should be adjusted so that it does not whine.

Paolo

\
 
 \ /
  Last update: 2022-06-01 10:55    [W:0.174 / U:0.992 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site