All of lore.kernel.org
 help / color / mirror / Atom feed
* [Bridge] [PATCH] fix 802.3ad multicast
@ 2006-04-06 16:15 Vlad Drukker
  2006-04-07 23:59 ` Stephen Hemminger
  0 siblings, 1 reply; 3+ messages in thread
From: Vlad Drukker @ 2006-04-06 16:15 UTC (permalink / raw)
  To: shemminger; +Cc: bridge

[-- Attachment #1: Type: text/plain, Size: 165 bytes --]

Hi Stephen,

there was a bug in bridging bonds.
multicast packets needed for 802.3ad netif_carrier_ok() were dropped.
attached patch works for me.

Cheers,
Vlad.




[-- Attachment #2: fix_br_multicast.patch --]
[-- Type: text/x-patch, Size: 1344 bytes --]

Signed-off-by: Vlad Drukker <vlad@storewiz.com>
---
[BRIDGE] fix 802.3ad multicast frame handling
	core netif code does handle_bridge before calling protocol handler
	for ETH_P_SLOW packet_type. when BR_STATE_DISABLED is set for
	bonded port, netif_carrier_ok() will always fail for 802.3ad bond,
	because 'partner' (multicast) packet has to be received via
	_disabled_ port, causing bond to stay in BR_STATE_DISABLED forever.

---
commit e78e0ecc216f934662ae0a10df61c9e2ade44647
tree d491d94f3f043fa698e25cde863b97adc34693b2
parent e77d1795d3eb2999e271cee8957240f161a5461c
author Vlad Drukker <vlad@storewiz.com> Thu, 06 Apr 2006 18:56:51 +0300
committer Vlad Drukker <vlad@storewiz.com> Thu, 06 Apr 2006 18:56:51 +0300

 net/bridge/br_input.c |    4 +++-
 1 files changed, 3 insertions(+), 1 deletions(-)

diff --git a/net/bridge/br_input.c b/net/bridge/br_input.c
index b776656..6c72c5e 100644
--- a/net/bridge/br_input.c
+++ b/net/bridge/br_input.c
@@ -125,7 +125,9 @@ int br_handle_frame(struct net_bridge_po
 	struct sk_buff *skb = *pskb;
 	const unsigned char *dest = eth_hdr(skb)->h_dest;
 
-	if (p->state == BR_STATE_DISABLED)
+	if (p->state == BR_STATE_DISABLED
+			&& !(skb->dev->priv_flags & IFF_MASTER_8023AD
+			&& skb->protocol == __constant_htons(ETH_P_SLOW)))
 		goto err;
 
 	if (!is_valid_ether_addr(eth_hdr(skb)->h_source))

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [Bridge] [PATCH] fix 802.3ad multicast
  2006-04-06 16:15 [Bridge] [PATCH] fix 802.3ad multicast Vlad Drukker
@ 2006-04-07 23:59 ` Stephen Hemminger
  2006-04-09 14:42   ` Vlad Drukker
  0 siblings, 1 reply; 3+ messages in thread
From: Stephen Hemminger @ 2006-04-07 23:59 UTC (permalink / raw)
  To: Vlad Drukker; +Cc: bridge

On Thu, 06 Apr 2006 19:15:06 +0300
Vlad Drukker <vlad@storewiz.com> wrote:

> Hi Stephen,
> 
> there was a bug in bridging bonds.
> multicast packets needed for 802.3ad netif_carrier_ok() were dropped.
> attached patch works for me.
> 
> Cheers,
> Vlad.
> 
> 
> 

Making a bonding specific hack like this seems wrong. The
port could also be disabled during shutdown (for RCU removal),
and in that case we need to drop the packet.

There must be a better solution.

-- 
Stephen Hemminger <shemminger@osdl.org>
OSDL http://developer.osdl.org/~shemminger

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [Bridge] [PATCH] fix 802.3ad multicast
  2006-04-07 23:59 ` Stephen Hemminger
@ 2006-04-09 14:42   ` Vlad Drukker
  0 siblings, 0 replies; 3+ messages in thread
From: Vlad Drukker @ 2006-04-09 14:42 UTC (permalink / raw)
  To: Stephen Hemminger; +Cc: bridge

On Fri, 2006-04-07 at 16:59 -0700, Stephen Hemminger wrote:
> On Thu, 06 Apr 2006 19:15:06 +0300
> Vlad Drukker <vlad@storewiz.com> wrote:
> 
> > Hi Stephen,
> > 
> > there was a bug in bridging bonds.
> > multicast packets needed for 802.3ad netif_carrier_ok() were dropped.
> > attached patch works for me.
> > 
> > Cheers,
> > Vlad.
> > 
> > 
> > 
> 
> Making a bonding specific hack like this seems wrong. The
> port could also be disabled during shutdown (for RCU removal),
> and in that case we need to drop the packet.
> 
> There must be a better solution.
> 

you probably right, 
skb_bond() looks like a proper place for this, because
netif_receive_skb() needs to call ETH_P_SLOW hadler instead of
hadle_bridge hook.

the fix is moving to linux-net . 



^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2006-04-09 14:42 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-04-06 16:15 [Bridge] [PATCH] fix 802.3ad multicast Vlad Drukker
2006-04-07 23:59 ` Stephen Hemminger
2006-04-09 14:42   ` Vlad Drukker

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.