mirror of
git://git.openwrt.org/openwrt/openwrt.git
synced 2025-12-06 20:54:00 -05:00
Update patch 642-net-bridge-locally-receive-all-multicast-packets-if-.patch to upstream version and move to backport folder as 625-v6.16-net-bridge-locally-receive-all-multicast-packets-if-.patch because kernel 6.16 already includes it. Link: https://lore.kernel.org/all/OSZPR01MB8434308370ACAFA90A22980798B32@OSZPR01MB8434.jpnprd01.prod.outlook.com/ Link: https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?id=a496d2f0fd612ab9e10700afe00dc9267bad788b Signed-off-by: Mieczyslaw Nalewaj <namiltd@yahoo.com> Link: https://github.com/openwrt/openwrt/pull/19875 Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
42 lines
1.8 KiB
Diff
42 lines
1.8 KiB
Diff
From a496d2f0fd612ab9e10700afe00dc9267bad788b Mon Sep 17 00:00:00 2001
|
|
From: Shengyu Qu <wiagn233@outlook.com>
|
|
Date: Mon, 14 Apr 2025 18:56:01 +0800
|
|
Subject: net: bridge: locally receive all multicast packets if IFF_ALLMULTI is
|
|
set
|
|
|
|
If multicast snooping is enabled, multicast packets may not always end up
|
|
on the local bridge interface, if the host is not a member of the multicast
|
|
group. Similar to how IFF_PROMISC allows all packets to be received
|
|
locally, let IFF_ALLMULTI allow all multicast packets to be received.
|
|
|
|
OpenWrt uses a user space daemon for DHCPv6/RA/NDP handling, and in relay
|
|
mode it sets the ALLMULTI flag in order to receive all relevant queries on
|
|
the network.
|
|
|
|
This works for normal network interfaces and non-snooping bridges, but not
|
|
snooping bridges (unless multicast routing is enabled).
|
|
|
|
Reported-by: Felix Fietkau <nbd@nbd.name>
|
|
Closes: https://github.com/openwrt/openwrt/issues/15857#issuecomment-2662851243
|
|
Signed-off-by: Shengyu Qu <wiagn233@outlook.com>
|
|
Reviewed-by: Ido Schimmel <idosch@nvidia.com>
|
|
Acked-by: Nikolay Aleksandrov <razor@blackwall.org>
|
|
Link: https://patch.msgid.link/OSZPR01MB8434308370ACAFA90A22980798B32@OSZPR01MB8434.jpnprd01.prod.outlook.com
|
|
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
|
|
---
|
|
net/bridge/br_input.c | 3 ++-
|
|
1 file changed, 2 insertions(+), 1 deletion(-)
|
|
|
|
--- a/net/bridge/br_input.c
|
|
+++ b/net/bridge/br_input.c
|
|
@@ -184,7 +184,8 @@ int br_handle_frame_finish(struct net *n
|
|
if ((mdst || BR_INPUT_SKB_CB_MROUTERS_ONLY(skb)) &&
|
|
br_multicast_querier_exists(brmctx, eth_hdr(skb), mdst)) {
|
|
if ((mdst && mdst->host_joined) ||
|
|
- br_multicast_is_router(brmctx, skb)) {
|
|
+ br_multicast_is_router(brmctx, skb) ||
|
|
+ br->dev->flags & IFF_ALLMULTI) {
|
|
local_rcv = true;
|
|
DEV_STATS_INC(br->dev, multicast);
|
|
}
|