Skip to content

Commit 191f32d

Browse files
author
Fox Snowpatch
committed
1 parent 182544a commit 191f32d

1 file changed

Lines changed: 8 additions & 0 deletions

File tree

arch/powerpc/kernel/setup-common.c

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,7 @@
6868
#include <asm/kasan.h>
6969
#include <asm/mce.h>
7070
#include <asm/systemcfg.h>
71+
#include <linux/kmsg_dump.h>
7172

7273
#include "setup.h"
7374

@@ -744,6 +745,13 @@ static int ppc_panic_fadump_handler(struct notifier_block *this,
744745
*/
745746
hard_irq_disable();
746747

748+
/*
749+
* Invoke kmsg_dump (e.g., pstore) before crash_fadump() as fadump
750+
* runs before panic()'s kmsg_dump_desc() call.
751+
*/
752+
if (should_fadump_crash())
753+
kmsg_dump_desc(KMSG_DUMP_PANIC, (char *)ptr);
754+
747755
/*
748756
* If firmware-assisted dump has been registered then trigger
749757
* its callback and let the firmware handles everything else.

0 commit comments

Comments
 (0)