summaryrefslogtreecommitdiff
path: root/include/net/af_unix.h
diff options
context:
space:
mode:
authorIngo Molnar <mingo@elte.hu>2006-07-03 11:25:12 +0400
committerLinus Torvalds <torvalds@g5.osdl.org>2006-07-04 02:27:07 +0400
commita09785a2414afb261d9f719d544742af4300df22 (patch)
treea9fcbd82e9610cb77e7a2e1338ab901876dbcea8 /include/net/af_unix.h
parentda21f24dd73954c2ed0cd39a698e2c9916c05d71 (diff)
downloadlinux-a09785a2414afb261d9f719d544742af4300df22.tar.xz
[PATCH] lockdep: annotate af_unix locking
Teach special (recursive) locking code to the lock validator. Also splits af_unix's sk_receive_queue.lock class from the other networking skb-queue locks. Has no effect on non-lockdep kernels. Signed-off-by: Ingo Molnar <mingo@elte.hu> Signed-off-by: Arjan van de Ven <arjan@linux.intel.com> Cc: "David S. Miller" <davem@davemloft.net> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'include/net/af_unix.h')
-rw-r--r--include/net/af_unix.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/include/net/af_unix.h b/include/net/af_unix.h
index 5ba72d95280c..2fec827c8801 100644
--- a/include/net/af_unix.h
+++ b/include/net/af_unix.h
@@ -67,6 +67,9 @@ struct unix_skb_parms {
#define unix_state_rlock(s) spin_lock(&unix_sk(s)->lock)
#define unix_state_runlock(s) spin_unlock(&unix_sk(s)->lock)
#define unix_state_wlock(s) spin_lock(&unix_sk(s)->lock)
+#define unix_state_wlock_nested(s) \
+ spin_lock_nested(&unix_sk(s)->lock, \
+ SINGLE_DEPTH_NESTING)
#define unix_state_wunlock(s) spin_unlock(&unix_sk(s)->lock)
#ifdef __KERNEL__