From: David Miller <davem@davemloft.net>
To: jarkao2@gmail.cthom
Cc: eric.dumazet@gmail.com, netdev@vger.kernel.org
Subject: Re: [PATCH net-next-2.6] net: pskb_expand_head() optimization
Date: Sun, 12 Sep 2010 15:08:54 -0700 (PDT) [thread overview]
Message-ID: <20100912.150854.193715637.davem@davemloft.net> (raw)
In-Reply-To: <20100912205722.GB2585@del.dom.local>
From: Jarek Poplawski <jarkao2@gmail.com>
Date: Sun, 12 Sep 2010 22:57:22 +0200
> On Sun, Sep 12, 2010 at 09:13:53AM -0700, David Miller wrote:
>>
>> BTW, Jarek, as to your idea to store a tail pointer in the shinfo, how
>> will you sync that tail pointer in all of the shinfo instances
>> referencing the frag list?
>>
>> It simply can't work, we have to copy.
>
> The question is if we need to sync at all? This is shared data at the
> moment, so I can't imagine how the list (especialy doubly linked)
> could be changed without locking? And even if it's possible, I doubt
> copying e.g. like in your current patch can help when an skb is added
> at the tail later.
That's the fundamental issue.
If you look, everywhere we curently do that trick of "use the
skb->prev pointer to remmeber the frag_list tail" the code knows
it has exclusive access to both the skb metadata and the
underlying data.
But for modifications of the frag list during the SKBs lifetime
that's another issue, entirely. All of these functions trimming
the head or tail of the SKB data which can modify the frag
list elements, they can be called from all kinds of contexts.
Look for Alexey Kuznetsov's comments in skbuff.c that read
"mincing fragments" and similar.
The real win with my work is complete unification of all list
handling, and making our packet handling code much more "hackable"
by non-networking kernel hackers.
Really we have the last major core datastructures that do not
use standard lists, and I'm going to convert it so we can
be sane like the rest of the kernel. :-)
next prev parent reply other threads:[~2010-09-12 22:08 UTC|newest]
Thread overview: 33+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-09-03 3:43 [PATCH] net: Frag list lost on head expansion David Miller
2010-09-03 5:48 ` Eric Dumazet
2010-09-03 6:19 ` Eric Dumazet
2010-09-03 9:09 ` [PATCH net-next-2.6] net: pskb_expand_head() optimization Eric Dumazet
2010-09-03 13:46 ` David Miller
2010-09-07 2:20 ` David Miller
2010-09-07 5:02 ` Eric Dumazet
2010-09-07 5:05 ` David Miller
2010-09-07 9:16 ` Jarek Poplawski
2010-09-07 9:37 ` Eric Dumazet
2010-09-10 19:54 ` David Miller
2010-09-11 12:31 ` Jarek Poplawski
2010-09-12 3:30 ` David Miller
2010-09-12 10:45 ` Jarek Poplawski
2010-09-12 10:58 ` Jarek Poplawski
2010-09-12 15:58 ` David Miller
2010-09-12 16:13 ` David Miller
2010-09-12 20:57 ` Jarek Poplawski
2010-09-12 22:08 ` David Miller [this message]
2010-09-13 7:49 ` Jarek Poplawski
2010-09-12 19:55 ` Ben Pfaff
2010-09-12 20:24 ` David Miller
2010-09-12 20:45 ` Jarek Poplawski
2010-09-20 0:17 ` David Miller
2010-09-20 7:21 ` Jarek Poplawski
2010-09-20 9:02 ` Eric Dumazet
2010-09-20 9:14 ` Jarek Poplawski
2010-09-20 12:12 ` Jarek Poplawski
2010-09-20 12:40 ` Eric Dumazet
2010-09-20 16:59 ` David Miller
2010-09-07 1:25 ` David Miller
-- strict thread matches above, loose matches on Subject: below --
2010-07-22 19:12 [PATCH] Fix corruption of skb csum field in pskb_expand_head() of net/core/skbuff.c Andrea Shepard
2010-07-23 5:09 ` [PATCH net-next-2.6] net: pskb_expand_head() optimization Eric Dumazet
2010-07-25 4:06 ` David 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=20100912.150854.193715637.davem@davemloft.net \
--to=davem@davemloft.net \
--cc=eric.dumazet@gmail.com \
--cc=jarkao2@gmail.cthom \
--cc=netdev@vger.kernel.org \
/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).