kernel_samsung_a53x/arch/x86
Zhiquan Li 000e5d12f0 x86/mce: Mark fatal MCE's page as poison to avoid panic in the kdump kernel
[ Upstream commit 9f3b130048bfa2e44a8cfb1b616f826d9d5d8188 ]

Memory errors don't happen very often, especially fatal ones. However,
in large-scale scenarios such as data centers, that probability
increases with the amount of machines present.

When a fatal machine check happens, mce_panic() is called based on the
severity grading of that error. The page containing the error is not
marked as poison.

However, when kexec is enabled, tools like makedumpfile understand when
pages are marked as poison and do not touch them so as not to cause
a fatal machine check exception again while dumping the previous
kernel's memory.

Therefore, mark the page containing the error as poisoned so that the
kexec'ed kernel can avoid accessing the page.

  [ bp: Rewrite commit message and comment. ]

Co-developed-by: Youquan Song <youquan.song@intel.com>
Signed-off-by: Youquan Song <youquan.song@intel.com>
Signed-off-by: Zhiquan Li <zhiquan1.li@intel.com>
Signed-off-by: Borislav Petkov (AMD) <bp@alien8.de>
Reviewed-by: Naoya Horiguchi <naoya.horiguchi@nec.com>
Link: https://lore.kernel.org/r/20231014051754.3759099-1-zhiquan1.li@intel.com
Signed-off-by: Sasha Levin <sashal@kernel.org>
2024-11-18 12:13:08 +01:00
..
boot x86/boot: Ignore NMIs during very early boot 2024-11-18 12:13:08 +01:00
configs Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
crypto Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
entry Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
events x86: Share definition of __is_canonical_address() 2024-11-18 11:43:11 +01:00
hyperv Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
ia32 Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
include x86/entry/ia32: Ensure s32 is sign extended to s64 2024-11-18 12:13:07 +01:00
kernel x86/mce: Mark fatal MCE's page as poison to avoid panic in the kdump kernel 2024-11-18 12:13:08 +01:00
kvm KVM: use __vcalloc for very large allocations 2024-11-18 12:12:59 +01:00
lib x86/lib: Fix overflow when counting digits 2024-11-18 12:12:19 +01:00
math-emu Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
mm x86/mm: Drop the 4 MB restriction on minimal NUMA node memory size 2024-11-18 11:43:12 +01:00
net Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
oprofile Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
pci Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
platform Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
power Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
purgatory Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
ras Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
realmode Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
tools Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
um Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
video Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
xen Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
Kbuild Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
Kconfig Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
Kconfig.assembler Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
Kconfig.cpu Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
Kconfig.debug Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
Makefile Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
Makefile.um Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
Makefile_32.cpu Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00