summaryrefslogtreecommitdiffstats
path: root/net/tipc/config.c
diff options
context:
space:
mode:
authorAllan Stephens <allan.stephens@windriver.com>2008-05-21 14:55:04 -0700
committerDavid S. Miller <davem@davemloft.net>2008-05-21 14:55:04 -0700
commit03194379a77b02df3404ec4848a50c6784e9a8a5 (patch)
treef76ddd4c02f71f5ed03da0729d563f81d701f267 /net/tipc/config.c
parent6d4a6672c8263f98544d2b91690dc7074b144090 (diff)
downloadlinux-stable-03194379a77b02df3404ec4848a50c6784e9a8a5.tar.gz
linux-stable-03194379a77b02df3404ec4848a50c6784e9a8a5.tar.bz2
linux-stable-03194379a77b02df3404ec4848a50c6784e9a8a5.zip
tipc: Fix initialization sequence problems when entering network mode
This patch ensures that TIPC's topology service and configuration service are shut down before switching into "network mode". This ensures that TIPC does not mistakenly try to send unnecessary "publication withdraw" messages to other nodes before it is fully initialized for sending off-node messages. Note that the node's current network address is now updated only after the two services are shut down; this ensures that any existing connections to the topology server are terminated correctly using the old address. Signed-off-by: Allan Stephens <allan.stephens@windriver.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/tipc/config.c')
-rw-r--r--net/tipc/config.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/net/tipc/config.c b/net/tipc/config.c
index 16e7cb74969b..ca3544d030c7 100644
--- a/net/tipc/config.c
+++ b/net/tipc/config.c
@@ -293,7 +293,6 @@ static struct sk_buff *cfg_set_own_addr(void)
if (tipc_mode == TIPC_NET_MODE)
return tipc_cfg_reply_error_string(TIPC_CFG_NOT_SUPPORTED
" (cannot change node address once assigned)");
- tipc_own_addr = addr;
/*
* Must release all spinlocks before calling start_net() because
@@ -306,7 +305,7 @@ static struct sk_buff *cfg_set_own_addr(void)
*/
spin_unlock_bh(&config_lock);
- tipc_core_start_net();
+ tipc_core_start_net(addr);
spin_lock_bh(&config_lock);
return tipc_cfg_reply_none();
}