diff options
| author | Anton Vorontsov <cbouatmailru@gmail.com> | 2008-07-29 18:05:23 -0400 |
|---|---|---|
| committer | Anton Vorontsov <cbouatmailru@gmail.com> | 2008-07-29 18:05:23 -0400 |
| commit | 9fec6060d9e48ed7db0dac0e16d0f0f0e615b7f6 (patch) | |
| tree | 74b41f31a08f6500ff3dfcf64ba21e2d9a8e87e5 /net/tipc/net.c | |
| parent | fece418418f51e92dd7e67e17c5e3fe5a28d3279 (diff) | |
| parent | 6e86841d05f371b5b9b86ce76c02aaee83352298 (diff) | |
Merge branch 'master' of /home/cbou/linux-2.6
Conflicts:
drivers/power/Kconfig
drivers/power/Makefile
Diffstat (limited to 'net/tipc/net.c')
| -rw-r--r-- | net/tipc/net.c | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/net/tipc/net.c b/net/tipc/net.c index c39c76201e8e..ec7b04fbdc43 100644 --- a/net/tipc/net.c +++ b/net/tipc/net.c | |||
| @@ -165,7 +165,7 @@ static int net_init(void) | |||
| 165 | if (!tipc_net.zones) { | 165 | if (!tipc_net.zones) { |
| 166 | return -ENOMEM; | 166 | return -ENOMEM; |
| 167 | } | 167 | } |
| 168 | return TIPC_OK; | 168 | return 0; |
| 169 | } | 169 | } |
| 170 | 170 | ||
| 171 | static void net_stop(void) | 171 | static void net_stop(void) |
| @@ -266,7 +266,7 @@ void tipc_net_route_msg(struct sk_buff *buf) | |||
| 266 | tipc_link_send(buf, dnode, msg_link_selector(msg)); | 266 | tipc_link_send(buf, dnode, msg_link_selector(msg)); |
| 267 | } | 267 | } |
| 268 | 268 | ||
| 269 | int tipc_net_start(void) | 269 | int tipc_net_start(u32 addr) |
| 270 | { | 270 | { |
| 271 | char addr_string[16]; | 271 | char addr_string[16]; |
| 272 | int res; | 272 | int res; |
| @@ -274,6 +274,10 @@ int tipc_net_start(void) | |||
| 274 | if (tipc_mode != TIPC_NODE_MODE) | 274 | if (tipc_mode != TIPC_NODE_MODE) |
| 275 | return -ENOPROTOOPT; | 275 | return -ENOPROTOOPT; |
| 276 | 276 | ||
| 277 | tipc_subscr_stop(); | ||
| 278 | tipc_cfg_stop(); | ||
| 279 | |||
| 280 | tipc_own_addr = addr; | ||
| 277 | tipc_mode = TIPC_NET_MODE; | 281 | tipc_mode = TIPC_NET_MODE; |
| 278 | tipc_named_reinit(); | 282 | tipc_named_reinit(); |
| 279 | tipc_port_reinit(); | 283 | tipc_port_reinit(); |
| @@ -284,14 +288,14 @@ int tipc_net_start(void) | |||
| 284 | (res = tipc_bclink_init())) { | 288 | (res = tipc_bclink_init())) { |
| 285 | return res; | 289 | return res; |
| 286 | } | 290 | } |
| 287 | tipc_subscr_stop(); | 291 | |
| 288 | tipc_cfg_stop(); | ||
| 289 | tipc_k_signal((Handler)tipc_subscr_start, 0); | 292 | tipc_k_signal((Handler)tipc_subscr_start, 0); |
| 290 | tipc_k_signal((Handler)tipc_cfg_init, 0); | 293 | tipc_k_signal((Handler)tipc_cfg_init, 0); |
| 294 | |||
| 291 | info("Started in network mode\n"); | 295 | info("Started in network mode\n"); |
| 292 | info("Own node address %s, network identity %u\n", | 296 | info("Own node address %s, network identity %u\n", |
| 293 | addr_string_fill(addr_string, tipc_own_addr), tipc_net_id); | 297 | addr_string_fill(addr_string, tipc_own_addr), tipc_net_id); |
| 294 | return TIPC_OK; | 298 | return 0; |
| 295 | } | 299 | } |
| 296 | 300 | ||
| 297 | void tipc_net_stop(void) | 301 | void tipc_net_stop(void) |
