X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=include%2Flinux%2Flockdep.h;h=14c937d345cb135916fff7a44878a631b9ae3813;hb=e3a55fd18deab758a2970e0dfcd60a677a920426;hp=7e1160dde5e7cd052fcf67ac2852f7ecc1bb7062;hpb=cb18eccff48ef3986d1072964590bce6fec705fb;p=linux-2.6 diff --git a/include/linux/lockdep.h b/include/linux/lockdep.h index 7e1160dde5..14c937d345 100644 --- a/include/linux/lockdep.h +++ b/include/linux/lockdep.h @@ -8,6 +8,8 @@ #ifndef __LINUX_LOCKDEP_H #define __LINUX_LOCKDEP_H +struct task_struct; + #ifdef CONFIG_LOCKDEP #include @@ -243,7 +245,7 @@ extern void lock_release(struct lockdep_map *lock, int nested, # 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 */