diff options
author | Ying Xue <ying.xue@windriver.com> | 2014-03-27 00:54:30 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2014-03-27 13:08:36 -0400 |
commit | 76d7882420d94075c806c074de241602a06e47e6 (patch) | |
tree | 03a8d9227769559fe61c207b11e465431625fdd6 /net/tipc/node.c | |
parent | 1dbe136938df6633042b5674abdd2e08542168f3 (diff) |
tipc: remove unnecessary checking for node object
tipc_node_create routine doesn't need to check whether a node
object specified with a node address exists or not because its
caller(ie, tipc_disc_recv_msg routine) has checked this before
calling it.
Signed-off-by: Ying Xue <ying.xue@windriver.com>
Reviewed-by: Erik Hugne <erik.hugne@ericsson.com>
Reviewed-by: Jon Maloy <jon.maloy@ericsson.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/tipc/node.c')
-rw-r--r-- | net/tipc/node.c | 6 |
1 files changed, 0 insertions, 6 deletions
diff --git a/net/tipc/node.c b/net/tipc/node.c index 0b0f6c7da965..7c9b6673e2ab 100644 --- a/net/tipc/node.c +++ b/net/tipc/node.c | |||
@@ -95,12 +95,6 @@ struct tipc_node *tipc_node_create(u32 addr) | |||
95 | 95 | ||
96 | spin_lock_bh(&node_create_lock); | 96 | spin_lock_bh(&node_create_lock); |
97 | 97 | ||
98 | n_ptr = tipc_node_find(addr); | ||
99 | if (n_ptr) { | ||
100 | spin_unlock_bh(&node_create_lock); | ||
101 | return n_ptr; | ||
102 | } | ||
103 | |||
104 | n_ptr = kzalloc(sizeof(*n_ptr), GFP_ATOMIC); | 98 | n_ptr = kzalloc(sizeof(*n_ptr), GFP_ATOMIC); |
105 | if (!n_ptr) { | 99 | if (!n_ptr) { |
106 | spin_unlock_bh(&node_create_lock); | 100 | spin_unlock_bh(&node_create_lock); |