diff options
Diffstat (limited to 'arch/powerpc/kernel/setup-common.c')
-rw-r--r-- | arch/powerpc/kernel/setup-common.c | 20 |
1 files changed, 19 insertions, 1 deletions
diff --git a/arch/powerpc/kernel/setup-common.c b/arch/powerpc/kernel/setup-common.c index 684ab1d49c65..bd328123af75 100644 --- a/arch/powerpc/kernel/setup-common.c +++ b/arch/powerpc/kernel/setup-common.c | |||
@@ -443,6 +443,7 @@ void __init smp_setup_cpu_maps(void) | |||
443 | } | 443 | } |
444 | #endif /* CONFIG_SMP */ | 444 | #endif /* CONFIG_SMP */ |
445 | 445 | ||
446 | int __initdata do_early_xmon; | ||
446 | #ifdef CONFIG_XMON | 447 | #ifdef CONFIG_XMON |
447 | static int __init early_xmon(char *p) | 448 | static int __init early_xmon(char *p) |
448 | { | 449 | { |
@@ -456,7 +457,7 @@ static int __init early_xmon(char *p) | |||
456 | return 0; | 457 | return 0; |
457 | } | 458 | } |
458 | xmon_init(1); | 459 | xmon_init(1); |
459 | debugger(NULL); | 460 | do_early_xmon = 1; |
460 | 461 | ||
461 | return 0; | 462 | return 0; |
462 | } | 463 | } |
@@ -524,3 +525,20 @@ int check_legacy_ioport(unsigned long base_port) | |||
524 | return ppc_md.check_legacy_ioport(base_port); | 525 | return ppc_md.check_legacy_ioport(base_port); |
525 | } | 526 | } |
526 | EXPORT_SYMBOL(check_legacy_ioport); | 527 | EXPORT_SYMBOL(check_legacy_ioport); |
528 | |||
529 | static int ppc_panic_event(struct notifier_block *this, | ||
530 | unsigned long event, void *ptr) | ||
531 | { | ||
532 | ppc_md.panic(ptr); /* May not return */ | ||
533 | return NOTIFY_DONE; | ||
534 | } | ||
535 | |||
536 | static struct notifier_block ppc_panic_block = { | ||
537 | .notifier_call = ppc_panic_event, | ||
538 | .priority = INT_MIN /* may not return; must be done last */ | ||
539 | }; | ||
540 | |||
541 | void __init setup_panic(void) | ||
542 | { | ||
543 | atomic_notifier_chain_register(&panic_notifier_list, &ppc_panic_block); | ||
544 | } | ||