public inbox for netdev@vger.kernel.org
 help / color / mirror / Atom feed
From: Ben Hutchings <bhutchings@solarflare.com>
To: "Michał Mirosław" <mirq-linux@rere.qmqm.pl>
Cc: netdev@vger.kernel.org, "David S. Miller" <davem@davemloft.net>,
	Stephen Hemminger <shemminger@vyatta.com>
Subject: Re: [RFT PATCH 3/9] net: ethtool: break association of ETH_FLAG_* with NETIF_F_*
Date: Mon, 20 Jun 2011 21:11:21 +0100	[thread overview]
Message-ID: <1308600681.2701.159.camel@bwh-desktop> (raw)
In-Reply-To: <51d2fd4cf6855c2285ca9bcd8d267abedcbc599c.1308596963.git.mirq-linux@rere.qmqm.pl>

On Mon, 2011-06-20 at 21:14 +0200, Michał Mirosław wrote:
> This is the only place where NETIF_F_* feature flags are exposed
> to userspace.

Except sysfs.

> After this patch feature flags may be changed/reordered freely.
[...]

Really, what do you think was the point of exposing features through
sysfs if they are going to be changed?

Oh, but they have been changed already:

v2.5.70
net-sysfs added

v2.6.15
+#define NETIF_F_UFO             8192    /* Can offload UDP Large Send*/

v2.6.18
-#define NETIF_F_TSO            2048    /* Can offload TCP/IP segmentation */
-#define NETIF_F_UFO             8192    /* Can offload UDP Large Send*/
+#define NETIF_F_GSO            2048    /* Enable software GSO. */
+#define NETIF_F_GSO_SHIFT      16
+#define NETIF_F_TSO            (SKB_GSO_TCPV4 << NETIF_F_GSO_SHIFT)
+#define NETIF_F_UFO            (SKB_GSO_UDP << NETIF_F_GSO_SHIFT)
+#define NETIF_F_GSO_ROBUST     (SKB_GSO_DODGY << NETIF_F_GSO_SHIFT)
+#define NETIF_F_TSO_ECN                (SKB_GSO_TCP_ECN << NETIF_F_GSO_SHIFT)
+#define NETIF_F_TSO6           (SKB_GSO_TCPV6 << NETIF_F_GSO_SHIFT)

v2.6.23
+#define NETIF_F_IPV6_CSUM      16      /* Can checksum TCP/UDP over IPV6 */
+#define NETIF_F_MULTI_QUEUE    16384   /* Has multiple TX/RX queues */

v2.6.24
+#define NETIF_F_NETNS_LOCAL    8192    /* Does not change network namespaces */

v2.6.27
-#define NETIF_F_MULTI_QUEUE    16384   /* Has multiple TX/RX queues */

v2.6.29
+#define NETIF_F_GRO            16384   /* Generic receive offload */

(I've omitted changes that use previously unused bits.)

If we're going to keep changing features (maybe even more often) then we
have to do something about this sysfs attribute.  Maybe get rid of it
(as it seems not to be widely used, thankfully).  Maybe fix it to use
the same feature values as today, but no new features.  But certainly
don't pretend that feature flags are not exposed.

Ben.

-- 
Ben Hutchings, Senior Software 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.


  reply	other threads:[~2011-06-20 20:11 UTC|newest]

Thread overview: 28+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-06-20 19:14 [RFT PATCH 0/9] Cleanup and extension of netdev features Michał Mirosław
2011-06-20 19:14 ` [RFT PATCH 2/9] net: remove legacy ethtool ops Michał Mirosław
2011-06-20 19:14 ` [RFT PATCH 3/9] net: ethtool: break association of ETH_FLAG_* with NETIF_F_* Michał Mirosław
2011-06-20 20:11   ` Ben Hutchings [this message]
2011-06-20 20:27     ` David Miller
2011-06-20 20:51     ` Stephen Hemminger
2011-06-20 20:52       ` David Miller
2011-06-20 21:30         ` Ben Hutchings
2011-06-20 19:14 ` [RFT PATCH 5/9] net: Define enum for net device features Michał Mirosław
2011-06-20 19:14 ` [RFT PATCH 4/9] net: introduce and use netdev_features_t for device features sets Michał Mirosław
2011-06-20 21:01   ` Ben Hutchings
2011-06-20 19:14 ` [RFT PATCH 9/9] net: move NOCACHE_COPY checks to netdev_fix_features() Michał Mirosław
2011-06-20 19:14 ` [RFT PATCH 7/9] ethtool: prepare for larger netdev_features_t type Michał Mirosław
2011-06-20 21:16   ` Ben Hutchings
2011-06-23 17:50     ` Mahesh Bandewar
2011-06-23 18:03       ` Ben Hutchings
2011-06-23 18:21         ` Mahesh Bandewar
2011-06-23 18:55           ` Ben Hutchings
2011-06-23 20:38             ` Mahesh Bandewar
2011-06-20 19:14 ` [RFT PATCH 8/9] net: extend netdev_features_t to 64 bits Michał Mirosław
2011-06-20 19:14 ` [RFT PATCH 6/9] net: ethtool: use C99 array initialization for feature-names table Michał Mirosław
2011-06-20 19:35 ` [RFT PATCH 0/9] Cleanup and extension of netdev features David Miller
2011-06-20 19:47   ` Michał Mirosław
2011-06-20 19:55     ` [IGNORE PATCH 1/9] Intel net drivers: convert to ndo_fix_features Michał Mirosław
2011-06-21 21:43 ` [RFT PATCH 0/9] Cleanup and extension of netdev features Ben Greear
2011-06-21 21:52   ` Ben Hutchings
2011-06-21 23:27   ` Jeff Kirsher
2011-06-23 17:42 ` Mahesh Bandewar

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=1308600681.2701.159.camel@bwh-desktop \
    --to=bhutchings@solarflare.com \
    --cc=davem@davemloft.net \
    --cc=mirq-linux@rere.qmqm.pl \
    --cc=netdev@vger.kernel.org \
    --cc=shemminger@vyatta.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