Re: Old microcode CPU matching issue - x86/microcode/intel: Refresh the revisions that determine old_microcode
From: Sohil Mehta
Date: Thu Nov 20 2025 - 12:30:01 EST
On 11/20/2025 8:35 AM, Jon Kohler wrote:
>>
>> It attempts to take IA32_PLATFORM_ID into account when considering
>> old microcode.
>
> Hey Dave - got a chance to give it a go, and this did not seem to solve
> the issue, and in fact it made it kinda worse as I didn’t end up seeing
> the microcode getting patched up at all now.
>
There seems to be a simple bug in the patches. intel_get_platform_id()
already returns a mask so x86_match_cpu() shouldn't do the BIT()
operation for the platform_id.
Ignoring variable renames, this change (ontop of the patches) should
atleast fix the x86_match_cpu() issue.
diff --git a/arch/x86/kernel/cpu/match.c b/arch/x86/kernel/cpu/match.c
index 23b13ffc6053..613860448855 100644
--- a/arch/x86/kernel/cpu/match.c
+++ b/arch/x86/kernel/cpu/match.c
@@ -77,7 +77,7 @@ const struct x86_cpu_id *x86_match_cpu(const struct
x86_cpu_id *match)
!(BIT(c->x86_stepping) & m->steppings))
continue;
if (m->platform_mask != X86_PLATFORM_ANY &&
- !(BIT(c->x86_platform_id) & m->platform_mask))
+ !(c->x86_platform_id & m->platform_mask))
continue;
if (m->feature != X86_FEATURE_ANY && !cpu_has(c, m->feature))
continue;
> On 6.18 rc6 with a bit of debug logging added, still seeing the same
>
> [ 0.000000] x86/CPU: microcode 0x721421856 is older than minimum 0x721421881
> [ 0.000000] x86/CPU: MATCH LIST DATA: family 0x6, model 0x8f, steppings 0x100
> [ 0.000000] x86/CPU: BOOT_CPU_DATA: family 0x6, model 0x8f, stepping 0x8
> [ 0.000000] x86/CPU: Running old microcode
> [ 3.404176] microcode: Current revision: 0x2b000620 <<<<< I do have 0x2b000643 on the system, but it didn’t give me a notice that it updated early now
>
> This was on this proc:
> smpboot: CPU0: Intel(R) Xeon(R) Gold 5416S (family: 0x6, model: 0x8f, stepping: 0x8)
>
> Jon