Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 26559
b: refs/heads/master
c: cdc60a4
h: refs/heads/master
i:
  26557: edd9457
  26555: da57f35
  26551: fc67830
  26543: ffcd929
  26527: c5140ea
  26495: 7bd44c4
v: v3
  • Loading branch information
Corey Minyard authored and Linus Torvalds committed May 8, 2006
1 parent 179375c commit 6db1b83
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 5192d84e4c32cd335fd572e5ff0712041f45f7e7
refs/heads/master: cdc60a4c8e71c4bcf67e83fac6c0cabd0ff19bfe
10 changes: 9 additions & 1 deletion trunk/arch/x86_64/kernel/traps.c
Original file line number Diff line number Diff line change
Expand Up @@ -385,6 +385,7 @@ void out_of_line_bug(void)

static DEFINE_SPINLOCK(die_lock);
static int die_owner = -1;
static unsigned int die_nest_count;

unsigned __kprobes long oops_begin(void)
{
Expand All @@ -399,6 +400,7 @@ unsigned __kprobes long oops_begin(void)
else
spin_lock(&die_lock);
}
die_nest_count++;
die_owner = cpu;
console_verbose();
bust_spinlocks(1);
Expand All @@ -409,7 +411,13 @@ void __kprobes oops_end(unsigned long flags)
{
die_owner = -1;
bust_spinlocks(0);
spin_unlock_irqrestore(&die_lock, flags);
die_nest_count--;
if (die_nest_count)
/* We still own the lock */
local_irq_restore(flags);
else
/* Nest count reaches zero, release the lock. */
spin_unlock_irqrestore(&die_lock, flags);
if (panic_on_oops)
panic("Oops");
}
Expand Down

0 comments on commit 6db1b83

Please sign in to comment.