]> www.infradead.org Git - users/jedix/linux-maple.git/commit
KVM: x86: Document an erratum in KVM_SET_VCPU_EVENTS on Intel CPUs
authorSean Christopherson <seanjc@google.com>
Fri, 2 Aug 2024 20:04:20 +0000 (13:04 -0700)
committerSean Christopherson <seanjc@google.com>
Fri, 1 Nov 2024 16:22:28 +0000 (09:22 -0700)
commit0e3b70aa137cb29a407de38e5b660d939ab462a3
treea69be465b0d7543a1c1d5262fb2d72fe6f593a7a
parent90a877216e6bd4cc336ecd85ad4e95cf7a1aa1c8
KVM: x86: Document an erratum in KVM_SET_VCPU_EVENTS on Intel CPUs

Document a flaw in KVM's ABI which lets userspace attempt to inject a
"bad" hardware exception event, and thus induce VM-Fail on Intel CPUs.
Fixing the flaw is a fool's errand, as AMD doesn't sanity check the
validity of the error code, Intel CPUs that support CET relax the check
for Protected Mode, userspace can change the mode after queueing an
exception, KVM ignores the error code when emulating Real Mode exceptions,
and so on and so forth.

The VM-Fail itself doesn't harm KVM or the kernel beyond triggering a
ratelimited pr_warn(), so just document the oddity.

Link: https://lore.kernel.org/r/20240802200420.330769-1-seanjc@google.com
Signed-off-by: Sean Christopherson <seanjc@google.com>
Documentation/virt/kvm/x86/errata.rst