netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Fw: [Bug 43277] New: net/e1000e set mtu larger than 1500 fails
@ 2012-05-22 18:19 Stephen Hemminger
  2012-05-22 18:25 ` Stephen Hemminger
  0 siblings, 1 reply; 6+ messages in thread
From: Stephen Hemminger @ 2012-05-22 18:19 UTC (permalink / raw)
  To: netdev; +Cc: e1000-devel



Begin forwarded message:

Date: Tue, 22 May 2012 18:13:21 +0000 (UTC)
From: bugzilla-daemon@bugzilla.kernel.org
To: shemminger@linux-foundation.org
Subject: [Bug 43277] New: net/e1000e set mtu larger than 1500 fails


https://bugzilla.kernel.org/show_bug.cgi?id=43277

           Summary: net/e1000e set mtu larger than 1500 fails
           Product: Networking
           Version: 2.5
    Kernel Version: 3.4
          Platform: All
        OS/Version: Linux
              Tree: Mainline
            Status: NEW
          Severity: normal
          Priority: P1
         Component: IPV4
        AssignedTo: shemminger@linux-foundation.org
        ReportedBy: che@chrekh.se
        Regression: Yes


In kernel 3.4 I can no longer use jumbo-frames with my e1000e network
interface.

 $ sudo ip link set eth1 mtu 9000
 RTNETLINK answers: Invalid argument

Card-info (from kernel-log)

 e1000e 0000:05:00.1: eth1: (PCI Express:2.5GT/s:Width x4) 00:1b:78:59:84:25
 e1000e 0000:05:00.1: eth1: Intel(R) PRO/1000 Network Connection
 e1000e 0000:05:00.1: eth1: MAC: 0, PHY: 4, PBA No: D51930-003

I have bisected and found:

 70495a500d787c0c90a136acf454cb7d0eecd82e is the first bad commit

-- 
Configure bugmail: https://bugzilla.kernel.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

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

* Re: [Bug 43277] New: net/e1000e set mtu larger than 1500 fails
  2012-05-22 18:19 Fw: [Bug 43277] New: net/e1000e set mtu larger than 1500 fails Stephen Hemminger
@ 2012-05-22 18:25 ` Stephen Hemminger
  2012-05-22 18:28   ` Allan, Bruce W
  2012-05-22 18:39   ` Christer Ekholm
  0 siblings, 2 replies; 6+ messages in thread
From: Stephen Hemminger @ 2012-05-22 18:25 UTC (permalink / raw)
  To: che; +Cc: netdev, e1000-devel

On Tue, 22 May 2012 11:19:50 -0700
Stephen Hemminger <shemminger@vyatta.com> wrote:

> 
> 
> Begin forwarded message:
> 
> Date: Tue, 22 May 2012 18:13:21 +0000 (UTC)
> From: bugzilla-daemon@bugzilla.kernel.org
> To: shemminger@linux-foundation.org
> Subject: [Bug 43277] New: net/e1000e set mtu larger than 1500 fails
> 
> 
> https://bugzilla.kernel.org/show_bug.cgi?id=43277
> 
>            Summary: net/e1000e set mtu larger than 1500 fails
>            Product: Networking
>            Version: 2.5
>     Kernel Version: 3.4
>           Platform: All
>         OS/Version: Linux
>               Tree: Mainline
>             Status: NEW
>           Severity: normal
>           Priority: P1
>          Component: IPV4
>         AssignedTo: shemminger@linux-foundation.org
>         ReportedBy: che@chrekh.se
>         Regression: Yes
> 
> 
> In kernel 3.4 I can no longer use jumbo-frames with my e1000e network
> interface.
> 
>  $ sudo ip link set eth1 mtu 9000
>  RTNETLINK answers: Invalid argument

