KVM: x86: Add macros to track first...last VMX feature MSRs
authorSean Christopherson <seanjc@google.com>
Sat, 11 Mar 2023 00:46:00 +0000 (16:46 -0800)
committerSean Christopherson <seanjc@google.com>
Thu, 6 Apr 2023 21:57:22 +0000 (14:57 -0700)
commit5757f5b9562244e4b63f65576c16ca9eb21f81d2
tree715573ee5a347850c4db3a57a01eb250a81d6c1b
parentfb3146b4dc3bc6d0c0402a75f21d628eccf9bf8c
KVM: x86: Add macros to track first...last VMX feature MSRs

Add macros to track the range of VMX feature MSRs that are emulated by
KVM to reduce the maintenance cost of extending the set of emulated MSRs.

Note, KVM doesn't necessarily emulate all known/consumed VMX MSRs, e.g.
PROCBASED_CTLS3 is consumed by KVM to enable IPI virtualization, but is
not emulated as KVM doesn't emulate/virtualize IPI virtualization for
nested guests.

No functional change intended.

Reviewed-by: Xiaoyao Li <xiaoyao.li@intel.com>
Link: https://lore.kernel.org/r/20230311004618.920745-4-seanjc@google.com
Signed-off-by: Sean Christopherson <seanjc@google.com>
arch/x86/kvm/svm/svm.c
arch/x86/kvm/vmx/vmx.c
arch/x86/kvm/x86.h