From: "David S. Miller" <davem@redhat.com>
To: Julian Anastasov <ja@ssi.bg>
Cc: netdev@oss.sgi.com
Subject: Re: tunnel xmit and h.raw
Date: Fri, 3 Oct 2003 08:04:44 -0700 [thread overview]
Message-ID: <20031003080444.173a403c.davem@redhat.com> (raw)
In-Reply-To: <Pine.LNX.4.44.0310031750390.2761-100000@l>
On Fri, 3 Oct 2003 17:56:35 +0300 (EEST)
Julian Anastasov <ja@ssi.bg> wrote:
> On Fri, 3 Oct 2003, David S. Miller wrote:
>
> > Didn't we fix a nearly identical set of bugs in the tunnel
> > drivers just a month or two ago?
>
> The same place, but this one is special: h.raw is updated
> for us on reallocation but if the skb is shared I do not know if this is
> fatal for the other skb users, we change also their h.raw. But I rely
> on your opinion, may be it is safer with this change.
Oh, I see, the code is actually not buggy as-is. The following two
sequences are identical:
1) skb->h.raw = skb->nh.raw;
new_skb = skb_realloc_headroom(...);
skb = new_skb;
2) new_skb = skb_realloc_headroom(...);
skb = new_skb;
skb->h.raw = skb->nh.raw;
Because skb_realloc_headroom() keeps all the skb->*.raw pointers
in the right relative place if it allocates new data pointers or
whatever.
But the code is certainly clearer to read with your changes so I'll
add them as a code cleanup instead of a bug fix :)
next prev parent reply other threads:[~2003-10-03 15:04 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-10-03 0:00 tunnel xmit and h.raw Julian Anastasov
2003-10-03 14:30 ` David S. Miller
2003-10-03 14:56 ` Julian Anastasov
2003-10-03 15:04 ` David S. Miller [this message]
2003-10-03 15:05 ` David S. Miller
2003-10-03 15:49 ` Mika Penttilä
2003-10-07 15:32 ` David S. Miller
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=20031003080444.173a403c.davem@redhat.com \
--to=davem@redhat.com \
--cc=ja@ssi.bg \
--cc=netdev@oss.sgi.com \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).