From: Jeff Garzik <jeff@garzik•org>
To: Auke Kok <auke-jan.h.kok@intel•com>, davem@davemloft•net
Cc: netdev@vger•kernel.org, ossthema@de•ibm.com
Subject: Re: [PATCH] [NET] ethtool: Add LRO support
Date: Fri, 10 Aug 2007 04:42:44 -0400 [thread overview]
Message-ID: <46BC2504.9010400@garzik.org> (raw)
In-Reply-To: <20070809164117.9907.23351.stgit@localhost.localdomain>
Auke Kok wrote:
> Signed-off-by: Auke Kok <auke-jan.h.kok@intel•com>
> ---
>
> include/linux/ethtool.h | 8 +++++++
> include/linux/netdevice.h | 1 +
> net/core/ethtool.c | 53 +++++++++++++++++++++++++++++++++++++++++++++
> 3 files changed, 62 insertions(+), 0 deletions(-)
>
> diff --git a/include/linux/ethtool.h b/include/linux/ethtool.h
> index 23ccea8..a97248e 100644
> --- a/include/linux/ethtool.h
> +++ b/include/linux/ethtool.h
> @@ -272,6 +272,8 @@ u32 ethtool_op_get_tso(struct net_device *dev);
> int ethtool_op_set_tso(struct net_device *dev, u32 data);
> u32 ethtool_op_get_ufo(struct net_device *dev);
> int ethtool_op_set_ufo(struct net_device *dev, u32 data);
> +u32 ethtool_op_get_lro(struct net_device *dev);
> +int ethtool_op_set_lro(struct net_device *dev, u32 data);
I'm thinking we don't need to keep adding two function pointers for each
boolean choice.
I propose adding two operations:
get-flags: return 32-bit (even on 64-bit platforms) flags bitmap
set-flags: set 32-bit flags bitmap
The 32 bits shall be divided as follows:
bits 0-23: ETHTOOL_FLAG_xxx defined in linux/ethtool.h
bits 24-31: driver-specific boolean flags
The driver-specific flags are first enumerated by userland via an
ETHTOOL_GSTRINGS call, using new string set ETH_SS_FLAGS. The first
string returned names the first driver-private flag (bit 24). This also
indicates that driver-private bit 24 is a valid flag for this driver and
network interface.
The overall goal is to replace get-LRO/set-LRO operations with the
setting/clearing of ETH_FLAG_LRO, and as well, provide a more-scalable
ethtool interface.
I'll code this up, along with the associated generic helpers
(net/core/ethtool.c), if there are no objections.
Jeff
next prev parent reply other threads:[~2007-08-10 8:42 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-08-09 16:41 [PATCH] [NET] ethtool: Add LRO support Auke Kok
2007-08-09 22:00 ` David Miller
2007-08-10 7:47 ` Jan-Bernd Themann
2007-08-10 8:42 ` Jeff Garzik [this message]
2007-08-10 9:28 ` David Miller
2007-08-10 9:32 ` Jeff Garzik
2007-08-10 16:24 ` Kok, Auke
-- strict thread matches above, loose matches on Subject: below --
2007-07-31 20:21 Auke Kok
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=46BC2504.9010400@garzik.org \
--to=jeff@garzik$(echo .)org \
--cc=auke-jan.h.kok@intel$(echo .)com \
--cc=davem@davemloft$(echo .)net \
--cc=netdev@vger$(echo .)kernel.org \
--cc=ossthema@de$(echo .)ibm.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