netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: David L Stevens <david.stevens@oracle.com>
To: David Miller <davem@davemloft.net>
Cc: netdev@vger.kernel.org
Subject: Re: [PATCHv4 net-next 2/3] sunvnet: allow admin to set sunvnet MTU
Date: Tue, 16 Sep 2014 14:51:37 -0400	[thread overview]
Message-ID: <541886B9.3010206@oracle.com> (raw)
In-Reply-To: <541785D8.5030101@oracle.com>



On 09/15/2014 08:35 PM, David L Stevens wrote:

>   */
>  #define VNET_TX_TIMEOUT			(5 * HZ)
>  
> -#define VNET_MAXPACKET			1518ULL /* ETH_FRAMELEN + VLAN_HDR */
> +#define VNET_MAXPACKET			65553ULL /* 64K-1  +ETH HDR +VLAN HDR*/
>  #define VNET_TX_RING_SIZE		512
>  #define VNET_TX_WAKEUP_THRESH(dr)	((dr)->pending / 4)

While looking at adding TSO support, I've turned up a bug with this.

The transmit buffer mapping should be using a cookie per-page and this increases
the page count (without page alignment) from 2 with a 1500-byte MTU to 10 with a 64K MTU
+ framing and allowing from unaligned buffers.

I think it worked during my testing because the pages were contiguous, but the tx buffer
allocation code is assuming 2 pages (and 2 cookies) max.

So, it's incorrect. I'll fix and repost; please don't apply these yet.

							+-DLS

  reply	other threads:[~2014-09-16 18:51 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-09-16  0:35 [PATCHv4 net-next 2/3] sunvnet: allow admin to set sunvnet MTU David L Stevens
2014-09-16 18:51 ` David L Stevens [this message]
2014-09-16 19:10   ` David Miller
2014-09-17  9:07   ` David Laight

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=541886B9.3010206@oracle.com \
    --to=david.stevens@oracle.com \
    --cc=davem@davemloft.net \
    --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).