aboutsummaryrefslogtreecommitdiffstats
path: root/arch/i386/kernel/traps.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/i386/kernel/traps.c')
-rw-r--r--arch/i386/kernel/traps.c16
1 files changed, 15 insertions, 1 deletions
diff --git a/arch/i386/kernel/traps.c b/arch/i386/kernel/traps.c
index e38527994590..2d22f5761b1d 100644
--- a/arch/i386/kernel/traps.c
+++ b/arch/i386/kernel/traps.c
@@ -365,6 +365,9 @@ void die(const char * str, struct pt_regs * regs, long err)
365 365
366 if (++die.lock_owner_depth < 3) { 366 if (++die.lock_owner_depth < 3) {
367 int nl = 0; 367 int nl = 0;
368 unsigned long esp;
369 unsigned short ss;
370
368 handle_BUG(regs); 371 handle_BUG(regs);
369 printk(KERN_EMERG "%s: %04lx [#%d]\n", str, err & 0xffff, ++die_counter); 372 printk(KERN_EMERG "%s: %04lx [#%d]\n", str, err & 0xffff, ++die_counter);
370#ifdef CONFIG_PREEMPT 373#ifdef CONFIG_PREEMPT
@@ -387,8 +390,19 @@ void die(const char * str, struct pt_regs * regs, long err)
387 printk("\n"); 390 printk("\n");
388 if (notify_die(DIE_OOPS, str, regs, err, 391 if (notify_die(DIE_OOPS, str, regs, err,
389 current->thread.trap_no, SIGSEGV) != 392 current->thread.trap_no, SIGSEGV) !=
390 NOTIFY_STOP) 393 NOTIFY_STOP) {
391 show_registers(regs); 394 show_registers(regs);
395 /* Executive summary in case the oops scrolled away */
396 esp = (unsigned long) (&regs->esp);
397 savesegment(ss, ss);
398 if (user_mode(regs)) {
399 esp = regs->esp;
400 ss = regs->xss & 0xffff;
401 }
402 printk(KERN_EMERG "EIP: [<%08lx>] ", regs->eip);
403 print_symbol("%s", regs->eip);
404 printk(" SS:ESP %04x:%08lx\n", ss, esp);
405 }
392 else 406 else
393 regs = NULL; 407 regs = NULL;
394 } else 408 } else