I believe the problem is detected here. Check system console log (dmesg).
The hardware does not allow receive hashing and checksum offload together
in Jumbo mode.

	/*
	 * IP payload checksum (enabled with jumbos/packet-split when
	 * Rx checksum is enabled) and generation of RSS hash is
	 * mutually exclusive in the hardware.
	 */
	if ((netdev->features & NETIF_F_RXCSUM) &&
	    (netdev->features & NETIF_F_RXHASH)) {
		e_err("Jumbo frames cannot be enabled when both receive checksum offload and receive hashing are enabled.  Disable one of the receive offload features before enabling jumbos.\n");
		return -EINVAL;
	}

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

* RE: [Bug 43277] New: net/e1000e set mtu larger than 1500 fails
  2012-05-22 18:25 ` Stephen Hemminger
@ 2012-05-22 18:28   ` Allan, Bruce W
  2012-05-22 18:39   ` Christer Ekholm
  1 sibling, 0 replies; 6+ messages in thread
From: Allan, Bruce W @ 2012-05-22 18:28 UTC (permalink / raw)
  To: Stephen Hemminger, che; +Cc: netdev, e1000-devel

> -----Original Message-----
> From: netdev-owner@vger.kernel.org [mailto:netdev-
> owner@vger.kernel.org] On Behalf Of Stephen Hemminger
> Sent: Tuesday, May 22, 2012 11:25 AM
> To: che@chrekh.se
> Cc: netdev@vger.kernel.org; e1000-devel@lists.sf.net
> Subject: Re: [Bug 43277] New: net/e1000e set mtu larger than 1500
> fails
> 
> On Tue, 22 May 2012 11:19:50 -0700
> Stephen Hemminger <shemminger@vyatta.com> wrote:
> 
> >
> >
> > Begin forwarded message:
> >
> > Date: Tue, 22 May 2012 18:13:21 +0000 (UTC)
> > From: bugzilla-daemon@bugzilla.kernel.org
> > To: shemminger@linux-foundation.org
> > Subject: [Bug 43277] New: net/e1000e set mtu larger than 1500 fails
> >
> >
> > https://bugzilla.kernel.org/show_bug.cgi?id=43277
> >
> >            Summary: net/e1000e set mtu larger than 1500 fails
> >            Product: Networking
> >            Version: 2.5
> >     Kernel Version: 3.4
> >           Platform: All
> >         OS/Version: Linux
> >               Tree: Mainline
> >             Status: NEW
> >           Severity: normal
> >           Priority: P1
> >          Component: IPV4
> >         AssignedTo: shemminger@linux-foundation.org
> >         ReportedBy: che@chrekh.se
> >         Regression: Yes
> >
> >
> > In kernel 3.4 I can no longer use jumbo-frames with my e1000e
> network
> > interface.
> >
> >  $ sudo ip link set eth1 mtu 9000
> >  RTNETLINK answers: Invalid argument
> 
> I believe the problem is detected here. Check system console log
> (dmesg).
> The hardware does not allow receive hashing and checksum offload
> together
> in Jumbo mode.
> 
> 	/*
> 	 * IP payload checksum (enabled with jumbos/packet-split when
> 	 * Rx checksum is enabled) and generation of RSS hash is
> 	 * mutually exclusive in the hardware.
> 	 */
> 	if ((netdev->features & NETIF_F_RXCSUM) &&
> 	    (netdev->features & NETIF_F_RXHASH)) {
> 		e_err("Jumbo frames cannot be enabled when both receive
> checksum offload and receive hashing are enabled.  Disable one of the
> receive offload features before enabling jumbos.\n");
> 		return -EINVAL;
> 	}

That is correct.

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

* Re: [Bug 43277] New: net/e1000e set mtu larger than 1500 fails
  2012-05-22 18:25 ` Stephen Hemminger
  2012-05-22 18:28   ` Allan, Bruce W
@ 2012-05-22 18:39   ` Christer Ekholm
  2012-05-22 18:59     ` Ben Hutchings
  1 sibling, 1 reply; 6+ messages in thread
From: Christer Ekholm @ 2012-05-22 18:39 UTC (permalink / raw)
  To: Stephen Hemminger; +Cc: netdev, Allan, Bruce W, e1000-devel

Stephen Hemminger writes:
 > On Tue, 22 May 2012 11:19:50 -0700
 > Stephen Hemminger <shemminger@vyatta.com> wrote:
 > 
 > 
 > I believe the problem is detected here. Check system console log (dmesg).
 > The hardware does not allow receive hashing and checksum offload together
 > in Jumbo mode.
 > 
 > 	/*
 > 	 * IP payload checksum (enabled with jumbos/packet-split when
 > 	 * Rx checksum is enabled) and generation of RSS hash is
 > 	 * mutually exclusive in the hardware.
 > 	 */
 > 	if ((netdev->features & NETIF_F_RXCSUM) &&
 > 	    (netdev->features & NETIF_F_RXHASH)) {
 > 		e_err("Jumbo frames cannot be enabled when both receive checksum offload and receive hashing are enabled.  Disable one of the receive offload features before enabling jumbos.\n");
 > 		return -EINVAL;
 > 	}

Yes you are right.

 e1000e 0000:05:00.1: eth1: Jumbo frames cannot be enabled when both receive checksum offload and receive hashing are enabled.  Disable one of the receive offload features before enabling jumbos.

How stupid of me to not see that. 

After turning rxhash of, setting of mtu to 9000 is possible again.

$ sudo ethtool -K eth1 rxhash off

$ sudo ip link set eth1 mtu 9000


Sorry to have wasted your time.

 
-- 
 Christer

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

* Re: [Bug 43277] New: net/e1000e set mtu larger than 1500 fails
  2012-05-22 18:39   ` Christer Ekholm
