Skip to content

net: ethtool: fixes for HDS threshold

Jakub Kicinski netdev 2 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v2 Latest7 patches 4 repliesIn review 6 of 7 applied
  2. v16 patches 2 repliesSuperseded

Changes in v2 from the cover letter

- make sure we always manipulate cfg_pending under rtnl_lock
- split patch 2 into 2+3 for ease of review
v1: https://lore.kernel.org/[email protected]

Patches in v2 6 of 7 applied

#Subject and filesSizeRepliesApplied
1/7net: move HDS config from ethtool statedrivers/net/ethernet/broadcom/bnxt/bnxt.c drivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c drivers/net/netdevsim/ethtool.c +7 more+43 -240 replies
2/7net: ethtool: store netdev in a temp variable in ethnl_default_set_doit()net/ethtool/netlink.c+6 -30 repliesApplied
3/7net: provide pending ring configuration in net_deviceinclude/linux/netdevice.h net/core/dev.c net/ethtool/netlink.c +1 more+29 -80 repliesApplied
4/7eth: bnxt: apply hds_thrs settings correctlydrivers/net/ethernet/broadcom/bnxt/bnxt.c+1 -10 repliesApplied
5/7net: ethtool: populate the default HDS params in the coredrivers/net/ethernet/broadcom/bnxt/bnxt_ethtool.c drivers/net/netdevsim/ethtool.c net/ethtool/rings.c+4 -63 repliesApplied
6/7eth: bnxt: allocate enough buffer space to meet HDS thresholddrivers/net/ethernet/broadcom/bnxt/bnxt.c+4 -30 repliesApplied
7/7eth: bnxt: update header sizing defaultsdrivers/net/ethernet/broadcom/bnxt/bnxt.c+6 -10 repliesApplied

Reviews trailers per patch

None of the 7 patches has a Reviewed-by or Acked-by of their own; the series has one for all of them.

PatchMichael Chan
SeriesR-b
1/7
2/7
3/7
4/7
5/7
6/7
7/7

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v2 thread

Cover letter [PATCH net-next v2 0/7] net: ethtool: fixes for HDS threshold

Quick follow up on the HDS threshold work, since the merge window is upon us.

Fix the bnxt implementation to apply the settings right away, because we update the parameters _after_ configuring HW user needed to reconfig the device twice to get the settings to stick.

For this I took the liberty of moving the config to a separate struct. This follows my original thinking for the queue API. It should also fit more neatly into how many drivers which support safe config update operate. Drivers can allocate new objects using the "pending" struct.

netdevsim:

KTAP version 1
1..7
ok 1 hds.get_hds
ok 2 hds.get_hds_thresh
ok 3 hds.set_hds_disable
ok 4 hds.set_hds_enable
ok 5 hds.set_hds_thresh_zero
ok 6 hds.set_hds_thresh_max
ok 7 hds.set_hds_thresh_gt
# Totals: pass:7 fail:0 xfail:0 xpass:0 skip:0 error:0

bnxt:

KTAP version 1
1..7
ok 1 hds.get_hds
ok 2 hds.get_hds_thresh
ok 3 hds.set_hds_disable # SKIP disabling of HDS not supported by the device ok 4 hds.set_hds_enable
ok 5 hds.set_hds_thresh_zero
ok 6 hds.set_hds_thresh_max
ok 7 hds.set_hds_thresh_gt
# Totals: pass:6 fail:0 xfail:0 xpass:0 skip:1 error:0

v2:
- make sure we always manipulate cfg_pending under rtnl_lock
- split patch 2 into 2+3 for ease of review
v1: https://lore.kernel.org/[email protected]

Jakub Kicinski (7):
net: move HDS config from ethtool state
net: ethtool: store netdev in a temp variable in
ethnl_default_set_doit()
net: provide pending ring configuration in net_device
eth: bnxt: apply hds_thrs settings correctly
net: ethtool: populate the default HDS params in the core
eth: bnxt: allocate enough buffer space to meet HDS threshold
eth: bnxt: update header sizing defaults

 include/linux/ethtool.h                       |  4 ---
 include/linux/netdevice.h                     |  9 ++++++
 include/net/netdev_queues.h                   | 10 +++++++
 drivers/net/ethernet/broadcom/bnxt/bnxt.c     | 16 ++++++----
 .../net/ethernet/broadcom/bnxt/bnxt_ethtool.c |  4 +--
 drivers/net/netdevsim/ethtool.c               |  6 +---
 drivers/net/netdevsim/netdev.c                | 10 +++----
 net/core/dev.c                                | 12 ++++++--
 net/core/devmem.c                             |  4 +--
 net/ethtool/netlink.c                         | 30 +++++++++++++++----
 net/ethtool/rings.c                           | 16 ++++++----
 11 files changed, 84 insertions(+), 37 deletions(-)
Signature · 1 line
2.48.1