diff options
author | Jim Mattson <jmattson@google.com> | 2022-09-01 23:18:07 +0200 |
---|---|---|
committer | Sean Christopherson <seanjc@google.com> | 2023-01-24 19:05:18 +0100 |
commit | 2a4209d6a9cb51082813e3081e1172ae68d27935 (patch) | |
tree | bd66f553b3f03217893769b0281cc44dc47df62a /arch/x86/kvm/cpuid.c | |
parent | x86/cpufeatures: Add macros for Intel's new fast rep string features (diff) | |
download | linux-2a4209d6a9cb51082813e3081e1172ae68d27935.tar.xz linux-2a4209d6a9cb51082813e3081e1172ae68d27935.zip |
KVM: x86: Advertise fast REP string features inherent to the CPU
Fast zero-length REP MOVSB, fast short REP STOSB, and fast short REP
{CMPSB,SCASB} are inherent features of the processor that cannot be
hidden by the hypervisor. When these features are present on the host,
enumerate them in KVM_GET_SUPPORTED_CPUID.
Signed-off-by: Jim Mattson <jmattson@google.com>
Reviewed-by: Sean Christopherson <seanjc@google.com>
Link: https://lore.kernel.org/r/20220901211811.2883855-2-jmattson@google.com
Signed-off-by: Sean Christopherson <seanjc@google.com>
Diffstat (limited to 'arch/x86/kvm/cpuid.c')
-rw-r--r-- | arch/x86/kvm/cpuid.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/arch/x86/kvm/cpuid.c b/arch/x86/kvm/cpuid.c index 2a9f1e200dbc..d37cdab18715 100644 --- a/arch/x86/kvm/cpuid.c +++ b/arch/x86/kvm/cpuid.c @@ -664,8 +664,9 @@ void kvm_set_cpu_caps(void) kvm_cpu_cap_set(X86_FEATURE_SPEC_CTRL_SSBD); kvm_cpu_cap_mask(CPUID_7_1_EAX, - F(AVX_VNNI) | F(AVX512_BF16) | F(CMPCCXADD) | F(AMX_FP16) | - F(AVX_IFMA) + F(AVX_VNNI) | F(AVX512_BF16) | F(CMPCCXADD) | + F(FZRM) | F(FSRS) | F(FSRC) | + F(AMX_FP16) | F(AVX_IFMA) ); kvm_cpu_cap_init_kvm_defined(CPUID_7_1_EDX, |