diff options
Diffstat (limited to 'net/tipc/ref.h')
-rw-r--r-- | net/tipc/ref.h | 15 |
1 files changed, 11 insertions, 4 deletions
diff --git a/net/tipc/ref.h b/net/tipc/ref.h index e236fa520a1d..2b75a892305a 100644 --- a/net/tipc/ref.h +++ b/net/tipc/ref.h | |||
@@ -1,7 +1,7 @@ | |||
1 | /* | 1 | /* |
2 | * net/tipc/ref.h: Include file for TIPC object registry code | 2 | * net/tipc/ref.h: Include file for TIPC object registry code |
3 | * | 3 | * |
4 | * Copyright (c) 1991-2006, Ericsson AB | 4 | * Copyright (c) 1991-2006, 2014, Ericsson AB |
5 | * Copyright (c) 2005-2006, Wind River Systems | 5 | * Copyright (c) 2005-2006, Wind River Systems |
6 | * All rights reserved. | 6 | * All rights reserved. |
7 | * | 7 | * |
@@ -37,13 +37,20 @@ | |||
37 | #ifndef _TIPC_REF_H | 37 | #ifndef _TIPC_REF_H |
38 | #define _TIPC_REF_H | 38 | #define _TIPC_REF_H |
39 | 39 | ||
40 | #include "socket.h" | ||
41 | |||
40 | int tipc_ref_table_init(u32 requested_size, u32 start); | 42 | int tipc_ref_table_init(u32 requested_size, u32 start); |
41 | void tipc_ref_table_stop(void); | 43 | void tipc_ref_table_stop(void); |
42 | 44 | ||
43 | u32 tipc_ref_acquire(void *object, spinlock_t **lock); | 45 | u32 tipc_ref_acquire(struct tipc_sock *tsk); |
44 | void tipc_ref_discard(u32 ref); | 46 | void tipc_ref_discard(u32 ref); |
45 | 47 | ||
46 | void *tipc_ref_lock(u32 ref); | 48 | struct tipc_sock *tipc_sk_get(u32 ref); |
47 | void *tipc_ref_lock_next(u32 *ref); | 49 | struct tipc_sock *tipc_sk_get_next(u32 *ref); |
50 | |||
51 | static inline void tipc_sk_put(struct tipc_sock *tsk) | ||
52 | { | ||
53 | sock_put(&tsk->sk); | ||
54 | } | ||
48 | 55 | ||
49 | #endif | 56 | #endif |