mirror of
https://github.com/kernelkit/infix.git
synced 2026-07-22 01:13:00 +02:00
34 lines
1.3 KiB
Diff
34 lines
1.3 KiB
Diff
From 9044f8f0599e025644d13c0b031826f5765bbc34 Mon Sep 17 00:00:00 2001
|
|
From: Joachim Wiberg <troglobit@gmail.com>
|
|
Date: Tue, 5 Mar 2024 06:44:41 +0100
|
|
Subject: [PATCH 07/50] net: bridge: Ignore router ports when forwarding L2
|
|
multicast
|
|
|
|
Multicast router ports are either statically configured or learned from
|
|
control protocol traffic (IGMP/MLD/PIM). These protocols regulate IP
|
|
multicast -- MAC multicast should always be forwarded through flooding
|
|
of unknown multicast or using permanent MDB entries.
|
|
|
|
Signed-off-by: Tobias Waldekranz <tobias@waldekranz.com>
|
|
Signed-off-by: Joachim Wiberg <troglobit@gmail.com>
|
|
---
|
|
net/bridge/br_private.h | 5 ++++-
|
|
1 file changed, 4 insertions(+), 1 deletion(-)
|
|
|
|
diff --git a/net/bridge/br_private.h b/net/bridge/br_private.h
|
|
index ccbaaa96f7c7..d7187bead496 100644
|
|
--- a/net/bridge/br_private.h
|
|
+++ b/net/bridge/br_private.h
|
|
@@ -1097,7 +1097,10 @@ br_multicast_get_first_rport_node(struct net_bridge_mcast *brmctx,
|
|
if (skb->protocol == htons(ETH_P_IPV6))
|
|
return rcu_dereference(hlist_first_rcu(&brmctx->ip6_mc_router_list));
|
|
#endif
|
|
- return rcu_dereference(hlist_first_rcu(&brmctx->ip4_mc_router_list));
|
|
+ if (skb->protocol == htons(ETH_P_IP))
|
|
+ return rcu_dereference(hlist_first_rcu(&brmctx->ip4_mc_router_list));
|
|
+
|
|
+ return NULL;
|
|
}
|
|
|
|
static inline struct net_bridge_port *
|