@ 2012-05-22 18:59     ` Ben Hutchings
  2012-05-22 21:29       ` Stephen Hemminger
  0 siblings, 1 reply; 6+ messages in thread
From: Ben Hutchings @ 2012-05-22 18:59 UTC (permalink / raw)
  To: Christer Ekholm; +Cc: Stephen Hemminger, netdev, Allan, Bruce W, e1000-devel

On Tue, 2012-05-22 at 20:39 +0200, Christer Ekholm wrote:
> Stephen Hemminger writes:
>  > On Tue, 22 May 2012 11:19:50 -0700
>  > Stephen Hemminger <shemminger@vyatta.com> wrote:
>  > 
>  > 
>  > I believe the problem is detected here. Check system console log (dmesg).
>  > The hardware does not allow receive hashing and checksum offload together
>  > in Jumbo mode.
>  > 
>  > 	/*
>  > 	 * IP payload checksum (enabled with jumbos/packet-split when
>  > 	 * Rx checksum is enabled) and generation of RSS hash is
>  > 	 * mutually exclusive in the hardware.
>  > 	 */
>  > 	if ((netdev->features & NETIF_F_RXCSUM) &&
>  > 	    (netdev->features & NETIF_F_RXHASH)) {
>  > 		e_err("Jumbo frames cannot be enabled when both receive checksum offload and receive hashing are enabled.  Disable one of the receive offload features before enabling jumbos.\n");
>  > 		return -EINVAL;
>  > 	}
> 
> Yes you are right.
> 
>  e1000e 0000:05:00.1: eth1: Jumbo frames cannot be enabled when both receive checksum offload and receive hashing are enabled.  Disable one of the receive offload features before enabling jumbos.
> 
> How stupid of me to not see that. 
> 
> After turning rxhash of, setting of mtu to 9000 is possible again.
> 
> $ sudo ethtool -K eth1 rxhash off
> 
> $ sudo ip link set eth1 mtu 9000
> 
> 
> Sorry to have wasted your time.

It's not a waste of time.

