Commit:     e3a55fd18deab758a2970e0dfcd60a677a920426
Parent:     058560fbd70190ea6b50b5df4d814bc30911d06b
Author:     Jarek Poplawski <[EMAIL PROTECTED]>
AuthorDate: Thu Mar 22 00:11:26 2007 -0800
Committer:  Linus Torvalds <[EMAIL PROTECTED]>
CommitDate: Thu Mar 22 19:39:06 2007 -0700

    [PATCH] lockdep: lockdep_depth vs. debug_locks
    lockdep found a bug during a run of workqueue function - this could be also
    caused by a bug from other code running simultaneously.
    lockdep really shouldn't be used when debug_locks == 0!
    Reported-by: Folkert van Heusden <[EMAIL PROTECTED]>
    Inspired-by: Oleg Nesterov <[EMAIL PROTECTED]>
    Signed-off-by: Jarek Poplawski <[EMAIL PROTECTED]>
    Cc: Ingo Molnar <[EMAIL PROTECTED]>
    Acked-by: Peter Zijlstra <[EMAIL PROTECTED]>
    Signed-off-by: Andrew Morton <[EMAIL PROTECTED]>
    Signed-off-by: Linus Torvalds <[EMAIL PROTECTED]>
 include/linux/lockdep.h |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/include/linux/lockdep.h b/include/linux/lockdep.h
index 06fe93a..14c937d 100644
--- a/include/linux/lockdep.h
+++ b/include/linux/lockdep.h
@@ -245,7 +245,7 @@ extern void lock_release(struct lockdep_map *lock, int 
 # define INIT_LOCKDEP                          .lockdep_recursion = 0,
-#define lockdep_depth(tsk)     ((tsk)->lockdep_depth)
+#define lockdep_depth(tsk)     (debug_locks ? (tsk)->lockdep_depth : 0)
 #else /* !LOCKDEP */
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at

Reply via email to