public inbox for netdev@vger.kernel.org 
 help / color / mirror / Atom feed
From: Andrew Lunn <andrew@lunn•ch>
To: "Russell King (Oracle)" <linux@armlinux•org.uk>
Cc: Stefan Chulski <stefanc@marvell•com>,
	Marcin Wojtas <mw@semihalf•com>,
	"netdev@vger•kernel.org" <netdev@vger•kernel.org>
Subject: Re: mvpp2: incorrect max mtu?
Date: Fri, 14 May 2021 16:35:12 +0200	[thread overview]
Message-ID: <YJ6KoBEoEDb0VC7a@lunn.ch> (raw)
In-Reply-To: <20210514130018.GC12395@shell.armlinux.org.uk>

On Fri, May 14, 2021 at 02:00:18PM +0100, Russell King (Oracle) wrote:
> Hi all,
> 
> While testing out the 10G speeds on my Macchiatobin platforms, the first
> thing I notice is that they only manage about 1Gbps at a MTU of 1500.
> As expected, this increases when the MTU is increased - a MTU of 9000
> works, and gives a useful performance boost.
> 
> Then comes the obvious question - what is the maximum MTU.
> 
> #define MVPP2_BM_JUMBO_FRAME_SIZE       10432   /* frame size 9856 */
> 
> So, one may assume that 9856 is the maximum. However:
> 
> # ip li set dev eth0 mtu 9888
> # ip li set dev eth0 mtu 9889
> Error: mtu greater than device maximum.

Hi Russell

It all seems inconsistent:

https://elixir.bootlin.com/linux/latest/source/drivers/net/ethernet/marvell/mvpp2/mvpp2_main.c#L6879

	/* MTU range: 68 - 9704 */
	dev->min_mtu = ETH_MIN_MTU;
	/* 9704 == 9728 - 20 and rounding to 8 */
	dev->max_mtu = MVPP2_BM_JUMBO_PKT_SIZE;

Maybe this comment is correct, the code is now wrong, and the MAX MTU
should be 9704?

      Andrew

  parent reply	other threads:[~2021-05-14 14:35 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-05-14 13:00 mvpp2: incorrect max mtu? Russell King (Oracle)
2021-05-14 14:25 ` Marcin Wojtas
2021-05-14 17:19   ` Russell King (Oracle)
2021-05-14 14:35 ` Andrew Lunn [this message]
2021-05-14 17:21   ` Russell King (Oracle)
2021-05-18  6:09 ` [EXT] " Stefan Chulski
2021-05-18  9:41   ` Russell King (Oracle)
2021-05-18 10:25     ` Stefan Chulski
2021-05-23 10:54       ` Stefan Chulski

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=YJ6KoBEoEDb0VC7a@lunn.ch \
    --to=andrew@lunn$(echo .)ch \
    --cc=linux@armlinux$(echo .)org.uk \
    --cc=mw@semihalf$(echo .)com \
    --cc=netdev@vger$(echo .)kernel.org \
    --cc=stefanc@marvell$(echo .)com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html
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