diff options
Diffstat (limited to 'include/net/af_unix.h')
-rw-r--r-- | include/net/af_unix.h | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/include/net/af_unix.h b/include/net/af_unix.h index b5d785ab4a0e..bfc1779fc753 100644 --- a/include/net/af_unix.h +++ b/include/net/af_unix.h | |||
@@ -13,7 +13,7 @@ extern void unix_gc(void); | |||
13 | #define UNIX_HASH_SIZE 256 | 13 | #define UNIX_HASH_SIZE 256 |
14 | 14 | ||
15 | extern struct hlist_head unix_socket_table[UNIX_HASH_SIZE + 1]; | 15 | extern struct hlist_head unix_socket_table[UNIX_HASH_SIZE + 1]; |
16 | extern rwlock_t unix_table_lock; | 16 | extern spinlock_t unix_table_lock; |
17 | 17 | ||
18 | extern atomic_t unix_tot_inflight; | 18 | extern atomic_t unix_tot_inflight; |
19 | 19 | ||
@@ -58,10 +58,10 @@ struct unix_skb_parms { | |||
58 | #define UNIXCB(skb) (*(struct unix_skb_parms*)&((skb)->cb)) | 58 | #define UNIXCB(skb) (*(struct unix_skb_parms*)&((skb)->cb)) |
59 | #define UNIXCREDS(skb) (&UNIXCB((skb)).creds) | 59 | #define UNIXCREDS(skb) (&UNIXCB((skb)).creds) |
60 | 60 | ||
61 | #define unix_state_rlock(s) read_lock(&unix_sk(s)->lock) | 61 | #define unix_state_rlock(s) spin_lock(&unix_sk(s)->lock) |
62 | #define unix_state_runlock(s) read_unlock(&unix_sk(s)->lock) | 62 | #define unix_state_runlock(s) spin_unlock(&unix_sk(s)->lock) |
63 | #define unix_state_wlock(s) write_lock(&unix_sk(s)->lock) | 63 | #define unix_state_wlock(s) spin_lock(&unix_sk(s)->lock) |
64 | #define unix_state_wunlock(s) write_unlock(&unix_sk(s)->lock) | 64 | #define unix_state_wunlock(s) spin_unlock(&unix_sk(s)->lock) |
65 | 65 | ||
66 | #ifdef __KERNEL__ | 66 | #ifdef __KERNEL__ |
67 | /* The AF_UNIX socket */ | 67 | /* The AF_UNIX socket */ |
@@ -76,7 +76,7 @@ struct unix_sock { | |||
76 | struct sock *other; | 76 | struct sock *other; |
77 | struct sock *gc_tree; | 77 | struct sock *gc_tree; |
78 | atomic_t inflight; | 78 | atomic_t inflight; |
79 | rwlock_t lock; | 79 | spinlock_t lock; |
80 | wait_queue_head_t peer_wait; | 80 | wait_queue_head_t peer_wait; |
81 | }; | 81 | }; |
82 | #define unix_sk(__sk) ((struct unix_sock *)__sk) | 82 | #define unix_sk(__sk) ((struct unix_sock *)__sk) |