]> git.karo-electronics.de Git - linux-beck.git/commitdiff
[POWERPC] Fix compilation for CONFIG_DEBUGGER=n and CONFIG_KEXEC=y
authorOlof Johansson <olof@lixom.net>
Thu, 31 Jan 2008 03:34:47 +0000 (14:34 +1100)
committerPaul Mackerras <paulus@samba.org>
Thu, 7 Feb 2008 00:40:18 +0000 (11:40 +1100)
Looks like "[POWERPC] kdump shutdown hook support" broke builds when
CONFIG_DEBUGGER=n and CONFIG_KEXEC=y, such as in g5_defconfig:

arch/powerpc/kernel/crash.c: In function 'default_machine_crash_shutdown':
arch/powerpc/kernel/crash.c:388: error: '__debugger_fault_handler' undeclared (first use in this function)
arch/powerpc/kernel/crash.c:388: error: (Each undeclared identifier is reported only once
arch/powerpc/kernel/crash.c:388: error: for each function it appears in.)

Move the debugger hooks to under CONFIG_DEBUGGER || CONFIG_KEXEC, since
that's when the crash code is enabled.

(I should have caught this with my build-script pre-merge, my bad. :( )

Signed-off-by: Olof Johansson <olof@lixom.net>
Signed-off-by: Paul Mackerras <paulus@samba.org>
arch/powerpc/kernel/traps.c
include/asm-powerpc/system.h

index 848a20475db8c29deafdfe12380b746d0d4613ad..4b5b7ff4f78bb0e4564718fd7836f3a1542dae9f 100644 (file)
@@ -54,7 +54,7 @@
 #endif
 #include <asm/kexec.h>
 
-#ifdef CONFIG_DEBUGGER
+#if defined(CONFIG_DEBUGGER) || defined(CONFIG_KEXEC)
 int (*__debugger)(struct pt_regs *regs);
 int (*__debugger_ipi)(struct pt_regs *regs);
 int (*__debugger_bpt)(struct pt_regs *regs);
index bc9739dff5e75cd9a808c895092b7e98066ceda0..8d37283db032153dfb53ab504c32cd3878e10828 100644 (file)
@@ -65,7 +65,7 @@
 struct task_struct;
 struct pt_regs;
 
-#ifdef CONFIG_DEBUGGER
+#if defined(CONFIG_DEBUGGER) || defined(CONFIG_KEXEC)
 
 extern int (*__debugger)(struct pt_regs *regs);
 extern int (*__debugger_ipi)(struct pt_regs *regs);