linux/arch/x86/kernel/cpu/mce
Yazen Ghannam c7d314f386 x86/MCE: Make the number of MCA banks a per-CPU variable
The number of MCA banks is provided per logical CPU. Historically, this
number has been the same across all CPUs, but this is not an
architectural guarantee. Future AMD systems may have MCA bank counts
that vary between logical CPUs in a system.

This issue was partially addressed in

  006c077041 ("x86/mce: Handle varying MCA bank counts")

by allocating structures using the maximum number of MCA banks and by
saving the maximum MCA bank count in a system as the global count. This
means that some extra structures are allocated. Also, this means that
CPUs will spend more time in the #MC and other handlers checking extra
MCA banks.

Thus, define the number of MCA banks as a per-CPU variable.

 [ bp: Make mce_num_banks an unsigned int. ]

Signed-off-by: Yazen Ghannam <yazen.ghannam@amd.com>
Signed-off-by: Borislav Petkov <bp@suse.de>
Cc: "H. Peter Anvin" <hpa@zytor.com>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: "linux-edac@vger.kernel.org" <linux-edac@vger.kernel.org>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Tony Luck <tony.luck@intel.com>
Cc: "x86@kernel.org" <x86@kernel.org>
Link: https://lkml.kernel.org/r/20190607201752.221446-5-Yazen.Ghannam@amd.com
2019-06-11 15:23:09 +02:00
..
amd.c x86/MCE: Make the number of MCA banks a per-CPU variable 2019-06-11 15:23:09 +02:00
apei.c
core.c x86/MCE: Make the number of MCA banks a per-CPU variable 2019-06-11 15:23:09 +02:00
dev-mcelog.c treewide: Add SPDX license identifier for missed files 2019-05-21 10:50:45 +02:00
genpool.c x86/MCE: Add an MCE-record filtering function 2019-04-23 18:04:47 +02:00
inject.c treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 172 2019-05-30 11:26:39 -07:00
intel.c
internal.h x86/MCE: Make the number of MCA banks a per-CPU variable 2019-06-11 15:23:09 +02:00
Makefile
p5.c
severity.c x86/mce: Improve error message when kernel cannot recover, p2 2019-02-25 23:21:35 +01:00
therm_throt.c treewide: Add SPDX license identifier for missed files 2019-05-21 10:50:45 +02:00
threshold.c
winchip.c