diff options
author | Heiko Carstens <heiko.carstens@de.ibm.com> | 2015-02-18 08:17:14 -0500 |
---|---|---|
committer | Martin Schwidefsky <schwidefsky@de.ibm.com> | 2015-03-25 06:49:38 -0400 |
commit | e1d12d70f7467c3b26cbd0c14139dcddec88448d (patch) | |
tree | 17af8e9ac0d160e0a3fab79549e76b14744935ca /arch/s390 | |
parent | 86cd741bc6ed0edf6ea0e8ec5c840cf9e3f3a7cb (diff) |
s390/traps: panic() instead of die() on translation exception
In case of a translation exception the page tables are corrupted. If the
exception handler then calls die() which again calls show_regs()
-> show_code() -> copy_from_user(), the kernel may access the same memory
location again and generates yet another translation exception. Which in turn
will lead to a deadlock on the die_lock spinlock, which the kernel tries to
grab recursively.
Given that the page tables are corrupted anyway, if we see such an exception,
let's simply panic.
Signed-off-by: Heiko Carstens <heiko.carstens@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
Diffstat (limited to 'arch/s390')
-rw-r--r-- | arch/s390/kernel/traps.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/s390/kernel/traps.c b/arch/s390/kernel/traps.c index 8be11c22ed17..4d96c9f53455 100644 --- a/arch/s390/kernel/traps.c +++ b/arch/s390/kernel/traps.c | |||
@@ -174,7 +174,7 @@ static inline void do_fp_trap(struct pt_regs *regs, int fpc) | |||
174 | void translation_exception(struct pt_regs *regs) | 174 | void translation_exception(struct pt_regs *regs) |
175 | { | 175 | { |
176 | /* May never happen. */ | 176 | /* May never happen. */ |
177 | die(regs, "Translation exception"); | 177 | panic("Translation exception"); |
178 | } | 178 | } |
179 | 179 | ||
180 | void illegal_op(struct pt_regs *regs) | 180 | void illegal_op(struct pt_regs *regs) |