net: lan966x: Implement the callback SWITCHDEV_ATTR_ID_BRIDGE_MC_DISABLED
authorHoratiu Vultur <horatiu.vultur@microchip.com>
Fri, 4 Feb 2022 09:14:51 +0000 (10:14 +0100)
committerDavid S. Miller <davem@davemloft.net>
Sat, 5 Feb 2022 15:00:43 +0000 (15:00 +0000)
commit47aeea0d57e80c9449448802aede54526a3d6305
tree8223b81f7f252ccbe64db1e55abcbca5d3ebf2a9
parent1c213f05a3e16110ff34d0cc80d1e6166d5cf882
net: lan966x: Implement the callback SWITCHDEV_ATTR_ID_BRIDGE_MC_DISABLED

The callback allows to enable/disable multicast snooping.
When the snooping is enabled, all IGMP and MLD frames are redirected to
the CPU, therefore make sure not to set the skb flag 'offload_fwd_mark'.
The HW will not flood multicast ipv4/ipv6 data frames.
When the snooping is disabled, the HW will flood IGMP, MLD and multicast
ipv4/ipv6 frames according to the mcast_flood flag.

Signed-off-by: Horatiu Vultur <horatiu.vultur@microchip.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/microchip/lan966x/lan966x_main.c
drivers/net/ethernet/microchip/lan966x/lan966x_main.h
drivers/net/ethernet/microchip/lan966x/lan966x_regs.h
drivers/net/ethernet/microchip/lan966x/lan966x_switchdev.c