]> git.ipfire.org Git - thirdparty/linux.git/commitdiff
KVM: x86: allow CPUID 0xC000_0000 to proceed on Zhaoxin CPUs
authorEwan Hai <ewanhai-oc@zhaoxin.com>
Mon, 18 Aug 2025 08:30:34 +0000 (04:30 -0400)
committerSean Christopherson <seanjc@google.com>
Tue, 19 Aug 2025 18:59:30 +0000 (11:59 -0700)
Bypass the Centaur-only filter for the CPUID signature leaf so that
processing continues when the CPU vendor is Zhaoxin.

Signed-off-by: Ewan Hai <ewanhai-oc@zhaoxin.com>
Link: https://lore.kernel.org/r/20250818083034.93935-1-ewanhai-oc@zhaoxin.com
Signed-off-by: Sean Christopherson <seanjc@google.com>
arch/x86/kvm/cpuid.c

index e2836a255b1679de1ef76a6869fdf25217b8b201..bee8c869259f7a550688578ef29c2ddfa217735b 100644 (file)
@@ -1820,7 +1820,8 @@ static int get_cpuid_func(struct kvm_cpuid_array *array, u32 func,
        int r;
 
        if (func == CENTAUR_CPUID_SIGNATURE &&
-           boot_cpu_data.x86_vendor != X86_VENDOR_CENTAUR)
+           boot_cpu_data.x86_vendor != X86_VENDOR_CENTAUR &&
+           boot_cpu_data.x86_vendor != X86_VENDOR_ZHAOXIN)
                return 0;
 
        r = do_cpuid_func(array, func, type);