Re: [PATCH 2/2] x86/microcode: Rework early revisions reporting

Borislav Petkov
2023-12-01T20:43:49Z

On Fri, Dec 01, 2023 at 12:33:34PM -0800, Ashok Raj wrote:
> I'll get a dmesg shortly once i get my test system back.

Thanks.

> What I meant was

I know what you meant. Did you see the diff I sent you?

It has the fix already:

@@ -410,13 +421,19 @@ void __init load_ucode_intel_bsp(struct early_load_data *ed)
{
struct ucode_cpu_info uci;

- ed->old_rev = intel_get_microcode_revision();
-
uci.mc = get_microcode_blob(&uci, false);
- if (uci.mc && apply_microcode_early(&uci) == UCODE_UPDATED)
+ ed->old_rev = uci.cpu_sig.rev;
+
+ uc_dbg("old_rev: 0x%x", ed->old_rev);
+
+ if (uci.mc && apply_microcode_early(&uci) == UCODE_UPDATED) {
ucode_patch_va = UCODE_BSP_LOADED;
+ ed->new_rev = uci.cpu_sig.rev;
+
+ uc_dbg("updated, new_rev: 0x%x", ed->new_rev);
+ }
^^^^^^^^^^^^^

The assignment is now inside the UCODE_UPDATED conditional.

--
Regards/Gruss,
Boris.