netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Pull request: Fixes for new ethtool RSS commands
@ 2014-06-02  0:57 Ben Hutchings
  2014-06-02  1:01 ` [PATCH net-next 1/8] ethtool: Return immediately on error in ethtool_copy_validate_indir() Ben Hutchings
                   ` (9 more replies)
  0 siblings, 10 replies; 15+ messages in thread
From: Ben Hutchings @ 2014-06-02  0:57 UTC (permalink / raw)
  To: David Miller; +Cc: netdev

[-- Attachment #1: Type: text/plain, Size: 2777 bytes --]

The following changes since commit eb02a272c97b6e25d8e5fcf1ea93923e6f155595:

  driver/net/ethernet/ec_bhf.c: fix sparse warnings (2014-05-14 16:09:33 -0400)

are available in the git repository at:

  git://git.kernel.org/pub/scm/linux/kernel/git/bwh/net-next.git ethtool-rssh-fixes

for you to fetch changes up to dfe805c14a2018c5a58cfa3921f1897032740501:

  ethtool: Check that reserved fields of struct ethtool_rxfh are 0 (2014-05-19 01:30:30 +0100)

This addresses several problems I previously identified with the new
ETHTOOL_{G,S}RSSH commands:

1. Missing validation of reserved parameters
2. Vague documentation
3. Use of unnamed magic number
4. No consolidation with existing driver operations

I don't currently have access to suitable network hardware, but have
tested these changes with a dummy driver that can support various
combinations of operations and sizes, together with (a) Debian's ethtool
3.13 (b) ethtool 3.14 with the submitted patch to use ETHTOOL_{G,S}RSSH
and minor adjustment for fixes 1 and 3.

Ben.

----------------------------------------------------------------
Ben Hutchings (8):
      ethtool: Return immediately on error in ethtool_copy_validate_indir()
      ethtool: Name the 'no change' value for setting RSS hash key but not indir table
      ethtool: Improve explanation of the two arrays following struct ethtool_rxfh
      ethtool: Expand documentation of ethtool_ops::{get,set}_rxfh()
      ethtool: Disallow ETHTOOL_SRSSH with both indir table and hash key unchanged
      ethtool, be2net: constify array pointer parameters to ethtool_ops::set_rxfh
      ethtool: Replace ethtool_ops::{get,set}_rxfh_indir() with {get,set}_rxfh()
      ethtool: Check that reserved fields of struct ethtool_rxfh are 0

 .../net/ethernet/broadcom/bnx2x/bnx2x_ethtool.c    |  15 +--
 drivers/net/ethernet/broadcom/tg3.c                |   8 +-
 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c    |   8 +-
 drivers/net/ethernet/emulex/benet/be_cmds.c        |   2 +-
 drivers/net/ethernet/emulex/benet/be_cmds.h        |   2 +-
 drivers/net/ethernet/emulex/benet/be_ethtool.c     |   3 +-
 drivers/net/ethernet/intel/i40evf/i40evf_ethtool.c |  15 +--
 drivers/net/ethernet/intel/igb/igb_ethtool.c       |   9 +-
 drivers/net/ethernet/mellanox/mlx4/en_ethtool.c    |  10 +-
 drivers/net/ethernet/sfc/ethtool.c                 |  10 +-
 include/linux/ethtool.h                            |  24 ++---
 include/uapi/linux/ethtool.h                       |  25 ++---
 net/core/ethtool.c                                 | 110 +++++++++------------
 13 files changed, 116 insertions(+), 125 deletions(-)

-- 
Ben Hutchings
Any smoothly functioning technology is indistinguishable from a rigged demo.

[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 828 bytes --]

^ permalink raw reply	[flat|nested] 15+ messages in thread
* Pull request: Fixes for new ethtool RSS commands
@ 2014-06-03  1:49 Ben Hutchings
  2014-06-03  1:51 ` [PATCH net-next 6/8] ethtool, be2net: constify array pointer parameters to ethtool_ops::set_rxfh Ben Hutchings
  0 siblings, 1 reply; 15+ messages in thread
From: Ben Hutchings @ 2014-06-03  1:49 UTC (permalink / raw)
  To: David Miller; +Cc: netdev, Venkat Duvvuru

[-- Attachment #1: Type: text/plain, Size: 2876 bytes --]

The following changes since commit eb02a272c97b6e25d8e5fcf1ea93923e6f155595:

  driver/net/ethernet/ec_bhf.c: fix sparse warnings (2014-05-14 16:09:33 -0400)

are available in the git repository at:

  git://git.kernel.org/pub/scm/linux/kernel/git/bwh/net-next.git ethtool-rssh-fixes

for you to fetch changes up to f062a3844845d267e3716cbc188ad502a15898b7:

  ethtool: Check that reserved fields of struct ethtool_rxfh are 0 (2014-06-03 02:43:16 +0100)

This addresses several problems I previously identified with the new
ETHTOOL_{G,S}RSSH commands:

1. Missing validation of reserved parameters
2. Vague documentation
3. Use of unnamed magic number
4. No consolidation with existing driver operations

I don't currently have access to suitable network hardware, but have
tested these changes with a dummy driver that can support various
combinations of operations and sizes, together with (a) Debian's ethtool
3.13 (b) ethtool 3.14 with the submitted patch to use ETHTOOL_{G,S}RSSH
and minor adjustment for fixes 1 and 3.

v2: Update RSS operations in vmxnet3 too

Ben.

----------------------------------------------------------------
Ben Hutchings (8):
      ethtool: Return immediately on error in ethtool_copy_validate_indir()
      ethtool: Name the 'no change' value for setting RSS hash key but not indir table
      ethtool: Improve explanation of the two arrays following struct ethtool_rxfh
      ethtool: Expand documentation of ethtool_ops::{get,set}_rxfh()
      ethtool: Disallow ETHTOOL_SRSSH with both indir table and hash key unchanged
      ethtool, be2net: constify array pointer parameters to ethtool_ops::set_rxfh
      ethtool: Replace ethtool_ops::{get,set}_rxfh_indir() with {get,set}_rxfh()
      ethtool: Check that reserved fields of struct ethtool_rxfh are 0

 .../net/ethernet/broadcom/bnx2x/bnx2x_ethtool.c    |  15 +--
 drivers/net/ethernet/broadcom/tg3.c                |   8 +-
 drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c    |   8 +-
 drivers/net/ethernet/emulex/benet/be_cmds.c        |   2 +-
 drivers/net/ethernet/emulex/benet/be_cmds.h        |   2 +-
 drivers/net/ethernet/emulex/benet/be_ethtool.c     |   3 +-
 drivers/net/ethernet/intel/i40evf/i40evf_ethtool.c |  15 +--
 drivers/net/ethernet/intel/igb/igb_ethtool.c       |   9 +-
 drivers/net/ethernet/mellanox/mlx4/en_ethtool.c    |  10 +-
 drivers/net/ethernet/sfc/ethtool.c                 |  10 +-
 drivers/net/vmxnet3/vmxnet3_ethtool.c              |   8 +-
 include/linux/ethtool.h                            |  24 ++---
 include/uapi/linux/ethtool.h                       |  25 ++---
 net/core/ethtool.c                                 | 110 +++++++++------------
 14 files changed, 120 insertions(+), 129 deletions(-)

-- 
Ben Hutchings
If more than one person is responsible for a bug, no one is at fault.

[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 828 bytes --]

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

end of thread, other threads:[~2014-06-03  1:51 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-06-02  0:57 Pull request: Fixes for new ethtool RSS commands Ben Hutchings
2014-06-02  1:01 ` [PATCH net-next 1/8] ethtool: Return immediately on error in ethtool_copy_validate_indir() Ben Hutchings
2014-06-02  1:01 ` [PATCH net-next 2/8] ethtool: Name the 'no change' value for setting RSS hash key but not indir table Ben Hutchings
2014-06-02  1:01 ` [PATCH net-next 3/8] ethtool: Improve explanation of the two arrays following struct ethtool_rxfh Ben Hutchings
2014-06-02  1:02 ` [PATCH net-next 4/8] ethtool: Expand documentation of ethtool_ops::{get,set}_rxfh() Ben Hutchings
2014-06-02  1:02 ` [PATCH net-next 5/8] ethtool: Disallow ETHTOOL_SRSSH with both indir table and hash key unchanged Ben Hutchings
2014-06-02  1:02 ` [PATCH net-next 6/8] ethtool, be2net: constify array pointer parameters to ethtool_ops::set_rxfh Ben Hutchings
2014-06-02  1:03 ` [PATCH net-next 7/8] ethtool: Replace ethtool_ops::{get,set}_rxfh_indir() with {get,set}_rxfh() Ben Hutchings
2014-06-02  3:09   ` Jeff Kirsher
2014-06-02  1:04 ` [PATCH net-next 8/8] ethtool: Check that reserved fields of struct ethtool_rxfh are 0 Ben Hutchings
2014-06-02  1:11 ` Pull request: Fixes for new ethtool RSS commands Ben Hutchings
2014-06-03  0:13 ` David Miller
2014-06-03  0:23   ` David Miller
2014-06-03  1:42     ` Ben Hutchings
2014-06-03  1:49 Ben Hutchings
2014-06-03  1:51 ` [PATCH net-next 6/8] ethtool, be2net: constify array pointer parameters to ethtool_ops::set_rxfh Ben Hutchings

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