Skip to content

Commit

Permalink
net: bridge: igmp: Extend IGMP query to be per vlan
Browse files Browse the repository at this point in the history
Based on the comments of the previous version, we started to work on a
new version, so it would be possible to enable/disable queries per vlan.
This is still work in progress and there are plenty of things that are
not implemented and tested:
- ipv6 support
- the fast path needs to be improved
- currently it is possible only to enable/disable the queries per vlan,
  all the other configurations are global
- toggling vlan_filtering is not tested
- remove duplicated information
- etc...

But there are few things that are working like:
- sending queries per vlan
- stop sending queries if there is a better querier per vlan
- when ports are added/removed from vlan
- etc...

We were wondering if this what you had in mind when you proposed to have
this per vlan? Or we are completely off? Or we should fix some of the
issues that I mentioned, before you can see more clearly the direction?

Signed-off-by: Horatiu Vultur <horatiu.vultur@microchip.com>
  • Loading branch information
HoratiuVultur authored and intel-lab-lkp committed Jan 12, 2021
1 parent c73a459 commit 8d72e3d
Show file tree
Hide file tree
Showing 8 changed files with 560 additions and 83 deletions.
1 change: 1 addition & 0 deletions include/uapi/linux/if_link.h
Original file line number Diff line number Diff line change
Expand Up @@ -472,6 +472,7 @@ enum {
IFLA_BR_MCAST_MLD_VERSION,
IFLA_BR_VLAN_STATS_PER_PORT,
IFLA_BR_MULTI_BOOLOPT,
IFLA_BR_MCAST_QUERIER_VID,
__IFLA_BR_MAX,
};

Expand Down
2 changes: 1 addition & 1 deletion net/bridge/br_device.c
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ netdev_tx_t br_dev_xmit(struct sk_buff *skb, struct net_device *dev)

mdst = br_mdb_get(br, skb, vid);
if ((mdst || BR_INPUT_SKB_CB_MROUTERS_ONLY(skb)) &&
br_multicast_querier_exists(br, eth_hdr(skb), mdst))
br_multicast_querier_exists(br, eth_hdr(skb), mdst, vid))
br_multicast_flood(mdst, skb, false, true);
else
br_flood(br, skb, BR_PKT_MULTICAST, false, true);
Expand Down
2 changes: 1 addition & 1 deletion net/bridge/br_input.c
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,7 @@ int br_handle_frame_finish(struct net *net, struct sock *sk, struct sk_buff *skb
case BR_PKT_MULTICAST:
mdst = br_mdb_get(br, skb, vid);
if ((mdst || BR_INPUT_SKB_CB_MROUTERS_ONLY(skb)) &&
br_multicast_querier_exists(br, eth_hdr(skb), mdst)) {
br_multicast_querier_exists(br, eth_hdr(skb), mdst, vid)) {
if ((mdst && mdst->host_joined) ||
br_multicast_is_router(br)) {
local_rcv = true;
Expand Down

0 comments on commit 8d72e3d

Please sign in to comment.