netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* TSQ accounting skb->truesize degrades throughput for large packets
@ 2013-09-06 10:16 Wei Liu
  2013-09-06 12:57 ` Eric Dumazet
  0 siblings, 1 reply; 20+ messages in thread
From: Wei Liu @ 2013-09-06 10:16 UTC (permalink / raw)
  To: Eric Dumazet; +Cc: wei.liu2, Jonathan Davies, Ian Campbell, netdev, xen-devel

Hi Eric

I have some questions regarding TSQ and I hope you can shed some light
on this.

Our observation is that with the default TSQ limit (128K), throughput
for Xen network driver for large packets degrades. That's because we now
only have 1 packet in queue.

I double-checked that skb->len is indeed <64K. Then I discovered that
TSQ actually accounts for skb->truesize and the packets generated had
skb->truesize > 64K which effectively prevented us from putting 2
packets in queue.

There seems to be no way to limit skb->truesize inside driver -- the skb
is already constructed when it comes to xen-netfront.

My questions are:
  1) I see the comment in tcp_output.c saying: "TSQ : sk_wmem_alloc
     accounts skb truesize, including skb overhead. But thats OK", I
     don't quite understand why it is OK.
  2) presumably other drivers will suffer from this as well, is it
     possible to account for skb->len instead of skb->truesize?
  3) if accounting skb->truesize is on purpose, does that mean we only
     need to tune that value instead of trying to fix our driver (if
     there is a way to)?

Thanks
Wei.

^ permalink raw reply	[flat|nested] 20+ messages in thread

end of thread, other threads:[~2013-10-01  3:45 UTC | newest]

Thread overview: 20+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-09-06 10:16 TSQ accounting skb->truesize degrades throughput for large packets Wei Liu
2013-09-06 12:57 ` Eric Dumazet
2013-09-06 13:12   ` Wei Liu
2013-09-06 16:36   ` Zoltan Kiss
2013-09-06 16:56     ` Eric Dumazet
2013-09-09  9:27       ` Jason Wang
2013-09-09 13:47         ` Eric Dumazet
2013-09-10  7:45           ` Jason Wang
2013-09-10 12:35             ` Eric Dumazet
2013-09-06 17:00     ` Eric Dumazet
2013-09-07 17:21       ` Eric Dumazet
2013-09-09 21:41         ` Zoltan Kiss
2013-09-09 21:56           ` Eric Dumazet
     [not found]             ` <loom.20130921T045654-573@post.gmane.org>
     [not found]               ` <20130921150327.GA9078@zion.uk.xensource.com>
2013-09-22  2:36                 ` [Xen-devel] " Cong Wang
2013-09-22 14:58                   ` Eric Dumazet
2013-09-27 10:28                     ` [PATCH] tcp: TSQ can use a dynamic limit Eric Dumazet
2013-09-27 15:08                       ` Neal Cardwell
2013-09-29 15:41                       ` Cong Wang
2013-10-01  3:52                       ` David Miller
2013-09-09  5:28       ` TSQ accounting skb->truesize degrades throughput for large packets Cong Wang

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).