I think this behaviour is broken: NETIF_F_RXHASH is turned on by default
and user and distribution scripts that set MTU will now be broken until
they know that they need to work around this hardware limitation.  And
why should they ever need to know that?

I think the proper thing to do is to automatically turn off
NETIF_F_RXHASH when the MTU is too high for it to work.  The netdev
still keeps track of whether it is 'wanted'.

Ben.

-- 
Ben Hutchings, Staff Engineer, Solarflare
Not speaking for my employer; that's the marketing department's job.
They asked us to note that Solarflare product names are trademarked.

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

* Re: [Bug 43277] New: net/e1000e set mtu larger than 1500 fails
  2012-05-22 18:59     ` Ben Hutchings
@ 2012-05-22 21:29       ` Stephen Hemminger
  0 siblings, 0 replies; 6+ messages in thread
From: Stephen Hemminger @ 2012-05-22 21:29 UTC (permalink / raw)
  To: Ben Hutchings; +Cc: Christer Ekholm, netdev, Allan, Bruce W, e1000-devel

On Tue, 22 May 2012 19:59:16 +0100
Ben Hutchings <bhutchings@solarflare.com> wrote:

> On Tue, 2012-05-22 at 20:39 +0200, Christer Ekholm wrote:
> > Stephen Hemminger writes:
> >  > On Tue, 22 May 2012 11:19:50 -0700
> >  > Stephen Hemminger <shemminger@vyatta.com> wrote:
> >  > 
> >  > 
> >  > I believe the problem is detected here. Check system console log (dmesg).
> >  > The hardware does not allow receive hashing and checksum offload together
> >  > in Jumbo mode.
> >  > 
> >  > 	/*
> >  > 	 * IP payload checksum (enabled with jumbos/packet-split when
> >  > 	 * Rx checksum is enabled) and generation of RSS hash is
> >  > 	 * mutually exclusive in the hardware.
> >  > 	 */
> >  > 	if ((netdev->features & NETIF_F_RXCSUM) &&
> >  > 	    (netdev->features & NETIF_F_RXHASH)) {
> >  > 		e_err("Jumbo frames cannot be enabled when both receive checksum offload and receive hashing are enabled.  Disable one of the receive offload features before enabling jumbos.\n");
> >  > 		return -EINVAL;
> >  > 	}
> > 
> > Yes you are right.
> > 
> >  e1000e 0000:05:00.1: eth1: Jumbo frames cannot be enabled when both receive checksum offload and receive hashing are enabled.  Disable one of the receive offload features before enabling jumbos.
> > 
> > How stupid of me to not see that. 
> > 
> > After turning rxhash of, setting of mtu to 9000 is possible again.
> > 
> > $ sudo ethtool -K eth1 rxhash off
> > 
> > $ sudo ip link set eth1 mtu 9000
> > 
> > 
> > Sorry to have wasted your time.
> 
> It's not a waste of time.
> 
> I think this behaviour is broken: NETIF_F_RXHASH is turned on by default
> and user and distribution scripts that set MTU will now be broken until
> they know that they need to work around this hardware limitation.  And
> why should they ever need to know that?
> 
> I think the proper thing to do is to automatically turn off
> NETIF_F_RXHASH when the MTU is too high for it to work.  The netdev
> still keeps track of whether it is 'wanted'.
> 
> Ben.
> 

Agreed. Principal of least surprise says the best thing to
do would be turn off features that are performance improvements to allow
user to do what they wanted (and turn the error into a warning).

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

end of thread, other threads:[~2012-05-22 21:29 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-05-22 18:19 Fw: [Bug 43277] New: net/e1000e set mtu larger than 1500 fails Stephen Hemminger
2012-05-22 18:25 ` Stephen Hemminger
2012-05-22 18:28   ` Allan, Bruce W
2012-05-22 18:39   ` Christer Ekholm
2012-05-22 18:59     ` Ben Hutchings
2012-05-22 21:29       ` Stephen Hemminger

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