diff options
author | Peter Zijlstra <a.p.zijlstra@chello.nl> | 2011-07-07 05:39:45 -0400 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2011-07-21 14:43:16 -0400 |
commit | efbe2eee6dc0f179be84292bf269528b3ec365e9 (patch) | |
tree | 40996bc1d349f1747a5dd0261bdc1c84db2631de /kernel/lockdep.c | |
parent | 4582c0a4866ea70c35aa9279e1f91834d3348a93 (diff) |
lockdep: Fix lockdep_no_validate against IRQ states
Thomas noticed that a lock marked with lockdep_set_novalidate_class()
will still trigger warnings for IRQ inversions. Cure this by skipping
those when marking irq state.
Reported-and-tested-by: Thomas Gleixner <tglx@linutronix.de>
Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
Link: http://lkml.kernel.org/n/tip-2dp5vmpsxeraqm42kgww6ge2@git.kernel.org
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'kernel/lockdep.c')
-rw-r--r-- | kernel/lockdep.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/kernel/lockdep.c b/kernel/lockdep.c index 298c9276dfdb..628276d05915 100644 --- a/kernel/lockdep.c +++ b/kernel/lockdep.c | |||
@@ -2468,6 +2468,9 @@ mark_held_locks(struct task_struct *curr, enum mark_type mark) | |||
2468 | 2468 | ||
2469 | BUG_ON(usage_bit >= LOCK_USAGE_STATES); | 2469 | BUG_ON(usage_bit >= LOCK_USAGE_STATES); |
2470 | 2470 | ||
2471 | if (hlock_class(hlock)->key == &__lockdep_no_validate__) | ||
2472 | continue; | ||
2473 | |||
2471 | if (!mark_lock(curr, hlock, usage_bit)) | 2474 | if (!mark_lock(curr, hlock, usage_bit)) |
2472 | return 0; | 2475 | return 0; |
2473 | } | 2476 | } |