diff options
Diffstat (limited to 'arch/sh/kernel/traps_64.c')
-rw-r--r-- | arch/sh/kernel/traps_64.c | 31 |
1 files changed, 0 insertions, 31 deletions
diff --git a/arch/sh/kernel/traps_64.c b/arch/sh/kernel/traps_64.c index c902c29400a3..75bef61892d2 100644 --- a/arch/sh/kernel/traps_64.c +++ b/arch/sh/kernel/traps_64.c | |||
@@ -41,37 +41,6 @@ asmlinkage void do_##name(unsigned long error_code, struct pt_regs *regs) \ | |||
41 | do_unhandled_exception(trapnr, signr, str, __stringify(name), error_code, regs, current); \ | 41 | do_unhandled_exception(trapnr, signr, str, __stringify(name), error_code, regs, current); \ |
42 | } | 42 | } |
43 | 43 | ||
44 | static DEFINE_SPINLOCK(die_lock); | ||
45 | |||
46 | void die(const char * str, struct pt_regs * regs, long err) | ||
47 | { | ||
48 | console_verbose(); | ||
49 | spin_lock_irq(&die_lock); | ||
50 | printk("%s: %lx\n", str, (err & 0xffffff)); | ||
51 | show_regs(regs); | ||
52 | spin_unlock_irq(&die_lock); | ||
53 | do_exit(SIGSEGV); | ||
54 | } | ||
55 | |||
56 | static inline void die_if_kernel(const char * str, struct pt_regs * regs, long err) | ||
57 | { | ||
58 | if (!user_mode(regs)) | ||
59 | die(str, regs, err); | ||
60 | } | ||
61 | |||
62 | static void die_if_no_fixup(const char * str, struct pt_regs * regs, long err) | ||
63 | { | ||
64 | if (!user_mode(regs)) { | ||
65 | const struct exception_table_entry *fixup; | ||
66 | fixup = search_exception_tables(regs->pc); | ||
67 | if (fixup) { | ||
68 | regs->pc = fixup->fixup; | ||
69 | return; | ||
70 | } | ||
71 | die(str, regs, err); | ||
72 | } | ||
73 | } | ||
74 | |||
75 | DO_ERROR(13, SIGILL, "illegal slot instruction", illegal_slot_inst, current) | 44 | DO_ERROR(13, SIGILL, "illegal slot instruction", illegal_slot_inst, current) |
76 | DO_ERROR(87, SIGSEGV, "address error (exec)", address_error_exec, current) | 45 | DO_ERROR(87, SIGSEGV, "address error (exec)", address_error_exec, current) |
77 | 46 | ||