From: Anil Altinay <aaltinay@google.com>
To: aaltinay@google.com, stable@vger.kernel.org
Subject: [PATCH 6.18.y 0/6] KVM: x86: CPUID faulting fixes and AMD CPUID faulting virtualization
Date: Wed, 14 Oct 2026 21:28:38 +0000 [thread overview]
Message-ID: <20261014212844.11997-1-aaltinay@google.com> (raw)
Please backport the following 6 upstream commits to the 6.18.y stable tree:
1. 690dc03859e7 ("KVM: x86: Ignore cpuid faulting in SMM") [v7.1-rc1]
2. cf7d65d1d6f5 ("KVM: x86: Consolidate CPUID fault handling for emulator and interception logic") [v7.2-rc1]
3. be7fd7c3e8bc ("KVM: x86: Prioritize CPUID faulting over CPUID VM-exits in nested VMX") [v7.2-rc1]
4. d1bc99885a59 ("KVM: x86: Remove supports_cpuid_fault() helper") [v7.2-rc1]
5. e93a93f11490 ("KVM: x86: Virtualize AMD CPUID faulting") [v7.2-rc1]
6. b16c2aca369d ("KVM: selftests: Update hwcr_msr_test for CPUID faulting bit") [v7.2-rc1]
Patches 1 and 3 fix bugs in KVM's CPUID faulting virtualization (Fixes:
db2336a80489 ("KVM: x86: virtualize cpuid faulting")), ensuring that
CPUID does not fault in SMM and that CPUID faulting takes precedence
over CPUID VM-exits in nested VMX. Patch 2 is a non-functional refactoring
prerequisite for patch 3.
Patches 4-6 extend KVM's CPUID faulting virtualization (already supported
by KVM on Intel CPUs and by 6.18 host kernels on AMD CPUs via 65f55a301766
("x86/CPU/AMD: Add CPUID faulting support")) to AMD guests via
CPUID.80000021H:EAX.CpuidUserDis[bit 17] and HWCR.CpuidUserDis[bit 35],
allowing guests and container runtimes that rely on arch_prctl(ARCH_SET_CPUID)
to work uniformly across Intel and AMD KVM hosts, along with the
corresponding KVM selftest update.
All patches cherry-pick cleanly to 6.18.y except for a minor context
conflict in patch 2 (arch/x86/include/asm/kvm_host.h) and a u64 vs.
uint64_t type adjustment in patch 6 (tools/testing/selftests/kvm/x86/hwcr_msr_test.c).
Jim Mattson (5):
KVM: x86: Ignore cpuid faulting in SMM
KVM: x86: Prioritize CPUID faulting over CPUID VM-exits in nested VMX
KVM: x86: Remove supports_cpuid_fault() helper
KVM: x86: Virtualize AMD CPUID faulting
KVM: selftests: Update hwcr_msr_test for CPUID faulting bit
Sean Christopherson (1):
KVM: x86: Consolidate CPUID fault handling for emulator and
interception logic
arch/x86/include/asm/kvm_host.h | 1 -
arch/x86/include/asm/msr-index.h | 1 +
arch/x86/kvm/cpuid.c | 6 ++-
arch/x86/kvm/cpuid.h | 14 ++++---
arch/x86/kvm/emulate.c | 6 +--
arch/x86/kvm/kvm_emulate.h | 1 +
arch/x86/kvm/vmx/nested.c | 2 +
arch/x86/kvm/x86.c | 39 ++++++++++---------
.../selftests/kvm/include/x86/processor.h | 1 +
.../testing/selftests/kvm/x86/hwcr_msr_test.c | 9 ++++-
10 files changed, 46 insertions(+), 34 deletions(-)
--
2.56.0.385.gd3acb90ef8-goog
next reply other threads:[~2026-10-14 21:29 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-10-14 21:28 Anil Altinay [this message]
2026-10-14 21:28 ` [PATCH 6.18.y 1/6] KVM: x86: Ignore cpuid faulting in SMM Anil Altinay
2026-10-14 21:28 ` [PATCH 6.18.y 2/6] KVM: x86: Consolidate CPUID fault handling for emulator and interception logic Anil Altinay
2026-10-14 21:28 ` [PATCH 6.18.y 3/6] KVM: x86: Prioritize CPUID faulting over CPUID VM-exits in nested VMX Anil Altinay
2026-10-14 21:28 ` [PATCH 6.18.y 4/6] KVM: x86: Remove supports_cpuid_fault() helper Anil Altinay
2026-10-14 21:28 ` [PATCH 6.18.y 5/6] KVM: x86: Virtualize AMD CPUID faulting Anil Altinay
2026-10-14 21:28 ` [PATCH 6.18.y 6/6] KVM: selftests: Update hwcr_msr_test for CPUID faulting bit Anil Altinay
2026-10-14 22:18 ` [PATCH 6.18.y 0/6] KVM: x86: CPUID faulting fixes and AMD CPUID faulting virtualization Anil Altinay
2026-10-15 5:22 ` Greg KH
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20261014212844.11997-1-aaltinay@google.com \
--to=aaltinay@google.com \
--cc=stable@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox