mirror of
https://github.com/adulau/aha.git
synced 2024-12-28 03:36:19 +00:00
[PATCH] lockdep: debug_locks check after check_chain_key
In __lock_acquire check_chain_key can turn off debug_locks, so check is needed to assure proper return code. Signed-off-by: Jarek Poplawski <jarkao2@o2.pl> Cc: Ingo Molnar <mingo@elte.hu> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
This commit is contained in:
parent
34173a4aad
commit
60e114d113
1 changed files with 4 additions and 0 deletions
|
@ -2228,6 +2228,10 @@ out_calc_hash:
|
|||
|
||||
curr->lockdep_depth++;
|
||||
check_chain_key(curr);
|
||||
#ifdef CONFIG_DEBUG_LOCKDEP
|
||||
if (unlikely(!debug_locks))
|
||||
return 0;
|
||||
#endif
|
||||
if (unlikely(curr->lockdep_depth >= MAX_LOCK_DEPTH)) {
|
||||
debug_locks_off();
|
||||
printk("BUG: MAX_LOCK_DEPTH too low!\n");
|
||||
|
|
Loading…
Reference in a new issue