diff options
author | Kumar Gala <galak@kernel.crashing.org> | 2006-05-05 01:02:08 -0400 |
---|---|---|
committer | Kumar Gala <galak@kernel.crashing.org> | 2006-05-05 01:02:08 -0400 |
commit | 7e990266c845d7f712c96013891aaf74baef198f (patch) | |
tree | 92bc569003abdfd53b53f1081132469d92497ded /arch/powerpc/kernel/setup_64.c | |
parent | 5a43ee65620d628ba04deecf241b63b2410b97f2 (diff) |
powerpc: provide ppc_md.panic() for both ppc32 & ppc64
Allow boards to provide a panic callback on ppc32. Moved the code to sets
this up into setup-common.c so its shared between ppc32 & ppc64. Also moved
do_init_bootmem prototype into setup.h.
Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
Diffstat (limited to 'arch/powerpc/kernel/setup_64.c')
-rw-r--r-- | arch/powerpc/kernel/setup_64.c | 18 |
1 files changed, 1 insertions, 17 deletions
diff --git a/arch/powerpc/kernel/setup_64.c b/arch/powerpc/kernel/setup_64.c index 4467c49903b6..ab6ea37a77aa 100644 --- a/arch/powerpc/kernel/setup_64.c +++ b/arch/powerpc/kernel/setup_64.c | |||
@@ -100,12 +100,6 @@ unsigned long SYSRQ_KEY; | |||
100 | #endif /* CONFIG_MAGIC_SYSRQ */ | 100 | #endif /* CONFIG_MAGIC_SYSRQ */ |
101 | 101 | ||
102 | 102 | ||
103 | static int ppc64_panic_event(struct notifier_block *, unsigned long, void *); | ||
104 | static struct notifier_block ppc64_panic_block = { | ||
105 | .notifier_call = ppc64_panic_event, | ||
106 | .priority = INT_MIN /* may not return; must be done last */ | ||
107 | }; | ||
108 | |||
109 | #ifdef CONFIG_SMP | 103 | #ifdef CONFIG_SMP |
110 | 104 | ||
111 | static int smt_enabled_cmdline; | 105 | static int smt_enabled_cmdline; |
@@ -456,13 +450,6 @@ void __init setup_system(void) | |||
456 | DBG(" <- setup_system()\n"); | 450 | DBG(" <- setup_system()\n"); |
457 | } | 451 | } |
458 | 452 | ||
459 | static int ppc64_panic_event(struct notifier_block *this, | ||
460 | unsigned long event, void *ptr) | ||
461 | { | ||
462 | ppc_md.panic((char *)ptr); /* May not return */ | ||
463 | return NOTIFY_DONE; | ||
464 | } | ||
465 | |||
466 | #ifdef CONFIG_IRQSTACKS | 453 | #ifdef CONFIG_IRQSTACKS |
467 | static void __init irqstack_early_init(void) | 454 | static void __init irqstack_early_init(void) |
468 | { | 455 | { |
@@ -517,8 +504,6 @@ static void __init emergency_stack_init(void) | |||
517 | */ | 504 | */ |
518 | void __init setup_arch(char **cmdline_p) | 505 | void __init setup_arch(char **cmdline_p) |
519 | { | 506 | { |
520 | extern void do_init_bootmem(void); | ||
521 | |||
522 | ppc64_boot_msg(0x12, "Setup Arch"); | 507 | ppc64_boot_msg(0x12, "Setup Arch"); |
523 | 508 | ||
524 | *cmdline_p = cmd_line; | 509 | *cmdline_p = cmd_line; |
@@ -535,8 +520,7 @@ void __init setup_arch(char **cmdline_p) | |||
535 | panic_timeout = 180; | 520 | panic_timeout = 180; |
536 | 521 | ||
537 | if (ppc_md.panic) | 522 | if (ppc_md.panic) |
538 | atomic_notifier_chain_register(&panic_notifier_list, | 523 | setup_panic(); |
539 | &ppc64_panic_block); | ||
540 | 524 | ||
541 | init_mm.start_code = PAGE_OFFSET; | 525 | init_mm.start_code = PAGE_OFFSET; |
542 | init_mm.end_code = (unsigned long) _etext; | 526 | init_mm.end_code = (unsigned long) _etext; |