From: ANNIE LI <annie.li@oracle.com>
To: James Harper <james.harper@bendigoit.com.au>
Cc: KonradRzeszutekWilk <konrad@kernel.org>,
Ian Campbell <Ian.Campbell@citrix.com>,
xen-devel <xen-devel@lists.xen.org>
Subject: Re: netchannel vs MAX_SKB_FRAGS (Was: Re: [PATCH] xen/netfront: handle compound page fragments on transmit)
Date: Fri, 23 Nov 2012 14:49:41 +0800 [thread overview]
Message-ID: <50AF1C85.50604@oracle.com> (raw)
In-Reply-To: <6035A0D088A63A46850C3988ED045A4B32C95411@BITCOM1.int.sbss.com.au>
On 2012-11-23 10:10, James Harper wrote:
>> On 2012-11-21 0:04, Ian Campbell wrote:
>>> Limiting to just xen-devel folks.
>>>
>>> On Tue, 2012-11-20 at 15:54 +0000, Ian Campbell wrote:
>>>
>>> This highlights a couple of issues, the main one is that implicitly
>>> including MAX_SKB_FRAGS in the PV net protocol is just madness. It can
>>> and has changed in the past. Someone really needs to (retroactively)
>>> figure out what a sensible default minimum which front and back must
>>> support is and use it in the front and backends instead of
>>> MAX_SKB_FRAGS. Probably something derived from the existing 64K limit
>>> (Linux has used 17 and 18 as MAX_SKB_FRAGS in the past).
>>>
>>> Then perhaps implement a feature-flag to allow front and backends to
>>> negotiate something bigger if they like.
>>>
>>> It might also be interesting for front and backends to coalesce
>>> multiple ring slots into compound pages.
>> Yes, MAX_SKB_FRAGS is max frag number, not max slot number required.
>> But I am not so clear about the whole implementation here. Does it mean
>> netfront/netback uses something like MAX_SKB_FRAGS*SLOTS_PER_FRAG?
>> and SLOTS_PER_FRAG can be adjusted based on different situation? If
>> netfront and netback negotiate this value, then xenstore key feature is
>> required, right?
>> As mentioned in another compound page fragments patch, for non-
>> compound page, this value could be 64K/PAGE_SIZE + 1, but if taking account
>> into compound page, the worse case is around 48 slots(in 1+4096+1 case). It
>> is hard to negotiate this between netfront and netback for different packets.
>>
> FWIW, Windows appears to have no real limit in its SG list, and if its>18 then netback (or linux?) just drops such packets.
This should be netback dropping packets in function netbk_count_requests,
if (unlikely(frags >= MAX_SKB_FRAGS)) {
netdev_dbg(vif->dev, "Too many frags\n");
return -frags;
}
> For a 64kb "large" packet, the buffer arrangement would likely be eth hdr + ip hdr + tcp hdr + (64K - total header size)/PAGE_SIZE + 1 frags. It would be good if the documentation of the protocol defined this limitation (which may not even exist if dom0 was something other than Linux anyway).
Agree.
Thanks
Annie
>
> James
>
> _______________________________________________
> Xen-devel mailing list
> Xen-devel@lists.xen.org
> http://lists.xen.org/xen-devel
next prev parent reply other threads:[~2012-11-23 6:49 UTC|newest]
Thread overview: 92+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-10-09 13:47 compound skb frag pages appearing in start_xmit Ian Campbell
2012-10-09 13:54 ` Eric Dumazet
2012-10-09 14:01 ` Eric Dumazet
2012-10-09 14:01 ` Eric Dumazet
2012-10-09 14:23 ` Ian Campbell
2012-10-09 14:33 ` Eric Dumazet
2012-10-09 14:33 ` Eric Dumazet
2012-10-09 14:54 ` Ian Campbell
2012-10-09 14:54 ` Ian Campbell
2012-10-09 14:23 ` Ian Campbell
2012-10-09 14:17 ` Ian Campbell
2012-10-09 14:27 ` Eric Dumazet
2012-10-09 14:40 ` Ian Campbell
2012-10-09 14:51 ` Eric Dumazet
2012-10-09 14:51 ` Eric Dumazet
2012-10-10 10:13 ` [Xen-devel] " Ian Campbell
2012-10-10 12:24 ` Sander Eikelenboom
2012-10-10 12:29 ` Ian Campbell
2012-10-10 12:29 ` [Xen-devel] " Ian Campbell
2012-10-10 13:31 ` Sander Eikelenboom
2012-10-10 13:31 ` Sander Eikelenboom
2012-10-10 13:09 ` [Xen-devel] " Ian Campbell
2012-10-10 14:49 ` Sander Eikelenboom
2012-10-10 14:49 ` [Xen-devel] " Sander Eikelenboom
2012-10-11 8:02 ` Ian Campbell
2012-10-11 10:00 ` Sander Eikelenboom
2012-10-11 10:05 ` Eric Dumazet
2012-10-11 10:05 ` [Xen-devel] " Eric Dumazet
2012-10-11 10:14 ` Ian Campbell
2012-10-11 10:20 ` Sander Eikelenboom
2012-10-11 10:20 ` [Xen-devel] " Sander Eikelenboom
2012-11-15 2:31 ` ANNIE LI
2012-11-15 2:31 ` [Xen-devel] " ANNIE LI
2012-11-19 15:43 ` Sander Eikelenboom
2012-11-20 8:30 ` [Xen-devel] " Stefan Bader
2012-11-20 9:21 ` Ian Campbell
2012-11-20 11:36 ` Ian Campbell
2012-11-20 11:36 ` [Xen-devel] " Ian Campbell
2012-11-21 2:42 ` ANNIE LI
2012-11-21 2:42 ` ANNIE LI
2012-11-20 11:40 ` [PATCH] xen/netfront: handle compound page fragments on transmit Ian Campbell
2012-11-20 12:28 ` Jan Beulich
2012-11-20 12:28 ` [Xen-devel] " Jan Beulich
2012-11-20 13:35 ` Ian Campbell
2012-11-20 13:35 ` [Xen-devel] " Ian Campbell
2012-11-20 13:51 ` Jan Beulich
2012-11-20 14:14 ` Ian Campbell
2012-11-20 14:32 ` Jan Beulich
2012-11-20 15:06 ` Ian Campbell
2012-11-20 15:06 ` [Xen-devel] " Ian Campbell
2012-11-20 15:28 ` Eric Dumazet
2012-11-20 15:54 ` Ian Campbell
2012-11-20 16:04 ` netchannel vs MAX_SKB_FRAGS (Was: Re: [PATCH] xen/netfront: handle compound page fragments on transmit) Ian Campbell
2012-11-23 1:30 ` ANNIE LI
2012-11-23 2:10 ` James Harper
2012-11-23 6:49 ` ANNIE LI [this message]
2012-11-23 9:22 ` Paul Durrant
2012-11-23 9:26 ` James Harper
2012-11-23 9:34 ` Ian Campbell
2012-11-23 9:18 ` Ian Campbell
2012-11-23 15:08 ` annie li
2012-11-20 15:54 ` [PATCH] xen/netfront: handle compound page fragments on transmit Ian Campbell
2012-11-20 15:28 ` Eric Dumazet
2012-11-20 15:44 ` [Xen-devel] " Jan Beulich
2012-11-20 16:14 ` Eric Dumazet
2012-11-20 15:44 ` Jan Beulich
2012-11-20 14:32 ` Jan Beulich
2012-11-20 14:14 ` Ian Campbell
2012-11-20 13:51 ` Jan Beulich
2012-11-20 13:30 ` Stefan Bader
2012-11-20 13:30 ` Stefan Bader
2012-11-20 13:45 ` Sander Eikelenboom
2012-11-20 13:45 ` Sander Eikelenboom
2012-11-20 14:45 ` Eric Dumazet
2012-11-20 15:05 ` Ian Campbell
2012-11-20 15:05 ` Ian Campbell
2012-11-20 14:45 ` Eric Dumazet
2012-11-21 2:52 ` ANNIE LI
2012-11-21 11:09 ` Ian Campbell
2012-11-21 11:09 ` Ian Campbell
2012-11-21 2:52 ` ANNIE LI
2012-11-20 11:40 ` Ian Campbell
2012-11-20 8:30 ` compound skb frag pages appearing in start_xmit Stefan Bader
2012-10-11 10:14 ` Ian Campbell
2012-10-11 10:00 ` Sander Eikelenboom
2012-10-11 8:02 ` Ian Campbell
2012-10-10 13:09 ` Ian Campbell
2012-10-10 10:13 ` Ian Campbell
2012-10-09 14:40 ` Ian Campbell
2012-10-09 14:27 ` Eric Dumazet
2012-10-09 14:17 ` Ian Campbell
2012-10-09 13:54 ` Eric Dumazet
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=50AF1C85.50604@oracle.com \
--to=annie.li@oracle.com \
--cc=Ian.Campbell@citrix.com \
--cc=james.harper@bendigoit.com.au \
--cc=konrad@kernel.org \
--cc=xen-devel@lists.xen.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 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.