x86/mce/AMD: Make sure banks were initialized before accessing them
Borislav Petkov
maintainerQuoted 2 lines · Rafał Miłecki
Sure! E-mail me whenever you have something to test, I'll stick to the current BIOS version, thanks for the notice!
Thx!
Here's a first simple try to do the initialization of the needed structures much earlier so that the thresholding interrupt can function earlier and maybe catch your MCEs.
Please apply it ontop and send me full dmesg.
Thx.
arch/x86/kernel/cpu/mcheck/mce.c +2 -3
@@ -1747,10 +1747,9 @@ static void __mcheck_cpu_init_vendor(struct cpuinfo_x86 *c) mce_adjust_timer = cmci_intel_adjust_timer;break ; -case X86_VENDOR_AMD : { +case X86_VENDOR_AMD :mce_amd_feature_init (c);break ; - }case X86_VENDOR_HYGON :mce_hygon_feature_init (c);
@@ -2411,7 +2410,7 @@ static __init int mcheck_init_device(void)return err; } -device_initcall_sync (mcheck_init_device); +core_initcall (mcheck_init_device);/* * Old style boot options parsing. Only for compatibility.
arch/x86/kernel/cpu/mcheck/mce_amd.c +1 -1
@@ -1434,4 +1434,4 @@ static __init int threshold_init_device(void)* when running under xen, the initcall order is 1,2,3; * on baremetal, we skip 1 and we do only 2 and 3. */ -late_initcall (threshold_init_device); +core_initcall_sync (threshold_init_device);