diff options
| author | Sean Christopherson <[email protected]> | 2022-05-12 22:27:14 +0000 |
|---|---|---|
| committer | Sean Christopherson <[email protected]> | 2022-07-08 14:52:59 -0700 |
| commit | 2368048bf5c2ec4b604ac3431564071e89a0bc71 (patch) | |
| tree | 1ff3322bc564100878eac4a18735de08c295e1d8 /tools/perf/scripts/python | |
| parent | 0378739401cfc2fd2a50a2a337a4f394e8493008 (diff) | |
KVM: x86: Signal #GP, not -EPERM, on bad WRMSR(MCi_CTL/STATUS)
Return '1', not '-1', when handling an illegal WRMSR to a MCi_CTL or
MCi_STATUS MSR. The behavior of "all zeros' or "all ones" for CTL MSRs
is architectural, as is the "only zeros" behavior for STATUS MSRs. I.e.
the intent is to inject a #GP, not exit to userspace due to an unhandled
emulation case. Returning '-1' gets interpreted as -EPERM up the stack
and effecitvely kills the guest.
Fixes: 890ca9aefa78 ("KVM: Add MCE support")
Fixes: 9ffd986c6e4e ("KVM: X86: #GP when guest attempts to write MCi_STATUS register w/o 0")
Cc: [email protected]
Signed-off-by: Sean Christopherson <[email protected]>
Reviewed-by: Jim Mattson <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Diffstat (limited to 'tools/perf/scripts/python')
0 files changed, 0 insertions, 0 deletions