]> Pileus Git - ~andy/linux/blobdiff - arch/powerpc/kernel/setup-common.c
fadump: Convert firmware-assisted cpu state dump data into elf notes.
[~andy/linux] / arch / powerpc / kernel / setup-common.c
index 77bb77da05c1d5ad35ef17788f26cbe2878135a4..4e62a56e1a954f2569e4a21a3558b02ea7310e9c 100644 (file)
@@ -61,6 +61,7 @@
 #include <asm/xmon.h>
 #include <asm/cputhreads.h>
 #include <mm/mmu_decl.h>
+#include <asm/fadump.h>
 
 #include "setup.h"
 
@@ -639,6 +640,11 @@ EXPORT_SYMBOL(check_legacy_ioport);
 static int ppc_panic_event(struct notifier_block *this,
                              unsigned long event, void *ptr)
 {
+       /*
+        * If firmware-assisted dump has been registered then trigger
+        * firmware-assisted dump and let firmware handle everything else.
+        */
+       crash_fadump(NULL, ptr);
        ppc_md.panic(ptr);  /* May not return */
        return NOTIFY_DONE;
 }