diff options
| author | Sean Christopherson <seanjc@google.com> | 2025-12-30 13:13:45 -0800 |
|---|---|---|
| committer | Sean Christopherson <seanjc@google.com> | 2026-01-13 17:37:03 -0800 |
| commit | a08ca6691fd3ab40e40eb6600193672d50c7a7ba (patch) | |
| tree | ac1c6c23869f2a5b42faa67363614d01890d8001 /rust/alloc/collections/git@git.tavy.me:linux.git | |
| parent | d7507a94a07202234236d7f94bed6015ca645ae6 (diff) | |
KVM: SVM: Limit incorrect check on SVM_EXIT_ERR to running as a VM
Limit KVM's incorrect check for VMXEXIT_INVALID, a.k.a. SVM_EXIT_ERR, to
running as a VM, as detected by X86_FEATURE_HYPERVISOR. The exit_code and
all failure codes, e.g. VMXEXIT_INVALID, are 64-bit values, and so checking
only bits 31:0 could result in false positives when running on non-broken
hardware, e.g. in the extremely unlikely scenario exit code 0xffffffffull
is ever generated by hardware.
Keep the 32-bit check to play nice with running on broken KVM (for years,
KVM has not set bits 63:32 when synthesizing nested SVM VM-Exits).
Reviewed-by: Yosry Ahmed <yosry.ahmed@linux.dev>
Link: https://patch.msgid.link/20251230211347.4099600-7-seanjc@google.com
Signed-off-by: Sean Christopherson <seanjc@google.com>
Diffstat (limited to 'rust/alloc/collections/git@git.tavy.me:linux.git')
0 files changed, 0 insertions, 0 deletions
