summaryrefslogtreecommitdiffstats
path: root/arch/blackfin/kernel/traps.c
diff options
context:
space:
mode:
authorRobin Getz <robin.getz@analog.com>2007-10-09 11:24:30 +0200
committerBryan Wu <bryan.wu@analog.com>2007-10-09 11:24:30 +0200
commit2ebcade590dcf822dcdadcc4f8f68efd3ff2e217 (patch)
tree38532077386784de87ac65aba73e22c399c96ecb /arch/blackfin/kernel/traps.c
parentBlackfin arch: Initial patch to add earlyprintk support (diff)
downloadlinux-2ebcade590dcf822dcdadcc4f8f68efd3ff2e217.tar.xz
linux-2ebcade590dcf822dcdadcc4f8f68efd3ff2e217.zip
Blackfin arch: fix endless loop bug when a double fault happens
Today when a double fault happens (exception during an exception handling event), we go into an endless loop, with nothing comming out the UART. With this patch, we actually see that we have commited a double fault event Signed-off-by: Robin Getz <robin.getz@analog.com> Signed-off-by: Bryan Wu <bryan.wu@analog.com>
Diffstat (limited to 'arch/blackfin/kernel/traps.c')
-rw-r--r--arch/blackfin/kernel/traps.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/arch/blackfin/kernel/traps.c b/arch/blackfin/kernel/traps.c
index 1a8a5f171bc8..ba68eb2ec929 100644
--- a/arch/blackfin/kernel/traps.c
+++ b/arch/blackfin/kernel/traps.c
@@ -132,6 +132,14 @@ static int printk_address(unsigned long address)
}
#endif
+asmlinkage void double_fault_c(struct pt_regs *fp)
+{
+ printk(KERN_EMERG "\n" KERN_EMERG "Double Fault\n");
+ dump_bfin_regs(fp, (void *)fp->retx);
+ panic("Double Fault - unrecoverable event\n");
+
+}
+
asmlinkage void trap_c(struct pt_regs *fp)
{
#ifdef CONFIG_DEBUG_BFIN_HWTRACE_ON