[openwrt/openwrt] kernel: update and move net bridge patch to backport folder
LEDE Commits
lede-commits at lists.infradead.org
Thu Sep 4 14:52:03 PDT 2025
hauke pushed a commit to openwrt/openwrt.git, branch main:
https://git.openwrt.org/b4294bc9800901a72128e0f78d7746b637e25aa9
commit b4294bc9800901a72128e0f78d7746b637e25aa9
Author: Mieczyslaw Nalewaj <namiltd at yahoo.com>
AuthorDate: Sun Aug 31 16:53:36 2025 +0200
kernel: update and move net bridge patch to backport folder
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 at yahoo.com>
Link: https://github.com/openwrt/openwrt/pull/19875
Signed-off-by: Hauke Mehrtens <hauke at hauke-m.de>
---
...locally-receive-all-multicast-packets-if-.patch | 41 ++++++++++++++++++++++
...locally-receive-all-multicast-packets-if-.patch | 41 ++++++++++++++++++++++
...-bridge_allow_receiption_on_disabled_port.patch | 4 +--
...locally-receive-all-multicast-packets-if-.patch | 24 -------------
...ge-add-knob-for-filtering-rx-tx-BPDU-pack.patch | 2 +-
...-bridge_allow_receiption_on_disabled_port.patch | 4 +--
...locally-receive-all-multicast-packets-if-.patch | 24 -------------
...ge-add-knob-for-filtering-rx-tx-BPDU-pack.patch | 2 +-
8 files changed, 88 insertions(+), 54 deletions(-)
diff --git a/target/linux/generic/backport-6.12/625-v6.16-net-bridge-locally-receive-all-multicast-packets-if-.patch b/target/linux/generic/backport-6.12/625-v6.16-net-bridge-locally-receive-all-multicast-packets-if-.patch
new file mode 100644
index 0000000000..d9bd8c73a0
--- /dev/null
+++ b/target/linux/generic/backport-6.12/625-v6.16-net-bridge-locally-receive-all-multicast-packets-if-.patch
@@ -0,0 +1,41 @@
+From a496d2f0fd612ab9e10700afe00dc9267bad788b Mon Sep 17 00:00:00 2001
+From: Shengyu Qu <wiagn233 at 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 at nbd.name>
+Closes: https://github.com/openwrt/openwrt/issues/15857#issuecomment-2662851243
+Signed-off-by: Shengyu Qu <wiagn233 at outlook.com>
+Reviewed-by: Ido Schimmel <idosch at nvidia.com>
+Acked-by: Nikolay Aleksandrov <razor at blackwall.org>
+Link: https://patch.msgid.link/OSZPR01MB8434308370ACAFA90A22980798B32@OSZPR01MB8434.jpnprd01.prod.outlook.com
+Signed-off-by: Jakub Kicinski <kuba at 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);
+ }
diff --git a/target/linux/generic/backport-6.6/625-v6.16-net-bridge-locally-receive-all-multicast-packets-if-.patch b/target/linux/generic/backport-6.6/625-v6.16-net-bridge-locally-receive-all-multicast-packets-if-.patch
new file mode 100644
index 0000000000..d9bd8c73a0
--- /dev/null
+++ b/target/linux/generic/backport-6.6/625-v6.16-net-bridge-locally-receive-all-multicast-packets-if-.patch
@@ -0,0 +1,41 @@
+From a496d2f0fd612ab9e10700afe00dc9267bad788b Mon Sep 17 00:00:00 2001
+From: Shengyu Qu <wiagn233 at 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 at nbd.name>
+Closes: https://github.com/openwrt/openwrt/issues/15857#issuecomment-2662851243
+Signed-off-by: Shengyu Qu <wiagn233 at outlook.com>
+Reviewed-by: Ido Schimmel <idosch at nvidia.com>
+Acked-by: Nikolay Aleksandrov <razor at blackwall.org>
+Link: https://patch.msgid.link/OSZPR01MB8434308370ACAFA90A22980798B32@OSZPR01MB8434.jpnprd01.prod.outlook.com
+Signed-off-by: Jakub Kicinski <kuba at 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);
+ }
diff --git a/target/linux/generic/pending-6.12/150-bridge_allow_receiption_on_disabled_port.patch b/target/linux/generic/pending-6.12/150-bridge_allow_receiption_on_disabled_port.patch
index d8fd9cdf42..530f2c3a38 100644
--- a/target/linux/generic/pending-6.12/150-bridge_allow_receiption_on_disabled_port.patch
+++ b/target/linux/generic/pending-6.12/150-bridge_allow_receiption_on_disabled_port.patch
@@ -15,7 +15,7 @@ Signed-off-by: Felix Fietkau <nbd at nbd.name>
--- a/net/bridge/br_input.c
+++ b/net/bridge/br_input.c
-@@ -244,6 +244,9 @@ static void __br_handle_local_finish(str
+@@ -245,6 +245,9 @@ static void __br_handle_local_finish(str
/* note: already called with rcu_read_lock */
static int br_handle_local_finish(struct net *net, struct sock *sk, struct sk_buff *skb)
{
@@ -25,7 +25,7 @@ Signed-off-by: Felix Fietkau <nbd at nbd.name>
__br_handle_local_finish(skb);
/* return 1 to signal the okfn() was called so it's ok to use the skb */
-@@ -415,6 +418,17 @@ forward:
+@@ -416,6 +419,17 @@ forward:
goto defer_stp_filtering;
switch (p->state) {
diff --git a/target/linux/generic/pending-6.12/642-net-bridge-locally-receive-all-multicast-packets-if-.patch b/target/linux/generic/pending-6.12/642-net-bridge-locally-receive-all-multicast-packets-if-.patch
deleted file mode 100644
index 98edb315b1..0000000000
--- a/target/linux/generic/pending-6.12/642-net-bridge-locally-receive-all-multicast-packets-if-.patch
+++ /dev/null
@@ -1,24 +0,0 @@
-From: Felix Fietkau <nbd at nbd.name>
-Date: Mon, 17 Feb 2025 12:21:08 +0100
-Subject: [PATCH] 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.
-
-Signed-off-by: Felix Fietkau <nbd at nbd.name>
----
-
---- a/net/bridge/br_input.c
-+++ b/net/bridge/br_input.c
-@@ -152,6 +152,8 @@ int br_handle_frame_finish(struct net *n
- pkt_type = BR_PKT_MULTICAST;
- if (br_multicast_rcv(&brmctx, &pmctx, vlan, skb, vid))
- goto drop;
-+ if (br->dev->flags & IFF_ALLMULTI)
-+ local_rcv = true;
- }
- }
-
diff --git a/target/linux/generic/pending-6.12/710-bridge-add-knob-for-filtering-rx-tx-BPDU-pack.patch b/target/linux/generic/pending-6.12/710-bridge-add-knob-for-filtering-rx-tx-BPDU-pack.patch
index c44d2cf736..3ada4a0e9b 100644
--- a/target/linux/generic/pending-6.12/710-bridge-add-knob-for-filtering-rx-tx-BPDU-pack.patch
+++ b/target/linux/generic/pending-6.12/710-bridge-add-knob-for-filtering-rx-tx-BPDU-pack.patch
@@ -45,7 +45,7 @@ Signed-off-by: Felix Fietkau <nbd at nbd.name>
if (!(p->flags & BR_BCAST_FLOOD) && skb->dev != br->dev)
--- a/net/bridge/br_input.c
+++ b/net/bridge/br_input.c
-@@ -369,6 +369,8 @@ static rx_handler_result_t br_handle_fra
+@@ -368,6 +368,8 @@ static rx_handler_result_t br_handle_fra
fwd_mask |= p->group_fwd_mask;
switch (dest[5]) {
case 0x00: /* Bridge Group Address */
diff --git a/target/linux/generic/pending-6.6/150-bridge_allow_receiption_on_disabled_port.patch b/target/linux/generic/pending-6.6/150-bridge_allow_receiption_on_disabled_port.patch
index d8fd9cdf42..530f2c3a38 100644
--- a/target/linux/generic/pending-6.6/150-bridge_allow_receiption_on_disabled_port.patch
+++ b/target/linux/generic/pending-6.6/150-bridge_allow_receiption_on_disabled_port.patch
@@ -15,7 +15,7 @@ Signed-off-by: Felix Fietkau <nbd at nbd.name>
--- a/net/bridge/br_input.c
+++ b/net/bridge/br_input.c
-@@ -244,6 +244,9 @@ static void __br_handle_local_finish(str
+@@ -245,6 +245,9 @@ static void __br_handle_local_finish(str
/* note: already called with rcu_read_lock */
static int br_handle_local_finish(struct net *net, struct sock *sk, struct sk_buff *skb)
{
@@ -25,7 +25,7 @@ Signed-off-by: Felix Fietkau <nbd at nbd.name>
__br_handle_local_finish(skb);
/* return 1 to signal the okfn() was called so it's ok to use the skb */
-@@ -415,6 +418,17 @@ forward:
+@@ -416,6 +419,17 @@ forward:
goto defer_stp_filtering;
switch (p->state) {
diff --git a/target/linux/generic/pending-6.6/642-net-bridge-locally-receive-all-multicast-packets-if-.patch b/target/linux/generic/pending-6.6/642-net-bridge-locally-receive-all-multicast-packets-if-.patch
deleted file mode 100644
index 98edb315b1..0000000000
--- a/target/linux/generic/pending-6.6/642-net-bridge-locally-receive-all-multicast-packets-if-.patch
+++ /dev/null
@@ -1,24 +0,0 @@
-From: Felix Fietkau <nbd at nbd.name>
-Date: Mon, 17 Feb 2025 12:21:08 +0100
-Subject: [PATCH] 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.
-
-Signed-off-by: Felix Fietkau <nbd at nbd.name>
----
-
---- a/net/bridge/br_input.c
-+++ b/net/bridge/br_input.c
-@@ -152,6 +152,8 @@ int br_handle_frame_finish(struct net *n
- pkt_type = BR_PKT_MULTICAST;
- if (br_multicast_rcv(&brmctx, &pmctx, vlan, skb, vid))
- goto drop;
-+ if (br->dev->flags & IFF_ALLMULTI)
-+ local_rcv = true;
- }
- }
-
diff --git a/target/linux/generic/pending-6.6/710-bridge-add-knob-for-filtering-rx-tx-BPDU-pack.patch b/target/linux/generic/pending-6.6/710-bridge-add-knob-for-filtering-rx-tx-BPDU-pack.patch
index d62ccc571c..5916b5eac2 100644
--- a/target/linux/generic/pending-6.6/710-bridge-add-knob-for-filtering-rx-tx-BPDU-pack.patch
+++ b/target/linux/generic/pending-6.6/710-bridge-add-knob-for-filtering-rx-tx-BPDU-pack.patch
@@ -45,7 +45,7 @@ Signed-off-by: Felix Fietkau <nbd at nbd.name>
if (!(p->flags & BR_BCAST_FLOOD) && skb->dev != br->dev)
--- a/net/bridge/br_input.c
+++ b/net/bridge/br_input.c
-@@ -369,6 +369,8 @@ static rx_handler_result_t br_handle_fra
+@@ -368,6 +368,8 @@ static rx_handler_result_t br_handle_fra
fwd_mask |= p->group_fwd_mask;
switch (dest[5]) {
case 0x00: /* Bridge Group Address */
More information about the lede-commits
mailing list