tipc: add bearer disable/enable to new netlink api
A new netlink API for tipc that can disable or enable a tipc bearer. The new API is separated from the old API because of a bug in the user space client (tipc-config). The problem is that older versions of tipc-config has a very low receive limit and adding commands to the legacy genl_opts struct causes the ctrl_getfamily() response message to grow, subsequently breaking the tool. The new API utilizes netlink policies for input validation. Where the top-level netlink attributes are tipc-logical entities, like bearer. The top level entities then contain nested attributes. In this case a name, nested link properties and a domain. Netlink commands implemented in this patch: TIPC_NL_BEARER_ENABLE TIPC_NL_BEARER_DISABLE Netlink logical layout of bearer enable message: -> bearer -> name [ -> domain ] [ -> properties -> priority ] Netlink logical layout of bearer disable message: -> bearer -> name Signed-off-by: Richard Alpe <richard.alpe@ericsson.com> Reviewed-by: Erik Hugne <erik.hugne@ericsson.com> Reviewed-by: Jon Maloy <jon.maloy@ericsson.com> Acked-by: Ying Xue <ying.xue@windriver.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:

committed by
David S. Miller

parent
7cc76f5150
commit
0655f6a863
@@ -37,6 +37,7 @@
|
||||
#ifndef _TIPC_LINK_H
|
||||
#define _TIPC_LINK_H
|
||||
|
||||
#include <net/genetlink.h>
|
||||
#include "msg.h"
|
||||
#include "node.h"
|
||||
|
||||
@@ -239,6 +240,8 @@ void tipc_link_set_queue_limits(struct tipc_link *l_ptr, u32 window);
|
||||
void tipc_link_retransmit(struct tipc_link *l_ptr,
|
||||
struct sk_buff *start, u32 retransmits);
|
||||
|
||||
int tipc_nl_parse_link_prop(struct nlattr *prop, struct nlattr *props[]);
|
||||
|
||||
/*
|
||||
* Link sequence number manipulation routines (uses modulo 2**16 arithmetic)
|
||||
*/
|
||||
|
Reference in New Issue
Block a user