summaryrefslogtreecommitdiff
path: root/net/tipc/node.h
diff options
context:
space:
mode:
authorJon Paul Maloy <jon.maloy@ericsson.com>2015-11-19 14:30:43 -0500
committerDavid S. Miller <davem@davemloft.net>2015-11-20 14:06:10 -0500
commit2312bf61ae365fdd6b9bfb24558a417859759447 (patch)
tree182ac3a58a25951a475c3bc88a32b0e82662201e /net/tipc/node.h
parent1d7e1c2595bd20c5274a8e49d89cf0cf483759de (diff)
downloadlinux-riscv-2312bf61ae365fdd6b9bfb24558a417859759447.tar.gz
linux-riscv-2312bf61ae365fdd6b9bfb24558a417859759447.tar.bz2
linux-riscv-2312bf61ae365fdd6b9bfb24558a417859759447.zip
tipc: introduce per-link spinlock
As a preparation to allow parallel links to work more independently from each other we introduce a per-link spinlock, to be stored in the struct nodes's link entry area. Since the node lock still is a regular spinlock there is no increase in parallellism at this stage. Reviewed-by: Ying Xue <ying.xue@windriver.com> Signed-off-by: Jon Maloy <jon.maloy@ericsson.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/tipc/node.h')
-rw-r--r--net/tipc/node.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/net/tipc/node.h b/net/tipc/node.h
index dd79e9742bd6..8784907486c0 100644
--- a/net/tipc/node.h
+++ b/net/tipc/node.h
@@ -69,6 +69,7 @@ enum {
struct tipc_link_entry {
struct tipc_link *link;
+ spinlock_t lock; /* per-link */
u32 mtu;
struct sk_buff_head inputq;
struct tipc_media_addr maddr;
@@ -86,7 +87,7 @@ struct tipc_bclink_entry {
* struct tipc_node - TIPC node structure
* @addr: network address of node
* @ref: reference counter to node object
- * @lock: spinlock governing access to structure
+ * @lock: rwlock governing access to structure
* @net: the applicable net namespace
* @hash: links to adjacent nodes in unsorted hash chain
* @inputq: pointer to input queue containing messages for msg event