You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
KVM: x86: Blindly get current x2APIC reg value on "nodecode write" traps
When emulating a x2APIC write in response to an APICv/AVIC trap, get the
the written value from the vAPIC page without checking that reads are
allowed for the target register. AVIC can generate trap-like VM-Exits on
writes to EOI, and so KVM needs to get the written value from the backing
page without running afoul of EOI's write-only behavior.
Alternatively, EOI could be special cased to always write '0', e.g. so
that the sanity check could be preserved, but x2APIC on AMD is actually
supposed to disallow non-zero writes (not emulated by KVM), and the
sanity check was a byproduct of how the KVM code was written, i.e. wasn't
added to guard against anything in particular.
Fixes: 70c8327 ("KVM: x86: Bug the VM if an accelerated x2APIC trap occurs on a "bad" reg")
Fixes: 1bd9dfe ("KVM: x86: Do not block APIC write for non ICR registers")
Reported-by: Alejandro Jimenez <[email protected]>
Cc: [email protected]
Signed-off-by: Sean Christopherson <[email protected]>
Orabug: 34817119
Signed-off-by: Alejandro Jimenez <[email protected]>
Reviewed-by: Boris Ostrovsky <[email protected]>
Taken from upstream mailing list:
KVM: x86: Blindly get current x2APIC reg value on "nodecode write" traps
https://lore.kernel.org/kvm/[email protected]/
(cherry picked from commit ea0ddb98af1d3fc90cd28fe07aa43a6690b8286c)
Signed-off-by: Jack Vogel <[email protected]>
0 commit comments