]> www.infradead.org Git - users/jedix/linux-maple.git/commit
KVM: x86/xen: Add an #ifdef'd helper to detect writes to Xen MSR
authorSean Christopherson <seanjc@google.com>
Sat, 15 Feb 2025 01:14:34 +0000 (17:14 -0800)
committerSean Christopherson <seanjc@google.com>
Mon, 24 Feb 2025 16:59:57 +0000 (08:59 -0800)
commitbb0978d95a551b8181469c4442fd59567c9dd999
tree0119ed0e4a6f5018403db93c29c60d3dc5fa8e94
parent5c17848134ab1ffb97c4a17a6e25b41390478152
KVM: x86/xen: Add an #ifdef'd helper to detect writes to Xen MSR

Add a helper to detect writes to the Xen hypercall page MSR, and provide a
stub for CONFIG_KVM_XEN=n to optimize out the check for kernels built
without Xen support.

Reviewed-by: Paul Durrant <paul@xen.org>
Reviewed-by: David Woodhouse <dwmw@amazon.co.uk>
Link: https://lore.kernel.org/r/20250215011437.1203084-3-seanjc@google.com
Signed-off-by: Sean Christopherson <seanjc@google.com>
arch/x86/kvm/x86.c
arch/x86/kvm/xen.h