diff options
-rw-r--r-- | arch/arm/mm/fault.c | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/arch/arm/mm/fault.c b/arch/arm/mm/fault.c index 564b1c4829e4..5835e63454ff 100644 --- a/arch/arm/mm/fault.c +++ b/arch/arm/mm/fault.c | |||
@@ -475,12 +475,7 @@ static struct fsr_info { | |||
475 | { do_bad, SIGBUS, BUS_ADRALN, "alignment exception" }, | 475 | { do_bad, SIGBUS, BUS_ADRALN, "alignment exception" }, |
476 | { do_bad, SIGKILL, 0, "terminal exception" }, | 476 | { do_bad, SIGKILL, 0, "terminal exception" }, |
477 | { do_bad, SIGBUS, BUS_ADRALN, "alignment exception" }, | 477 | { do_bad, SIGBUS, BUS_ADRALN, "alignment exception" }, |
478 | /* Do we need runtime check ? */ | ||
479 | #if __LINUX_ARM_ARCH__ < 6 | ||
480 | { do_bad, SIGBUS, 0, "external abort on linefetch" }, | 478 | { do_bad, SIGBUS, 0, "external abort on linefetch" }, |
481 | #else | ||
482 | { do_translation_fault, SIGSEGV, SEGV_MAPERR, "I-cache maintenance fault" }, | ||
483 | #endif | ||
484 | { do_translation_fault, SIGSEGV, SEGV_MAPERR, "section translation fault" }, | 479 | { do_translation_fault, SIGSEGV, SEGV_MAPERR, "section translation fault" }, |
485 | { do_bad, SIGBUS, 0, "external abort on linefetch" }, | 480 | { do_bad, SIGBUS, 0, "external abort on linefetch" }, |
486 | { do_page_fault, SIGSEGV, SEGV_MAPERR, "page translation fault" }, | 481 | { do_page_fault, SIGSEGV, SEGV_MAPERR, "page translation fault" }, |
@@ -605,3 +600,14 @@ do_PrefetchAbort(unsigned long addr, unsigned int ifsr, struct pt_regs *regs) | |||
605 | arm_notify_die("", regs, &info, ifsr, 0); | 600 | arm_notify_die("", regs, &info, ifsr, 0); |
606 | } | 601 | } |
607 | 602 | ||
603 | static int __init exceptions_init(void) | ||
604 | { | ||
605 | if (cpu_architecture() >= CPU_ARCH_ARMv6) { | ||
606 | hook_fault_code(4, do_translation_fault, SIGSEGV, SEGV_MAPERR, | ||
607 | "I-cache maintenance fault"); | ||
608 | } | ||
609 | |||
610 | return 0; | ||
611 | } | ||
612 | |||
613 | arch_initcall(exceptions_init); | ||