Skip to contentSkip to conversation

x86/bugs: Replace RFDS model checks with VFM ones

PATCH Applied Sohil Mehta 4 participants 7 messages Oct 30 – Nov 25 x86

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 x86/bugs: Replace RFDS model checks with VFM ones

The RFDS vulnerability check uses raw model numbers to identify Alder Lake and Raptor Lake. Most Intel-specific code has already moved away from x86_model checks, but this one got added recently.

Replace the x86_model checks with VFM ones to make them more readable.

---
 arch/x86/kernel/cpu/common.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
arch/x86/kernel/cpu/common.c +2 -2
index c7352827f491..8d7bd8bb7b18 100644
@@ -1392,8 +1392,8 @@ static bool __init vulnerable_to_rfds(u64 x86_arch_cap_msr)
 	 * both Core and Atom CPUs. Mark unaffected when Atom CPUs are not
 	 * present.
 	 */
-	if ((boot_cpu_data.x86_model == 0x97 ||
-	     boot_cpu_data.x86_model == 0xB7) &&
+	if ((boot_cpu_data.x86_vfm == INTEL_ALDERLAKE ||
+	     boot_cpu_data.x86_vfm == INTEL_RAPTORLAKE) &&
 	     boot_cpu_data.topo.intel_type != INTEL_CPU_TYPE_ATOM &&
 	     !boot_cpu_has(X86_FEATURE_HYBRID_CPU))
 		return false;
Signature · 1 line
2.43.0
Reviewed-by on v1 1/1
#1 lore raw
Quoted 16 lines · Sohil Mehta

The RFDS vulnerability check uses raw model numbers to identify Alder Lake and Raptor Lake. Most Intel-specific code has already moved away from x86_model checks, but this one got added recently.

Replace the x86_model checks with VFM ones to make them more readable.

---
 arch/x86/kernel/cpu/common.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
arch/x86/kernel/cpu/common.c +0 -0
index c7352827f491..8d7bd8bb7b18 100644

arch/x86/kernel/cpu/common.c static bool __init vulnerable_to_rfds(u64 x86_arch_cap_msr) · line 1396

Quoted 7 lines
arch/x86/kernel/cpu/common.c +2 -2
@@ -1392,8 +1392,8 @@ static bool __init vulnerable_to_rfds(u64 x86_arch_cap_msr)
 	 * both Core and Atom CPUs. Mark unaffected when Atom CPUs are not
 	 * present.
 	 */
-	if ((boot_cpu_data.x86_model == 0x97 ||
-	     boot_cpu_data.x86_model == 0xB7) &&
+	if ((boot_cpu_data.x86_vfm == INTEL_ALDERLAKE ||
+	     boot_cpu_data.x86_vfm == INTEL_RAPTORLAKE) &&

I missed that when adding the patch. Thanks for fixing.

maintainer
#2 lore raw
In reply to Sohil Mehta
Quoted 17 lines · Sohil Mehta

The RFDS vulnerability check uses raw model numbers to identify Alder Lake and Raptor Lake. Most Intel-specific code has already moved away from x86_model checks, but this one got added recently.

Replace the x86_model checks with VFM ones to make them more readable.

---
 arch/x86/kernel/cpu/common.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
arch/x86/kernel/cpu/common.c +0 -0
index c7352827f491..8d7bd8bb7b18 100644

arch/x86/kernel/cpu/common.c static bool __init vulnerable_to_rfds(u64 x86_arch_cap_msr) · line 1399

Quoted 10 lines
arch/x86/kernel/cpu/common.c +2 -2
@@ -1392,8 +1392,8 @@ static bool __init vulnerable_to_rfds(u64 x86_arch_cap_msr)
 	 * both Core and Atom CPUs. Mark unaffected when Atom CPUs are not
 	 * present.
 	 */
-	if ((boot_cpu_data.x86_model == 0x97 ||
-	     boot_cpu_data.x86_model == 0xB7) &&
+	if ((boot_cpu_data.x86_vfm == INTEL_ALDERLAKE ||
+	     boot_cpu_data.x86_vfm == INTEL_RAPTORLAKE) &&
 	     boot_cpu_data.topo.intel_type != INTEL_CPU_TYPE_ATOM &&
 	     !boot_cpu_has(X86_FEATURE_HYBRID_CPU))
 		return false;

Queued, thx.

Signature · 4 lines
Regards/Gruss,
    Boris.

https://people.kernel.org/tglx/notes-about-netiquette
merge bot Applied
#3 lore raw
In reply to Sohil Mehta
The following commit has been merged into the x86/urgent branch of tip:

The following commit has been merged into the x86/urgent branch of tip:

Commit-ID:     b828d777c292c963aa110c33159a59f81d372ce7
Gitweb:        https://git.kernel.org/tip/b828d777c292c963aa110c33159a59f81d372ce7
Author:        Sohil Mehta <[email protected]>
AuthorDate:    Fri, 30 Oct 2026 12:52:14 -07:00
Committer:     Borislav Petkov (AMD) <[email protected]>
CommitterDate: Sun, 01 Nov 2026 17:42:22 -08:00

x86/bugs: Replace RFDS model checks with VFM ones

The RFDS vulnerability check uses raw model numbers to identify Alder Lake and Raptor Lake. Most Intel-specific code has already moved away from x86_model checks, but this one got added recently.

Replace the x86_model checks with VFM ones to make them more readable.

---
 arch/x86/kernel/cpu/common.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
arch/x86/kernel/cpu/common.c +2 -2
index 9bd50c6..aba7e99 100644
@@ -1391,8 +1391,8 @@ static bool __init vulnerable_to_rfds(u64 x86_arch_cap_msr)
 	 * both Core and Atom CPUs. Mark unaffected when Atom CPUs are not
 	 * present.
 	 */
-	if ((boot_cpu_data.x86_model == 0x97 ||
-	     boot_cpu_data.x86_model == 0xB7) &&
+	if ((boot_cpu_data.x86_vfm == INTEL_ALDERLAKE ||
+	     boot_cpu_data.x86_vfm == INTEL_RAPTORLAKE) &&
 	     boot_cpu_data.topo.intel_type != INTEL_CPU_TYPE_ATOM &&
 	     !boot_cpu_has(X86_FEATURE_HYBRID_CPU))
 		return false;
merge bot Applied
#4 lore raw
In reply to Sohil Mehta
The following commit has been merged into the x86/cleanups branch of tip:

The following commit has been merged into the x86/cleanups branch of tip:

Commit-ID:     07479e8845c8a3a17d49a707a7178e9fd8360ab1
Gitweb:        https://git.kernel.org/tip/07479e8845c8a3a17d49a707a7178e9fd8360ab1
Author:        Sohil Mehta <[email protected]>
AuthorDate:    Fri, 30 Oct 2026 12:52:14 -07:00
Committer:     Borislav Petkov (AMD) <[email protected]>
CommitterDate: Sun, 01 Nov 2026 20:28:55 -08:00

x86/bugs: Replace RFDS model checks with VFM ones

The RFDS vulnerability check uses raw model numbers to identify Alder Lake and Raptor Lake. Most Intel-specific code has already moved away from x86_model checks, but this one got added recently.

Replace the x86_model checks with VFM ones to make them more readable.

---
 arch/x86/kernel/cpu/common.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
arch/x86/kernel/cpu/common.c +2 -2
index 9bd50c6..aba7e99 100644
@@ -1391,8 +1391,8 @@ static bool __init vulnerable_to_rfds(u64 x86_arch_cap_msr)
 	 * both Core and Atom CPUs. Mark unaffected when Atom CPUs are not
 	 * present.
 	 */
-	if ((boot_cpu_data.x86_model == 0x97 ||
-	     boot_cpu_data.x86_model == 0xB7) &&
+	if ((boot_cpu_data.x86_vfm == INTEL_ALDERLAKE ||
+	     boot_cpu_data.x86_vfm == INTEL_RAPTORLAKE) &&
 	     boot_cpu_data.topo.intel_type != INTEL_CPU_TYPE_ATOM &&
 	     !boot_cpu_has(X86_FEATURE_HYBRID_CPU))
 		return false;
#5 lore raw
The following commit has been merged into the x86/cpu branch of tip:

The following commit has been merged into the x86/cpu branch of tip:

Commit-ID:     c9b08a72a6bab2ca4c99f073e62bdc3130615e7e
Gitweb:        https://git.kernel.org/tip/c9b08a72a6bab2ca4c99f073e62bdc3130615e7e
Author:        tip-bot2 for Sohil Mehta <[email protected]>
AuthorDate:    Mon, 02 Nov 2026 04:31:25 
Committer:     Dave Hansen <[email protected]>
CommitterDate: Tue, 24 Nov 2026 08:23:18 -08:00

x86/bugs: Replace RFDS model checks with VFM ones

The following commit has been merged into the x86/cleanups branch of tip:

Commit-ID:     07479e8845c8a3a17d49a707a7178e9fd8360ab1
Gitweb:        https://git.kernel.org/tip/07479e8845c8a3a17d49a707a7178e9fd8360ab1
Author:        Sohil Mehta <[email protected]>
AuthorDate:    Fri, 30 Oct 2026 12:52:14 -07:00
Committer:     Borislav Petkov (AMD) <[email protected]>
CommitterDate: Sun, 01 Nov 2026 20:28:55 -08:00

x86/bugs: Replace RFDS model checks with VFM ones

The RFDS vulnerability check uses raw model numbers to identify Alder Lake and Raptor Lake. Most Intel-specific code has already moved away from x86_model checks, but this one got added recently.

Replace the x86_model checks with VFM ones to make them more readable.

---
 arch/x86/kernel/cpu/common.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
arch/x86/kernel/cpu/common.c +2 -2
index 7e4eb70..0374746 100644
@@ -1391,8 +1391,8 @@ static bool __init vulnerable_to_rfds(u64 x86_arch_cap_msr)
 	 * both Core and Atom CPUs. Mark unaffected when Atom CPUs are not
 	 * present.
 	 */
-	if ((boot_cpu_data.x86_model == 0x97 ||
-	     boot_cpu_data.x86_model == 0xB7) &&
+	if ((boot_cpu_data.x86_vfm == INTEL_ALDERLAKE ||
+	     boot_cpu_data.x86_vfm == INTEL_RAPTORLAKE) &&
 	     boot_cpu_data.topo.intel_type != INTEL_CPU_TYPE_ATOM &&
 	     !boot_cpu_has(X86_FEATURE_HYBRID_CPU))
 		return false;
merge bot Applied
#6 lore raw
In reply to tip-bot2 for Sohil Mehta
The following commit has been merged into the x86/cpu branch of tip:

The following commit has been merged into the x86/cpu branch of tip:

Commit-ID:     bbb389a04a410f49a2976125997217ea8747661a
Gitweb:        https://git.kernel.org/tip/bbb389a04a410f49a2976125997217ea8747661a
Author:        Sohil Mehta <[email protected]>
AuthorDate:    Mon, 02 Nov 2026 04:31:25 
Committer:     Ingo Molnar <[email protected]>
CommitterDate: Wed, 25 Nov 2026 10:56:38 +01:00

x86/bugs: Replace RFDS model checks with VFM ones

x86/bugs: Replace RFDS model checks with VFM ones

The RFDS vulnerability check uses raw model numbers to identify Alder Lake and Raptor Lake. Most Intel-specific code has already moved away from x86_model checks, but this one got added recently.

Replace the x86_model checks with VFM ones to make them more readable.

---
 arch/x86/kernel/cpu/common.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
arch/x86/kernel/cpu/common.c +2 -2
index 7e4eb70..0374746 100644
@@ -1391,8 +1391,8 @@ static bool __init vulnerable_to_rfds(u64 x86_arch_cap_msr)
 	 * both Core and Atom CPUs. Mark unaffected when Atom CPUs are not
 	 * present.
 	 */
-	if ((boot_cpu_data.x86_model == 0x97 ||
-	     boot_cpu_data.x86_model == 0xB7) &&
+	if ((boot_cpu_data.x86_vfm == INTEL_ALDERLAKE ||
+	     boot_cpu_data.x86_vfm == INTEL_RAPTORLAKE) &&
 	     boot_cpu_data.topo.intel_type != INTEL_CPU_TYPE_ATOM &&
 	     !boot_cpu_has(X86_FEATURE_HYBRID_CPU))
 		return false;