diff options
author | Alexander van Heukelum <heukelum@mailshack.com> | 2008-07-01 19:31:03 -0400 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2008-07-09 02:17:49 -0400 |
commit | e423f49fc8ccd761618748d7139638d8ddc1d16f (patch) | |
tree | c781aa3984ac1c87c0f59d5e37e701237fc75caa /arch/x86/kernel/traps_32.c | |
parent | badc76527f7e29302f0bde3d366c59101fb2ab87 (diff) |
x86: traps_xx: modify __die
if (cond) block -> if (!cond) goto end_of_block
Signed-off-by: Alexander van Heukelum <heukelum@fastmail.fm>
Acked-by: Cyrill Gorcunov <gorcunov@gmail.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'arch/x86/kernel/traps_32.c')
-rw-r--r-- | arch/x86/kernel/traps_32.c | 30 |
1 files changed, 13 insertions, 17 deletions
diff --git a/arch/x86/kernel/traps_32.c b/arch/x86/kernel/traps_32.c index 5339af459a38..5afd94a01b98 100644 --- a/arch/x86/kernel/traps_32.c +++ b/arch/x86/kernel/traps_32.c | |||
@@ -399,26 +399,22 @@ int __kprobes __die(const char *str, struct pt_regs *regs, long err) | |||
399 | printk("DEBUG_PAGEALLOC"); | 399 | printk("DEBUG_PAGEALLOC"); |
400 | #endif | 400 | #endif |
401 | printk("\n"); | 401 | printk("\n"); |
402 | |||
403 | if (notify_die(DIE_OOPS, str, regs, err, | 402 | if (notify_die(DIE_OOPS, str, regs, err, |
404 | current->thread.trap_no, SIGSEGV) != NOTIFY_STOP) { | 403 | current->thread.trap_no, SIGSEGV) == NOTIFY_STOP) |
405 | 404 | return 1; | |
406 | show_registers(regs); | ||
407 | /* Executive summary in case the oops scrolled away */ | ||
408 | sp = (unsigned long) (®s->sp); | ||
409 | savesegment(ss, ss); | ||
410 | if (user_mode(regs)) { | ||
411 | sp = regs->sp; | ||
412 | ss = regs->ss & 0xffff; | ||
413 | } | ||
414 | printk(KERN_EMERG "EIP: [<%08lx>] ", regs->ip); | ||
415 | print_symbol("%s", regs->ip); | ||
416 | printk(" SS:ESP %04x:%08lx\n", ss, sp); | ||
417 | 405 | ||
418 | return 0; | 406 | show_registers(regs); |
407 | /* Executive summary in case the oops scrolled away */ | ||
408 | sp = (unsigned long) (®s->sp); | ||
409 | savesegment(ss, ss); | ||
410 | if (user_mode(regs)) { | ||
411 | sp = regs->sp; | ||
412 | ss = regs->ss & 0xffff; | ||
419 | } | 413 | } |
420 | 414 | printk(KERN_EMERG "EIP: [<%08lx>] ", regs->ip); | |
421 | return 1; | 415 | print_symbol("%s", regs->ip); |
416 | printk(" SS:ESP %04x:%08lx\n", ss, sp); | ||
417 | return 0; | ||
422 | } | 418 | } |
423 | 419 | ||
424 | /* | 420 | /* |