Re: [PATCH] x86/MCE: Prevent CPU offline for SMCA CPUs with non-core banks

From: Borislav Petkov
Date: Tue Aug 27 2024 - 08:52:07 EST


On August 26, 2024 3:20:57 PM GMT+02:00, Yazen Ghannam <yazen.ghannam@xxxxxxx> wrote:
>On Sun, Aug 25, 2024 at 01:16:37PM +0200, Thomas Gleixner wrote:
>> On Wed, Aug 21 2024 at 09:00, Yazen Ghannam wrote:
>> > Logical CPUs in AMD Scalable MCA (SMCA) systems can manage non-core
>> > banks. Each of these banks represents unique and separate hardware
>> > located within the system. Each bank is managed by a single logical CPU;
>> > they are not shared. Furthermore, the "CPU to MCA bank" assignment
>> > cannot be modified at run time.
>> >
>> > The MCE subsystem supports run time CPU hotplug. Many vendors have
>> > non-core MCA banks, so MCA settings are not cleared when a CPU is
>> > offlined for these vendors.
>> >
>> > Even though the non-core MCA banks remain enabled, MCA errors will not
>> > be handled (reported, cleared, etc.) on SMCA systems when the managing
>> > CPU is offline.
>> >
>> > Check if a CPU manages non-core MCA banks and, if so, prevent it from
>> > being taken offline.
>>
>> Which in turn breaks hibernation and kexec...
>>
>
>Right, good point.
>
>Maybe this change can apply only to a user-initiated (sysfs) case?
>
>Thanks,
>Yazen
>

Or, you can simply say that the MCE cannot be processed because the user took the managing CPU offline.

What is this actually really fixing anyway?
--
Sent from a small device: formatting sucks and brevity is inevitable.