Linux-kernel mailing list archive 1998-42,: Re: bridging fix? Which (fwd)

# Re: bridging fix? Which (fwd)

Peter T. Breuer (ptb@it.uc3m.es)
Thu, 22 Oct 1998 20:39:07 +0200 (MET DST)

- Messages sorted by: [ date ][ thread ][ subject ][ author ]
- Next message: jens@pinguin.conetix.de: "Re: Motherboard design specifically for Linux"
- Previous message: Andre M. Hedrick: "Re: (U)DMA Explained (Re: Kernel freeze on boot (.123-.125) in IDE init)"

"A month of sundays ago Andreas Haumer wrote:"
>
> > I would love to have just the fix for this as a patch. I know that's
> > too much to ask, so I'm asking just to be clued in on the eureka that
> > solved this.
> >
> I think that's what you are looking for:

Yes - thank you very much. It compiles .. haven't tested yet.

I certainly don't understand this fix. It seems to work by not letting us
miss a code path that should unqueue a skb by not queuing it in the first
place, which kind of hurts my head (but I don't grok network code at all).
The unqueue is still missable but never gets an opportunity to be missed
and hurt. I get a vague sensation that this may be a kind of reentrancy
problem, but not much more.

> *** linux-2.0.35/net/bridge/br.c Tue Aug 26 20:05:34 1997
> --- linux/net/bridge/br.c Sat Oct 17 16:04:22 1998
> ***************
> *** 921,930 ****
> skb->pkt_bridged = IS_BRIDGED;
> skb->arp = 1; /* do not resolve... */
> skb->h.raw = skb->data + ETH_HLEN;
> ! save_flags(flags);
> ! cli();
> ! skb_queue_tail(dev->buffs, skb);
> ! restore_flags(flags);
> return(0);
> }
>
> --- 921,927 ----
> skb->pkt_bridged = IS_BRIDGED;
> skb->arp = 1; /* do not resolve... */
> skb->h.raw = skb->data + ETH_HLEN;
> ! dev_queue_xmit(skb, dev, SOPRI_INTERACTIVE);
> return(0);
> }
>
> ***************
> *** 977,986 ****
> skb->pkt_bridged = IS_BRIDGED;
> skb->arp = 1; /* do not resolve... */
> skb->h.raw = skb->data + ETH_HLEN;
> ! save_flags(flags);
> ! cli();
> ! skb_queue_tail(dev->buffs, skb);
> ! restore_flags(flags);
> return(0);
> }
>
> --- 974,981 ----
> skb->pkt_bridged = IS_BRIDGED;
> skb->arp = 1; /* do not resolve... */
> skb->h.raw = skb->data + ETH_HLEN;
> !
> ! dev_queue_xmit(skb, dev, SOPRI_INTERACTIVE);
> return(0);
> }
>
> HTH
>
> - andreas
>
> --
> Andreas Haumer | email: andreas@xss.co.at | PGP key available
> *x Software + Systeme | phone: +43.1.6001508 | on request.
> Buchengasse 67/8 | +43.664.3004449 |
> A-1100 Vienna, Austria | fax: +43.1.6001507 | AH327-RIPE

Peter

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/

- Next message: jens@pinguin.conetix.de: "Re: Motherboard design specifically for Linux"
- Previous message: Andre M. Hedrick: "Re: (U)DMA Explained (Re: Kernel freeze on boot (.123-.125) in IDE init)"