aboutsummaryrefslogtreecommitdiffstats
path: root/net/tipc/config.c
diff options
context:
space:
mode:
Diffstat (limited to 'net/tipc/config.c')
-rw-r--r--net/tipc/config.c21
1 files changed, 2 insertions, 19 deletions
diff --git a/net/tipc/config.c b/net/tipc/config.c
index 05dc102300ae..bc512102eebd 100644
--- a/net/tipc/config.c
+++ b/net/tipc/config.c
@@ -269,19 +269,6 @@ static struct sk_buff *cfg_set_max_ports(void)
269 return tipc_cfg_reply_none(); 269 return tipc_cfg_reply_none();
270} 270}
271 271
272static struct sk_buff *cfg_set_max_clusters(void)
273{
274 u32 value;
275
276 if (!TLV_CHECK(req_tlv_area, req_tlv_space, TIPC_TLV_UNSIGNED))
277 return tipc_cfg_reply_error_string(TIPC_CFG_TLV_ERROR);
278 value = ntohl(*(__be32 *)TLV_DATA(req_tlv_area));
279 if (value != delimit(value, 1, 1))
280 return tipc_cfg_reply_error_string(TIPC_CFG_INVALID_VALUE
281 " (max clusters fixed at 1)");
282 return tipc_cfg_reply_none();
283}
284
285static struct sk_buff *cfg_set_max_nodes(void) 272static struct sk_buff *cfg_set_max_nodes(void)
286{ 273{
287 u32 value; 274 u32 value;
@@ -420,9 +407,6 @@ struct sk_buff *tipc_cfg_do_cmd(u32 orig_node, u16 cmd, const void *request_area
420 case TIPC_CMD_SET_MAX_SUBSCR: 407 case TIPC_CMD_SET_MAX_SUBSCR:
421 rep_tlv_buf = cfg_set_max_subscriptions(); 408 rep_tlv_buf = cfg_set_max_subscriptions();
422 break; 409 break;
423 case TIPC_CMD_SET_MAX_CLUSTERS:
424 rep_tlv_buf = cfg_set_max_clusters();
425 break;
426 case TIPC_CMD_SET_MAX_NODES: 410 case TIPC_CMD_SET_MAX_NODES:
427 rep_tlv_buf = cfg_set_max_nodes(); 411 rep_tlv_buf = cfg_set_max_nodes();
428 break; 412 break;
@@ -441,9 +425,6 @@ struct sk_buff *tipc_cfg_do_cmd(u32 orig_node, u16 cmd, const void *request_area
441 case TIPC_CMD_GET_MAX_SUBSCR: 425 case TIPC_CMD_GET_MAX_SUBSCR:
442 rep_tlv_buf = tipc_cfg_reply_unsigned(tipc_max_subscriptions); 426 rep_tlv_buf = tipc_cfg_reply_unsigned(tipc_max_subscriptions);
443 break; 427 break;
444 case TIPC_CMD_GET_MAX_CLUSTERS:
445 rep_tlv_buf = tipc_cfg_reply_unsigned(tipc_max_clusters);
446 break;
447 case TIPC_CMD_GET_MAX_NODES: 428 case TIPC_CMD_GET_MAX_NODES:
448 rep_tlv_buf = tipc_cfg_reply_unsigned(tipc_max_nodes); 429 rep_tlv_buf = tipc_cfg_reply_unsigned(tipc_max_nodes);
449 break; 430 break;
@@ -458,6 +439,8 @@ struct sk_buff *tipc_cfg_do_cmd(u32 orig_node, u16 cmd, const void *request_area
458 case TIPC_CMD_GET_MAX_ZONES: 439 case TIPC_CMD_GET_MAX_ZONES:
459 case TIPC_CMD_SET_MAX_SLAVES: 440 case TIPC_CMD_SET_MAX_SLAVES:
460 case TIPC_CMD_GET_MAX_SLAVES: 441 case TIPC_CMD_GET_MAX_SLAVES:
442 case TIPC_CMD_SET_MAX_CLUSTERS:
443 case TIPC_CMD_GET_MAX_CLUSTERS:
461 rep_tlv_buf = tipc_cfg_reply_error_string(TIPC_CFG_NOT_SUPPORTED 444 rep_tlv_buf = tipc_cfg_reply_error_string(TIPC_CFG_NOT_SUPPORTED
462 " (obsolete command)"); 445 " (obsolete command)");
463 break; 446 break;