netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jeff Garzik <jgarzik@pobox.com>
To: "David S. Miller" <davem@davemloft.net>
Cc: Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	Netdev <netdev@oss.sgi.com>
Subject: Re: [NET]: TSO requires SG, enforce this at device registry.
Date: Mon, 25 Oct 2004 01:50:41 -0400	[thread overview]
Message-ID: <417C9431.6030505@pobox.com> (raw)
In-Reply-To: <200410221715.i9MHFlIu021927@hera.kernel.org>

Linux Kernel Mailing List wrote:
> diff -Nru a/net/core/dev.c b/net/core/dev.c
> --- a/net/core/dev.c	2004-10-22 10:15:57 -07:00
> +++ b/net/core/dev.c	2004-10-22 10:15:57 -07:00
> @@ -2871,6 +2871,14 @@
>  		dev->features &= ~NETIF_F_SG;
>  	}
>  
> +	/* TSO requires that SG is present as well. */
> +	if ((dev->features & NETIF_F_TSO) &&
> +	    !(dev->features & NETIF_F_SG)) {
> +		printk("%s: Dropping NETIF_F_TSO since no SG feature.\n",
> +		       dev->name);
> +		dev->features &= ~NETIF_F_TSO;
> +	}


Although this patch is correct, I am pondering whether this fully covers 
the problems in the field.

There are currently two classes of problems I am seeing, that generate 
real-life bug reports:

1) Given current driver implementations of ethtool ioctls, sysadmin is 
free to create a combination of bits that are IMHO a bug.  One can argue 
that this is an extension of "root can shoot himself in the foot", so 
who knows.

2) Programmers writing drivers do not appear to be clear that SG is 
required to tx-csum/tso, and also, should not be present without one or 
both of those bits set.

	Jeff

       reply	other threads:[~2004-10-25  5:50 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <200410221715.i9MHFlIu021927@hera.kernel.org>
2004-10-25  5:50 ` Jeff Garzik [this message]
2004-10-25  5:57   ` [NET]: TSO requires SG, enforce this at device registry David S. Miller
2004-10-25  6:28     ` Jeff Garzik
2004-10-25 23:11       ` David S. Miller

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=417C9431.6030505@pobox.com \
    --to=jgarzik@pobox.com \
    --cc=davem@davemloft.net \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@oss.sgi.com \
    /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).