Skip to contentSkip to conversation

x86/mce: Improve error message when kernel cannot recover (part 2)

PATCH New Tony Luck 2 participants 2 messages Feb 25, 2019

Subsystems (2)
lore
Share & tools
lore

Tony Luck

author maintainer
#0 lore raw

PATCH 1/1 x86/mce: Improve error message when kernel cannot recover (part 2)

In c7d606f560e4:
("x86/mce: Improve error message when kernel cannot recover")
we added a case for a machine check caused by a DATA access to poison memory from the kernel. We should also have added a case for an uncorrectable error during an instruction fetch in the kernel.

Add the extra case so the error message now reads:

mce: [Hardware Error]: Machine check: Instruction fetch error in kernel

Fixes c7d606f560e4 ("x86/mce: Improve error message when kernel cannot recover")
---
 arch/x86/kernel/cpu/mce/severity.c | 5 +++++
 1 file changed, 5 insertions(+)
arch/x86/kernel/cpu/mce/severity.c +5 -0
index dc3e26e905a3..65201e180fe0 100644
@@ -165,6 +165,11 @@ static struct severity {
 		SER, MASK(MCI_STATUS_OVER|MCI_UC_SAR|MCI_ADDR|MCACOD, MCI_UC_SAR|MCI_ADDR|MCACOD_DATA),
 		KERNEL
 		),
+	MCESEV(
+		PANIC, "Instruction fetch error in kernel",
+		SER, MASK(MCI_STATUS_OVER|MCI_UC_SAR|MCI_ADDR|MCACOD, MCI_UC_SAR|MCI_ADDR|MCACOD_INSTR),
+		KERNEL
+		),
 #endif
 	MCESEV(
 		PANIC, "Action required: unknown MCACOD",
Signature · 1 line
2.19.1
#1 lore raw

[tip:ras/core] x86/mce: Improve error message when kernel cannot recover, p2

x86/mce: Improve error message when kernel cannot recover, p2
Commit-ID:  41f035a86b5b72a4f947c38e94239d20d595352a
Gitweb:     https://git.kernel.org/tip/41f035a86b5b72a4f947c38e94239d20d595352a
Author:     Tony Luck <[email protected]>
AuthorDate: Mon, 25 Feb 2019 12:59:40 -0800
Committer:  Borislav Petkov <[email protected]>
CommitDate: Mon, 25 Feb 2019 23:21:35 +0100

x86/mce: Improve error message when kernel cannot recover, p2

In

c7d606f560e4 ("x86/mce: Improve error message when kernel cannot recover")

a case was added for a machine check caused by a DATA access to poison memory from the kernel. A case should have been added also for an uncorrectable error during an instruction fetch in the kernel.

Add that extra case so the error message now reads:

mce: [Hardware Error]: Machine check: Instruction fetch error in kernel

Fixes c7d606f560e4 ("x86/mce: Improve error message when kernel cannot recover")
Cc "H. Peter Anvin" <[email protected]>
Cc Ingo Molnar <[email protected]>
Cc Pu Wen <[email protected]>
Cc Thomas Gleixner <[email protected]>
Cc x86-ml <[email protected]>
---
 arch/x86/kernel/cpu/mce/severity.c | 5 +++++
 1 file changed, 5 insertions(+)
arch/x86/kernel/cpu/mce/severity.c +5 -0
index dc3e26e905a3..65201e180fe0 100644
@@ -165,6 +165,11 @@ static struct severity {
 		SER, MASK(MCI_STATUS_OVER|MCI_UC_SAR|MCI_ADDR|MCACOD, MCI_UC_SAR|MCI_ADDR|MCACOD_DATA),
 		KERNEL
 		),
+	MCESEV(
+		PANIC, "Instruction fetch error in kernel",
+		SER, MASK(MCI_STATUS_OVER|MCI_UC_SAR|MCI_ADDR|MCACOD, MCI_UC_SAR|MCI_ADDR|MCACOD_INSTR),
+		KERNEL
+		),
 #endif
 	MCESEV(
 		PANIC, "Action required: unknown MCACOD",