Skip to contentSkip to conversation

powerpc: dump kernel log before carrying out fadump or kdump

PATCH Superseded Ganesh Goudar 2 participants 2 messages Aug 22, 2019 – Aug 27, 2019 PowerPC

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 powerpc: dump kernel log before carrying out fadump or kdump

Die or panic path in system reset handler dumps kernel log to nvram, since commit 4388c9b3a6ee ("powerpc: Do not send system reset request through the oops path") system reset request is not allowed to take die path if fadump or kdump is configured, hence we miss dumping kernel log to nvram, call kmsg_dump() before carrying out fadump or kdump.

Fixes 4388c9b3a6ee ("powerpc: Do not send system reset request through the oops path")
---
 arch/powerpc/kernel/traps.c | 1 +
 1 file changed, 1 insertion(+)
arch/powerpc/kernel/traps.c +1 -0
index 11caa0291254..82f43535e686 100644
@@ -472,6 +472,7 @@ void system_reset_exception(struct pt_regs *regs)
 	if (debugger(regs))
 		goto out;
 
+	kmsg_dump(KMSG_DUMP_OOPS);
 	/*
 	 * A system reset is a request to dump, so we always send
 	 * it through the crashdump code (if fadump or kdump are
Signature · 1 line
2.17.2
reviewer Reviewed-by on v1 1/1
#1 lore raw

Ganesh Goudar's on August 22, 2019 4:31 pm:

Quoted 10 lines

Die or panic path in system reset handler dumps kernel log to nvram, since commit 4388c9b3a6ee ("powerpc: Do not send system reset request through the oops path") system reset request is not allowed to take die path if fadump or kdump is configured, hence we miss dumping kernel log to nvram, call kmsg_dump() before carrying out fadump or kdump.

Fixes 4388c9b3a6ee ("powerpc: Do not send system reset request through the oops path")