diff options
author | Ying Xue | 2014-05-05 08:56:16 +0800 |
---|---|---|
committer | David S. Miller | 2014-05-05 17:26:45 -0400 |
commit | eb8b00f5f248c50603bca383792ac3a618297be0 (patch) | |
tree | 429c3bff534952209c848f011cb675530a115b5d /net/tipc/config.c | |
parent | d69afc90b8d47e471d2870f090f662e569b08407 (diff) |
tipc: convert allocations of global variables associated with bclink
Convert allocations of global variables associated with bclink from
static way to dynamical way for the convenience of bclink instance
initialisation. Meanwhile, this also helps TIPC support name space
in the future easily.
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/config.c')
-rw-r--r-- | net/tipc/config.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/net/tipc/config.c b/net/tipc/config.c index 251f5a2028e4..2b42403ad33a 100644 --- a/net/tipc/config.c +++ b/net/tipc/config.c @@ -177,8 +177,10 @@ static struct sk_buff *cfg_set_own_addr(void) if (tipc_own_addr) return tipc_cfg_reply_error_string(TIPC_CFG_NOT_SUPPORTED " (cannot change node address once assigned)"); - tipc_net_start(addr); - return tipc_cfg_reply_none(); + if (!tipc_net_start(addr)) + return tipc_cfg_reply_none(); + + return tipc_cfg_reply_error_string("cannot change to network mode"); } static struct sk_buff *cfg_set_max_ports(void) |