net: mscc: ocelot: fix broken IP multicast flooding
authorVladimir Oltean <vladimir.oltean@nxp.com>
Fri, 15 Apr 2022 15:19:50 +0000 (18:19 +0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 27 Apr 2022 12:38:54 +0000 (14:38 +0200)
commit93581ae1f9803235393c98ed3dd7014fad2fa2d0
tree875bd9f9cd6a6fb13642ec20384543124f02cf3b
parent6a5ca57d5acd2271f435bbbb9223566cec2ff45b
net: mscc: ocelot: fix broken IP multicast flooding

[ Upstream commit 4cf35a2b627a020fe1a6b6fc7a6a12394644e474 ]

When the user runs:
bridge link set dev $br_port mcast_flood on

this command should affect not only L2 multicast, but also IPv4 and IPv6
multicast.

In the Ocelot switch, unknown multicast gets flooded according to
different PGIDs according to its type, and PGID_MC only handles L2
multicast. Therefore, by leaving PGID_MCIPV4 and PGID_MCIPV6 at their
default value of 0, unknown IP multicast traffic is never flooded.

Fixes: 421741ea5672 ("net: mscc: ocelot: offload bridge port flags to device")
Signed-off-by: Vladimir Oltean <vladimir.oltean@nxp.com>
Link: https://lore.kernel.org/r/20220415151950.219660-1-vladimir.oltean@nxp.com
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/net/ethernet/mscc/ocelot.c