aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--arch/powerpc/include/asm/kexec.h1
-rw-r--r--arch/powerpc/kernel/crash.c21
2 files changed, 3 insertions, 19 deletions
diff --git a/arch/powerpc/include/asm/kexec.h b/arch/powerpc/include/asm/kexec.h
index 209ed8ba163..16d7e33d35e 100644
--- a/arch/powerpc/include/asm/kexec.h
+++ b/arch/powerpc/include/asm/kexec.h
@@ -49,7 +49,6 @@
49#define KEXEC_STATE_REAL_MODE 2 49#define KEXEC_STATE_REAL_MODE 2
50 50
51#ifndef __ASSEMBLY__ 51#ifndef __ASSEMBLY__
52#include <linux/cpumask.h>
53#include <asm/reg.h> 52#include <asm/reg.h>
54 53
55typedef void (*crash_shutdown_t)(void); 54typedef void (*crash_shutdown_t)(void);
diff --git a/arch/powerpc/kernel/crash.c b/arch/powerpc/kernel/crash.c
index a8b6e2d705a..d4467557b00 100644
--- a/arch/powerpc/kernel/crash.c
+++ b/arch/powerpc/kernel/crash.c
@@ -10,41 +10,27 @@
10 * 10 *
11 */ 11 */
12 12
13#undef DEBUG
14
15#include <linux/kernel.h> 13#include <linux/kernel.h>
16#include <linux/smp.h> 14#include <linux/smp.h>
17#include <linux/reboot.h> 15#include <linux/reboot.h>
18#include <linux/kexec.h> 16#include <linux/kexec.h>
19#include <linux/bootmem.h>
20#include <linux/export.h> 17#include <linux/export.h>
21#include <linux/crash_dump.h> 18#include <linux/crash_dump.h>
22#include <linux/delay.h> 19#include <linux/delay.h>
23#include <linux/elf.h>
24#include <linux/elfcore.h>
25#include <linux/init.h> 20#include <linux/init.h>
26#include <linux/irq.h> 21#include <linux/irq.h>
27#include <linux/types.h> 22#include <linux/types.h>
28#include <linux/memblock.h>
29 23
30#include <asm/processor.h> 24#include <asm/processor.h>
31#include <asm/machdep.h> 25#include <asm/machdep.h>
32#include <asm/kexec.h> 26#include <asm/kexec.h>
33#include <asm/kdump.h> 27#include <asm/kdump.h>
34#include <asm/prom.h> 28#include <asm/prom.h>
35#include <asm/firmware.h>
36#include <asm/smp.h> 29#include <asm/smp.h>
37#include <asm/system.h> 30#include <asm/system.h>
38#include <asm/setjmp.h> 31#include <asm/setjmp.h>
39 32
40#ifdef DEBUG 33/* This keeps a track of which one is the crashing cpu. */
41#include <asm/udbg.h>
42#define DBG(fmt...) udbg_printf(fmt)
43#else
44#define DBG(fmt...)
45#endif
46
47/* This keeps a track of which one is crashing cpu. */
48int crashing_cpu = -1; 34int crashing_cpu = -1;
49static cpumask_t cpus_in_crash = CPU_MASK_NONE; 35static cpumask_t cpus_in_crash = CPU_MASK_NONE;
50 36
@@ -201,7 +187,7 @@ void crash_kexec_secondary(struct pt_regs *regs)
201static void crash_kexec_prepare_cpus(int cpu) 187static void crash_kexec_prepare_cpus(int cpu)
202{ 188{
203 /* 189 /*
204 * move the secondarys to us so that we can copy 190 * move the secondaries to us so that we can copy
205 * the new kernel 0-0x100 safely 191 * the new kernel 0-0x100 safely
206 * 192 *
207 * do this if kexec in setup.c ? 193 * do this if kexec in setup.c ?
@@ -302,7 +288,6 @@ void default_machine_crash_shutdown(struct pt_regs *regs)
302 unsigned int i; 288 unsigned int i;
303 int (*old_handler)(struct pt_regs *regs); 289 int (*old_handler)(struct pt_regs *regs);
304 290
305
306 /* 291 /*
307 * This function is only called after the system 292 * This function is only called after the system
308 * has panicked or is otherwise in a critical state. 293 * has panicked or is otherwise in a critical state.
@@ -328,7 +313,7 @@ void default_machine_crash_shutdown(struct pt_regs *regs)
328 machine_kexec_mask_interrupts(); 313 machine_kexec_mask_interrupts();
329 314
330 /* 315 /*
331 * Call registered shutdown routines savely. Swap out 316 * Call registered shutdown routines safely. Swap out
332 * __debugger_fault_handler, and replace on exit. 317 * __debugger_fault_handler, and replace on exit.
333 */ 318 */
334 old_handler = __debugger_fault_handler; 319 old_handler = __debugger_fault_handler;