]> xenbits.xensource.com Git - xen.git/commit
x86/boot: Record MSR_ARCH_CAPS for the Raw and Host CPU policy
authorAndrew Cooper <andrew.cooper3@citrix.com>
Fri, 12 May 2023 14:37:02 +0000 (15:37 +0100)
committerAndrew Cooper <andrew.cooper3@citrix.com>
Wed, 24 May 2023 18:04:41 +0000 (19:04 +0100)
commit70553000d6b44dd7c271a35932b0b3e1f22c5532
tree255befd76a2c9e0fe4309049952ee37bb3b1d32e
parentce8c930851a5ca21c4e70f83be7e8b290ce1b519
x86/boot: Record MSR_ARCH_CAPS for the Raw and Host CPU policy

Extend x86_cpu_policy_fill_native() with a read of ARCH_CAPS based on the
CPUID information just read, removing the specially handling in
calculate_raw_cpu_policy().

Right now, the only use of x86_cpu_policy_fill_native() outside of Xen is the
unit tests.  Getting MSR data in this context is left to whomever first
encounters a genuine need to have it.

Extend generic_identify() to read ARCH_CAPS into x86_capability[], which is
fed into the Host Policy.  This in turn means there's no need to special case
arch_caps in calculate_host_policy().

No practical change.

Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Reviewed-by: Jan Beulich <jbeulich@suse.com>
xen/arch/x86/cpu-policy.c
xen/arch/x86/cpu/common.c
xen/lib/x86/cpuid.c