lkml.org 
[lkml]   [1998]   [Oct]   [22]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: bridging fix? Which (fwd)
Hi!

Peter T. Breuer wrote:
>
> [Cc: to linux-kernel, in case some other network guru knows and alan
> is busy]
>
> Hello Alan
>
> I know you finally found and fixed the bridging code leak somewhere in
> the recent 2.0.36pre series or just before. But I haven't been able to
> figure out what the fix was, by inspection. I would be deeply grateful
> if you could tell me what the line or lines was .. I think some
> intrepid soul managed to find the line that did the damage using the
> memleak patches.
>
Yeah, I think that was me :-)

> I saw the leak first on a server I had at 2.0.33. P100 with 3c905
> and buslogic fast and wide. It went down in a week serving NFS. You
> steered me to the cause and workaround.
>
Yes, the system where I found that also went down after a few days.
I have some quite impressive vmstat statistics where you can see a
almost linear decreasing in available memory...

[...]
>
> 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:

*** 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

-
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/

\
 
 \ /
  Last update: 2005-03-22 13:45    [W:0.041 / U:0.160 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site