From: Bart De Schuymer <bdschuym@pandora.be>
To: "David S. Miller" <davem@redhat.com>, Steve Hill <steve@navaho.co.uk>
Cc: netdev@oss.sgi.com
Subject: Re: 2.6.0-test9 : bridge freezes
Date: Tue, 16 Dec 2003 08:43:58 +0100 [thread overview]
Message-ID: <200312160843.58992.bdschuym@pandora.be> (raw)
In-Reply-To: <20031215171732.4877acd1.davem@redhat.com>
On Tuesday 16 December 2003 02:17, David S. Miller wrote:
> There must be something in particular that the IPV4 fragmentation code
> is doing that makes these fragment reference drops get forgotten. Hmmm...
>
> I just noticed that both bridge netfilter and IPV4 fragmentation make much
> use of the skb->cb[] control block, this may be the true source of the
> troubles.
>
> In fact, since bridge netfilter expects pointers to be there, I'm surprised
> this does not cause a crash.
It only expects a pointer in br_nf_forward_finish() for ARP traffic. I
checked and the ARP code doesn't use the control buffer.
For IP traffic, it uses the control buffer just before and just after
the call to the IP PRE_ROUTING hook.
OK, I just looked at the ip_fragment.c code and it uses the control buffer
too. You are truly amazing. I'll use skbuff.c::nf_bridge_info instead.
Steve, does this patch fix things? Of course, first remove your code from
ip_fragment.c. I haven't tested this patch yet, this will have to wait
until this evening.
Dave, I'll cook up a slightly different patch for you later, I think
nf_bridge->hh is now a bad name, I'll change it into nf_bridge->data.
thanks,
Bart
--- linux-2.6.0-test11-bk10/net/bridge/br_netfilter.c.old 2003-12-16 08:33:35.000000000 +0100
+++ linux-2.6.0-test11-bk10/net/bridge/br_netfilter.c 2003-12-16 08:34:12.000000000 +0100
@@ -38,11 +38,9 @@
#define skb_origaddr(skb) (((struct bridge_skb_cb *) \
- (skb->cb))->daddr.ipv4)
+ (skb->nf_bridge->hh))->daddr.ipv4)
#define store_orig_dstaddr(skb) (skb_origaddr(skb) = (skb)->nh.iph->daddr)
#define dnat_took_place(skb) (skb_origaddr(skb) != (skb)->nh.iph->daddr)
-#define clear_cb(skb) (memset(&skb_origaddr(skb), 0, \
- sizeof(struct bridge_skb_cb)))
#define has_bridge_parent(device) ((device)->br_port != NULL)
#define bridge_parent(device) ((device)->br_port->br->dev)
@@ -203,7 +201,6 @@ bridged_dnat:
*/
nf_bridge->mask |= BRNF_BRIDGED_DNAT;
skb->dev = nf_bridge->physindev;
- clear_cb(skb);
if (skb->protocol ==
__constant_htons(ETH_P_8021Q)) {
skb_push(skb, VLAN_HLEN);
@@ -224,7 +221,6 @@ bridged_dnat:
dst_hold(skb->dst);
}
- clear_cb(skb);
skb->dev = nf_bridge->physindev;
if (skb->protocol == __constant_htons(ETH_P_8021Q)) {
skb_push(skb, VLAN_HLEN);
next prev parent reply other threads:[~2003-12-16 7:43 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-12-15 13:15 2.6.0-test9 : bridge freezes Steve Hill
2003-12-16 1:17 ` David S. Miller
2003-12-16 7:43 ` Bart De Schuymer [this message]
2003-12-16 7:46 ` David S. Miller
2003-12-16 9:00 ` Steve Hill
2003-12-16 21:46 ` Bart De Schuymer
2003-12-16 21:49 ` David S. Miller
2003-12-17 8:36 ` Steve Hill
2003-12-17 18:27 ` Bart De Schuymer
-- strict thread matches above, loose matches on Subject: below --
2003-11-22 15:27 SVR Anand
2003-11-22 16:19 ` Gene Heskett
2003-11-22 16:20 ` Linus Torvalds
2003-11-23 23:26 ` David S. Miller
2003-11-24 0:02 ` Markus Hästbacka
2003-11-22 19:18 ` Markus Hästbacka
2003-11-24 19:09 ` Stephen Hemminger
2003-11-25 6:39 ` SVR Anand
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=200312160843.58992.bdschuym@pandora.be \
--to=bdschuym@pandora.be \
--cc=davem@redhat.com \
--cc=netdev@oss.sgi.com \
--cc=steve@navaho.co.uk \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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.