diff options
author | Haavard Skinnemoen <haavard.skinnemoen@atmel.com> | 2008-03-13 23:52:13 +0100 |
---|---|---|
committer | Haavard Skinnemoen <haavard.skinnemoen@atmel.com> | 2008-03-13 23:56:15 +0100 |
commit | 957ecd7dc835d40d110e8c8f460d1956420f86b1 (patch) | |
tree | 385285c2f3213813b442228e36a56eb65f798106 /arch/avr32/kernel | |
parent | bafe68034e3ef5e9f512bd0468001caf34981c41 (diff) | |
download | talos-obmc-linux-957ecd7dc835d40d110e8c8f460d1956420f86b1.tar.gz talos-obmc-linux-957ecd7dc835d40d110e8c8f460d1956420f86b1.zip |
avr32: Build fix for CONFIG_BUG=n
Don't include the BUG trap handling code when CONFIG_BUG is not set.
This fixes allnoconfig.
Signed-off-by: Haavard Skinnemoen <haavard.skinnemoen@atmel.com>
Diffstat (limited to 'arch/avr32/kernel')
-rw-r--r-- | arch/avr32/kernel/traps.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/arch/avr32/kernel/traps.c b/arch/avr32/kernel/traps.c index cf6f686d9b0b..b835c4c01368 100644 --- a/arch/avr32/kernel/traps.c +++ b/arch/avr32/kernel/traps.c @@ -178,6 +178,7 @@ static int do_cop_absent(u32 insn) return 0; } +#ifdef CONFIG_BUG int is_valid_bugaddr(unsigned long pc) { unsigned short opcode; @@ -189,6 +190,7 @@ int is_valid_bugaddr(unsigned long pc) return opcode == AVR32_BUG_OPCODE; } +#endif asmlinkage void do_illegal_opcode(unsigned long ecr, struct pt_regs *regs) { @@ -197,6 +199,7 @@ asmlinkage void do_illegal_opcode(unsigned long ecr, struct pt_regs *regs) void __user *pc; long code; +#ifdef CONFIG_BUG if (!user_mode(regs) && (ecr == ECR_ILLEGAL_OPCODE)) { enum bug_trap_type type; @@ -211,6 +214,7 @@ asmlinkage void do_illegal_opcode(unsigned long ecr, struct pt_regs *regs) die("Kernel BUG", regs, SIGKILL); } } +#endif local_irq_enable(); |