diff options
| author | Jim Mattson <jmattson@google.com> | 2026-05-27 20:43:44 +0300 |
|---|---|---|
| committer | Sean Christopherson <seanjc@google.com> | 2026-05-27 21:21:41 +0300 |
| commit | be7fd7c3e8bcfd3a1804567ce5cf9ca3b254c1ba (patch) | |
| tree | 0c28b16947a05e25899f6ca775925a5ebe7c76dd /scripts | |
| parent | cf7d65d1d6f50daadfe7c475f0c2b1bfdc288b56 (diff) | |
| download | linux-be7fd7c3e8bcfd3a1804567ce5cf9ca3b254c1ba.tar.xz | |
KVM: x86: Prioritize CPUID faulting over CPUID VM-exits in nested VMX
Per the Intel SDM, "Certain exceptions have priority over VM exits. These
include invalid-opcode exceptions, faults based on privilege level, and
general-protection exceptions that are based on checking I/O permission
bits in the task-state segment (TSS)."
Ensure that when L2 executes CPUID at CPL > 0 while L1 has enabled CPUID
faulting, KVM intercepts the exit in L0 and queues #GP rather than
forwarding the CPUID VM-exit to L1.
Empirical testing confirms that this #GP has higher precedence than a CPUID
VM-exit on Granite Rapids (F/M/S 6/0xad/1).
Fixes: db2336a80489 ("KVM: x86: virtualize cpuid faulting")
Reported-by: Sashiko <sashiko-bot@kernel.org>
Closes: https://sashiko.dev/#/patchset/20260513224608.1859737-1-jmattson%40google.com?part=3
Signed-off-by: Jim Mattson <jmattson@google.com>
Link: https://patch.msgid.link/20260527174347.2356165-3-jmattson@google.com
Signed-off-by: Sean Christopherson <seanjc@google.com>
Diffstat (limited to 'scripts')
0 files changed, 0 insertions, 0 deletions
