kvm selftest 'msr' fails on some skylake cpus
Hi!
This kvm unit test tests that all reserved bits of the MSR_IA32_FLUSH_CMD #GP, but apparently on some systems this test fails.
For example I reproduced this on:
model name : Intel(R) Xeon(R) CPU E3-1260L v5 @ 2.90GHz
stepping : 3
microcode : 0xf0
As I see in the 'vmx_vcpu_after_set_cpuid', we passthough this msr to the guest AS IS, thus the unit test tests the microcode.
So I suspect that the test actually caught a harmless microcode bug.
What do you think we should do to workaround this? Maybe disable this check on affected cpus or turn it into a warning because MSR_IA32_FLUSH_CMD reserved bits test doesn't test KVM?
Best regards,
Maxim Levitsky
Sean Christopherson
reviewerQuoted 12 lines · Maxim Levitsky
Hi!
This kvm unit test tests that all reserved bits of the
MSR_IA32_FLUSH_CMD#GP, but apparently on some systems this test fails.For example I reproduced this on:
model name : Intel(R) Xeon(R) CPU E3-1260L v5 @ 2.90GHz
stepping : 3
microcode :0xf0
Quoted 4 lines
As I see in the '
vmx_vcpu_after_set_cpuid', we passthough this msr to the guest AS IS, thus the unit test tests the microcode.So I suspect that the test actually caught a harmless microcode bug.
Yeah, we encountered the same thing and came to the same conclusion.
Quoted 3 lines
What do you think we should do to workaround this? Maybe disable this check on affected cpus or turn it into a warning because
MSR_IA32_FLUSH_CMDreserved bits test doesn't test KVM?
Ya, Mingwei posted a patch[*] to force KVM to emulate the faulting accesses, which more or less does exactly that, but preserves a bit of KVM coverage. I'll get a KUT pull request sent to Paolo today, I've got a sizeable number of changes ready.
Quoted 24 lines · Sean Christopherson
Quoted 12 lines · Maxim Levitsky
Hi!
This kvm unit test tests that all reserved bits of the
MSR_IA32_FLUSH_CMD#GP, but apparently on some systems this test fails.For example I reproduced this on:
model name : Intel(R) Xeon(R) CPU E3-1260L v5 @ 2.90GHz
stepping : 3
microcode :0xf0Quoted 4 lines
As I see in the '
vmx_vcpu_after_set_cpuid', we passthough this msr to the guest AS IS, thus the unit test tests the microcode.So I suspect that the test actually caught a harmless microcode bug.
Yeah, we encountered the same thing and came to the same conclusion.
Quoted 3 lines
What do you think we should do to workaround this? Maybe disable this check on affected cpus or turn it into a warning because
MSR_IA32_FLUSH_CMDreserved bits test doesn't test KVM?
Quoted 6 lines
Ya, Mingwei posted a patch[*] to force KVM to emulate the faulting accesses, which more or less does exactly that, but preserves a bit of KVM coverage. I'll get a KUT pull request sent to Paolo today, I've got a sizeable number of changes ready.
This works for me.
Thanks,
Best regards,
Maxim Levitsky
Quoted 30 lines · Maxim Levitsky
Quoted 28 lines · Sean Christopherson
Quoted 12 lines · Maxim Levitsky
Hi!
This kvm unit test tests that all reserved bits of the
MSR_IA32_FLUSH_CMD#GP, but apparently on some systems this test fails.For example I reproduced this on:
model name : Intel(R) Xeon(R) CPU E3-1260L v5 @ 2.90GHz
stepping : 3
microcode :0xf0Quoted 4 lines
As I see in the '
vmx_vcpu_after_set_cpuid', we passthough this msr to the guest AS IS, thus the unit test tests the microcode.So I suspect that the test actually caught a harmless microcode bug.
Yeah, we encountered the same thing and came to the same conclusion.
Quoted 3 lines
What do you think we should do to workaround this? Maybe disable this check on affected cpus or turn it into a warning because
MSR_IA32_FLUSH_CMDreserved bits test doesn't test KVM?Ya, Mingwei posted a patch[*] to force KVM to emulate the faulting accesses, which more or less does exactly that, but preserves a bit of KVM coverage. I'll get a KUT pull request sent to Paolo today, I've got a sizeable number of changes ready.
Quoted 8 lines
Quoted 2 lines
This works for me.
Thanks,Best regards,
Maxim Levitsky
Sean and/or Paolo,
I'm still waiting for this to show up. :)
Sean Christopherson
reviewerQuoted 37 lines · Jim Mattson
Quoted 36 lines · Maxim Levitsky
Quoted 24 lines · Sean Christopherson
Quoted 12 lines · Maxim Levitsky
Hi!
This kvm unit test tests that all reserved bits of the
MSR_IA32_FLUSH_CMD#GP, but apparently on some systems this test fails.For example I reproduced this on:
model name : Intel(R) Xeon(R) CPU E3-1260L v5 @ 2.90GHz
stepping : 3
microcode :0xf0Quoted 4 lines
As I see in the '
vmx_vcpu_after_set_cpuid', we passthough this msr to the guest AS IS, thus the unit test tests the microcode.So I suspect that the test actually caught a harmless microcode bug.
Yeah, we encountered the same thing and came to the same conclusion.
Quoted 3 lines
What do you think we should do to workaround this? Maybe disable this check on affected cpus or turn it into a warning because
MSR_IA32_FLUSH_CMDreserved bits test doesn't test KVM?Quoted 6 lines
Ya, Mingwei posted a patch[*] to force KVM to emulate the faulting accesses, which more or less does exactly that, but preserves a bit of KVM coverage. I'll get a KUT pull request sent to Paolo today, I've got a sizeable number of changes ready.
This works for me.
Thanks,
Quoted 6 lines
Quoted 2 lines
Best regards,
Maxim LevitskySean and/or Paolo,
I'm still waiting for this to show up. :)
13a12056be1e4939dadbd0d2cfb65df400832905 x86: msr: testing MSR_IA32_FLUSH_CMD reserved bits only in KVM emulation 51b87946279cf6e9248ceacf0f27833b6ebeef5e x86: Add FEP support on read/write register instructions
/drop mic