mirror of
https://github.com/nxp-imx/linux-imx.git
synced 2025-07-19 07:39:54 +02:00
net: bridge: Add extack to br_multicast_new_port_group()
Make it possible to set an extack in br_multicast_new_port_group(). Eventually, this function will check for per-port and per-port-vlan MDB maximums, and will use the extack to communicate the reason for the bounce. Signed-off-by: Petr Machata <petrm@nvidia.com> Reviewed-by: Ido Schimmel <idosch@nvidia.com> Acked-by: Nikolay Aleksandrov <razor@blackwall.org> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
c00041cf1c
commit
60977a0c63
|
@ -849,7 +849,7 @@ static int br_mdb_add_group_sg(const struct br_mdb_config *cfg,
|
|||
}
|
||||
|
||||
p = br_multicast_new_port_group(cfg->p, &cfg->group, *pp, flags, NULL,
|
||||
MCAST_INCLUDE, cfg->rt_protocol);
|
||||
MCAST_INCLUDE, cfg->rt_protocol, extack);
|
||||
if (unlikely(!p)) {
|
||||
NL_SET_ERR_MSG_MOD(extack, "Couldn't allocate new (S, G) port group");
|
||||
return -ENOMEM;
|
||||
|
@ -1075,7 +1075,8 @@ static int br_mdb_add_group_star_g(const struct br_mdb_config *cfg,
|
|||
}
|
||||
|
||||
p = br_multicast_new_port_group(cfg->p, &cfg->group, *pp, flags, NULL,
|
||||
cfg->filter_mode, cfg->rt_protocol);
|
||||
cfg->filter_mode, cfg->rt_protocol,
|
||||
extack);
|
||||
if (unlikely(!p)) {
|
||||
NL_SET_ERR_MSG_MOD(extack, "Couldn't allocate new (*, G) port group");
|
||||
return -ENOMEM;
|
||||
|
|
|
@ -1284,7 +1284,8 @@ struct net_bridge_port_group *br_multicast_new_port_group(
|
|||
unsigned char flags,
|
||||
const unsigned char *src,
|
||||
u8 filter_mode,
|
||||
u8 rt_protocol)
|
||||
u8 rt_protocol,
|
||||
struct netlink_ext_ack *extack)
|
||||
{
|
||||
struct net_bridge_port_group *p;
|
||||
|
||||
|
@ -1387,7 +1388,7 @@ __br_multicast_add_group(struct net_bridge_mcast *brmctx,
|
|||
}
|
||||
|
||||
p = br_multicast_new_port_group(pmctx->port, group, *pp, 0, src,
|
||||
filter_mode, RTPROT_KERNEL);
|
||||
filter_mode, RTPROT_KERNEL, NULL);
|
||||
if (unlikely(!p)) {
|
||||
p = ERR_PTR(-ENOMEM);
|
||||
goto out;
|
||||
|
|
|
@ -956,7 +956,8 @@ br_multicast_new_port_group(struct net_bridge_port *port,
|
|||
const struct br_ip *group,
|
||||
struct net_bridge_port_group __rcu *next,
|
||||
unsigned char flags, const unsigned char *src,
|
||||
u8 filter_mode, u8 rt_protocol);
|
||||
u8 filter_mode, u8 rt_protocol,
|
||||
struct netlink_ext_ack *extack);
|
||||
int br_mdb_hash_init(struct net_bridge *br);
|
||||
void br_mdb_hash_fini(struct net_bridge *br);
|
||||
void br_mdb_notify(struct net_device *dev, struct net_bridge_mdb_entry *mp,
|
||||
|
|
Loading…
Reference in New Issue
Block a user