22 * net/tipc/config.c: TIPC configuration management code
33 *
44 * Copyright (c) 2002-2006, Ericsson AB
5- * Copyright (c) 2004-2007, Wind River Systems
5+ * Copyright (c) 2004-2007, 2010-2011, Wind River Systems
66 * All rights reserved.
77 *
88 * Redistribution and use in source and binary forms, with or without
@@ -148,7 +148,7 @@ static struct sk_buff *cfg_enable_bearer(void)
148148
149149 args = (struct tipc_bearer_config * )TLV_DATA (req_tlv_area );
150150 if (tipc_enable_bearer (args -> name ,
151- ntohl (args -> detect_scope ),
151+ ntohl (args -> disc_domain ),
152152 ntohl (args -> priority )))
153153 return tipc_cfg_reply_error_string ("unable to enable bearer" );
154154
@@ -260,25 +260,6 @@ static struct sk_buff *cfg_set_max_ports(void)
260260 return tipc_cfg_reply_none ();
261261}
262262
263- static struct sk_buff * cfg_set_max_nodes (void )
264- {
265- u32 value ;
266-
267- if (!TLV_CHECK (req_tlv_area , req_tlv_space , TIPC_TLV_UNSIGNED ))
268- return tipc_cfg_reply_error_string (TIPC_CFG_TLV_ERROR );
269- value = ntohl (* (__be32 * )TLV_DATA (req_tlv_area ));
270- if (value == tipc_max_nodes )
271- return tipc_cfg_reply_none ();
272- if (value != delimit (value , 8 , 2047 ))
273- return tipc_cfg_reply_error_string (TIPC_CFG_INVALID_VALUE
274- " (max nodes must be 8-2047)" );
275- if (tipc_mode == TIPC_NET_MODE )
276- return tipc_cfg_reply_error_string (TIPC_CFG_NOT_SUPPORTED
277- " (cannot change max nodes once TIPC has joined a network)" );
278- tipc_max_nodes = value ;
279- return tipc_cfg_reply_none ();
280- }
281-
282263static struct sk_buff * cfg_set_netid (void )
283264{
284265 u32 value ;
@@ -397,9 +378,6 @@ struct sk_buff *tipc_cfg_do_cmd(u32 orig_node, u16 cmd, const void *request_area
397378 case TIPC_CMD_SET_MAX_SUBSCR :
398379 rep_tlv_buf = cfg_set_max_subscriptions ();
399380 break ;
400- case TIPC_CMD_SET_MAX_NODES :
401- rep_tlv_buf = cfg_set_max_nodes ();
402- break ;
403381 case TIPC_CMD_SET_NETID :
404382 rep_tlv_buf = cfg_set_netid ();
405383 break ;
@@ -415,9 +393,6 @@ struct sk_buff *tipc_cfg_do_cmd(u32 orig_node, u16 cmd, const void *request_area
415393 case TIPC_CMD_GET_MAX_SUBSCR :
416394 rep_tlv_buf = tipc_cfg_reply_unsigned (tipc_max_subscriptions );
417395 break ;
418- case TIPC_CMD_GET_MAX_NODES :
419- rep_tlv_buf = tipc_cfg_reply_unsigned (tipc_max_nodes );
420- break ;
421396 case TIPC_CMD_GET_NETID :
422397 rep_tlv_buf = tipc_cfg_reply_unsigned (tipc_net_id );
423398 break ;
@@ -431,6 +406,8 @@ struct sk_buff *tipc_cfg_do_cmd(u32 orig_node, u16 cmd, const void *request_area
431406 case TIPC_CMD_GET_MAX_SLAVES :
432407 case TIPC_CMD_SET_MAX_CLUSTERS :
433408 case TIPC_CMD_GET_MAX_CLUSTERS :
409+ case TIPC_CMD_SET_MAX_NODES :
410+ case TIPC_CMD_GET_MAX_NODES :
434411 rep_tlv_buf = tipc_cfg_reply_error_string (TIPC_CFG_NOT_SUPPORTED
435412 " (obsolete command)" );
436413 break ;
0 commit comments