From: Tony Luck Date: Mon, 20 May 2024 22:46:01 +0000 (-0700) Subject: x86/virt/tdx: Switch to new Intel CPU model defines X-Git-Tag: v6.11-rc1~193^2~8 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=189e8d4b98495a9145301a3594f4fb56118211e8;p=thirdparty%2Fkernel%2Flinux.git x86/virt/tdx: Switch to new Intel CPU model defines New CPU #defines encode vendor and family as well as model. Signed-off-by: Tony Luck Signed-off-by: Dave Hansen Link: https://lore.kernel.org/all/20240520224620.9480-31-tony.luck%40intel.com --- diff --git a/arch/x86/virt/vmx/tdx/tdx.c b/arch/x86/virt/vmx/tdx/tdx.c index 49a1c6890b556..4e2b2e2ac9f90 100644 --- a/arch/x86/virt/vmx/tdx/tdx.c +++ b/arch/x86/virt/vmx/tdx/tdx.c @@ -33,7 +33,7 @@ #include #include #include -#include +#include #include #include #include "tdx.h" @@ -1426,9 +1426,9 @@ static void __init check_tdx_erratum(void) * private memory poisons that memory, and a subsequent read of * that memory triggers #MC. */ - switch (boot_cpu_data.x86_model) { - case INTEL_FAM6_SAPPHIRERAPIDS_X: - case INTEL_FAM6_EMERALDRAPIDS_X: + switch (boot_cpu_data.x86_vfm) { + case INTEL_SAPPHIRERAPIDS_X: + case INTEL_EMERALDRAPIDS_X: setup_force_cpu_bug(X86_BUG_TDX_PW_MCE); } }