Re: [PATCH] KVM: SVM: drop MSR_IA32_PERF_CAPABILITIES from emulated MSRs

2020-06-18 Thread Vitaly Kuznetsov
Paolo Bonzini writes: > On 17/06/20 13:38, Vitaly Kuznetsov wrote: >> >> For KVM_GET_MSR_INDEX_LIST, the promise is "guest msrs that are >> supported" and I'm not exactly sure what this means. Personally, I see >> no point in returning MSRs which can't be read with KVM_GET_MSRS (as >> this also

Re: [PATCH] KVM: SVM: drop MSR_IA32_PERF_CAPABILITIES from emulated MSRs

2020-06-17 Thread Paolo Bonzini
On 17/06/20 13:38, Vitaly Kuznetsov wrote: > > For KVM_GET_MSR_INDEX_LIST, the promise is "guest msrs that are > supported" and I'm not exactly sure what this means. Personally, I see > no point in returning MSRs which can't be read with KVM_GET_MSRS (as > this also means the guest can't read them

Re: [PATCH] KVM: SVM: drop MSR_IA32_PERF_CAPABILITIES from emulated MSRs

2020-06-17 Thread Jim Mattson
On Wed, Jun 17, 2020 at 4:38 AM Vitaly Kuznetsov wrote: > Side note: MSR_IA32_PERF_CAPABILITIES can be returned by both > KVM_GET_MSR_INDEX_LIST and KVM_GET_MSR_FEATURE_INDEX_LIST as we have it > both as an emulated MSR filtered by kvm_x86_ops.has_emulated_msr() and > a feature msr filtered by kv

Re: [PATCH] KVM: SVM: drop MSR_IA32_PERF_CAPABILITIES from emulated MSRs

2020-06-17 Thread Vitaly Kuznetsov
Jim Mattson writes: > On Tue, Jun 16, 2020 at 9:45 AM Vitaly Kuznetsov wrote: >> >> Jim Mattson writes: >> >> > On Tue, Jun 16, 2020 at 9:14 AM Vitaly Kuznetsov >> > wrote: >> >> >> >> state_test/smm_test selftests are failing on AMD with: >> >> "Unexpected result from KVM_GET_MSRS, r: 51 (fa

Re: [PATCH] KVM: SVM: drop MSR_IA32_PERF_CAPABILITIES from emulated MSRs

2020-06-16 Thread Jim Mattson
On Tue, Jun 16, 2020 at 9:45 AM Vitaly Kuznetsov wrote: > > Jim Mattson writes: > > > On Tue, Jun 16, 2020 at 9:14 AM Vitaly Kuznetsov > > wrote: > >> > >> state_test/smm_test selftests are failing on AMD with: > >> "Unexpected result from KVM_GET_MSRS, r: 51 (failed MSR was 0x345)" > >> > >> M

Re: [PATCH] KVM: SVM: drop MSR_IA32_PERF_CAPABILITIES from emulated MSRs

2020-06-16 Thread Vitaly Kuznetsov
Jim Mattson writes: > On Tue, Jun 16, 2020 at 9:14 AM Vitaly Kuznetsov wrote: >> >> state_test/smm_test selftests are failing on AMD with: >> "Unexpected result from KVM_GET_MSRS, r: 51 (failed MSR was 0x345)" >> >> MSR_IA32_PERF_CAPABILITIES is an emulated MSR indeed but only on Intel, >> make

Re: [PATCH] KVM: SVM: drop MSR_IA32_PERF_CAPABILITIES from emulated MSRs

2020-06-16 Thread Jim Mattson
On Tue, Jun 16, 2020 at 9:14 AM Vitaly Kuznetsov wrote: > > state_test/smm_test selftests are failing on AMD with: > "Unexpected result from KVM_GET_MSRS, r: 51 (failed MSR was 0x345)" > > MSR_IA32_PERF_CAPABILITIES is an emulated MSR indeed but only on Intel, > make svm_has_emulated_msr() skip it

[PATCH] KVM: SVM: drop MSR_IA32_PERF_CAPABILITIES from emulated MSRs

2020-06-16 Thread Vitaly Kuznetsov
state_test/smm_test selftests are failing on AMD with: "Unexpected result from KVM_GET_MSRS, r: 51 (failed MSR was 0x345)" MSR_IA32_PERF_CAPABILITIES is an emulated MSR indeed but only on Intel, make svm_has_emulated_msr() skip it so it is not returned by KVM_GET_MSR_INDEX_LIST. Fixes: 27461da310