arch/x86/cpu_common: use cpu_cpuid_extended_level
Use cpu_cpuid_extended_level instead of open-coding the same
functionality in cpu_check_deterministic_cache_cpuid_supported.
Signed-off-by: Felix Held <felix-coreboot@felixheld.de>
Change-Id: I4ea22c3997769179311f3c8822e6d8cc15a8834c
Reviewed-on: https://review.coreboot.org/c/coreboot/+/78057
Reviewed-by: Matt DeVillier <matt.devillier@amd.corp-partner.google.com>
Reviewed-by: Paul Menzel <paulepanter@mailbox.org>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
diff --git a/src/arch/x86/cpu_common.c b/src/arch/x86/cpu_common.c
index af4e7b0..102ccf0 100644
--- a/src/arch/x86/cpu_common.c
+++ b/src/arch/x86/cpu_common.c
@@ -97,8 +97,7 @@
return CPUID_COMMAND_UNSUPPORTED;
return CPUID_TYPE_INTEL;
} else if (cpu_is_amd()) {
- res = cpuid(0x80000000);
- if (res.eax < 0x80000001)
+ if (cpu_cpuid_extended_level() < 0x80000001)
return CPUID_COMMAND_UNSUPPORTED;
res = cpuid(0x80000001);