aboutsummaryrefslogtreecommitdiffstats
path: root/arch/mips/kernel/traps.c
diff options
context:
space:
mode:
authorThomas Bogendoerfer <tsbogend@alpha.franken.de>2008-08-04 13:44:34 -0400
committerRalf Baechle <ralf@linux-mips.org>2008-09-05 16:24:11 -0400
commit0510617b85758b6e66f3c602ceccea1826440470 (patch)
treeb5b3c9750ca2b92d65f059692c56fbb45c9426e0 /arch/mips/kernel/traps.c
parentb380b0d4f7dffcc235c0facefa537d4655619101 (diff)
[MIPS] Fix data bus error recovery
With -ffunction-section the entries in __dbe_table aren't no longer sorted, so the lookup of exception addresses in do_be() failed for some addresses. To avoid this we now sort __dbe_table. Signed-off-by: Thomas Bogendoerfer <tsbogend@alpha.franken.de> Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Diffstat (limited to 'arch/mips/kernel/traps.c')
-rw-r--r--arch/mips/kernel/traps.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/arch/mips/kernel/traps.c b/arch/mips/kernel/traps.c
index 426cced1e9dc..1f579a8ea25b 100644
--- a/arch/mips/kernel/traps.c
+++ b/arch/mips/kernel/traps.c
@@ -373,8 +373,8 @@ void __noreturn die(const char * str, const struct pt_regs * regs)
373 do_exit(SIGSEGV); 373 do_exit(SIGSEGV);
374} 374}
375 375
376extern const struct exception_table_entry __start___dbe_table[]; 376extern struct exception_table_entry __start___dbe_table[];
377extern const struct exception_table_entry __stop___dbe_table[]; 377extern struct exception_table_entry __stop___dbe_table[];
378 378
379__asm__( 379__asm__(
380" .section __dbe_table, \"a\"\n" 380" .section __dbe_table, \"a\"\n"
@@ -1682,4 +1682,6 @@ void __init trap_init(void)
1682 1682
1683 flush_icache_range(ebase, ebase + 0x400); 1683 flush_icache_range(ebase, ebase + 0x400);
1684 flush_tlb_handlers(); 1684 flush_tlb_handlers();
1685
1686 sort_extable(__start___dbe_table, __stop___dbe_table);
1685} 1687}