netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH net-next 00/11] eth: bnxt: use the new RSS API
@ 2024-07-02 23:47 Jakub Kicinski
  2024-07-02 23:47 ` [PATCH net-next 01/11] net: ethtool: let drivers remove lost RSS contexts Jakub Kicinski
                   ` (11 more replies)
  0 siblings, 12 replies; 31+ messages in thread
From: Jakub Kicinski @ 2024-07-02 23:47 UTC (permalink / raw)
  To: davem; +Cc: netdev, edumazet, pabeni, ecree.xilinx, michael.chan,
	Jakub Kicinski

Convert bnxt from using the set_rxfh API to separate create/modify/remove
callbacks.

Two small extensions to the core APIs are necessary:
 - the ability to discard contexts if for some catastrophic reasons
   device can no longer provide them;
 - the ability to reserve space in the context for RSS table growth.

The driver is adjusted to store indirection tables on u32 to make
it easier to use core structs directly.

With that out of the way the conversion is fairly straightforward.

Jakub Kicinski (11):
  net: ethtool: let drivers remove lost RSS contexts
  net: ethtool: let drivers declare max size of RSS indir table and key
  eth: bnxt: allow deleting RSS contexts when the device is down
  eth: bnxt: move from .set_rxfh to .create_rxfh_context and friends
  eth: bnxt: remove rss_ctx_bmap
  eth: bnxt: depend on core cleaning up RSS contexts
  eth: bnxt: use context priv for struct bnxt_rss_ctx
  eth: bnxt: use the RSS context XArray instead of the local list
  eth: bnxt: bump the entry size in indir tables to u32
  eth: bnxt: use the indir table from ethtool context
  eth: bnxt: pad out the correct indirection table

 drivers/net/ethernet/broadcom/bnxt/bnxt.c     | 115 +++++--------
 drivers/net/ethernet/broadcom/bnxt/bnxt.h     |  14 +-
 .../net/ethernet/broadcom/bnxt/bnxt_ethtool.c | 159 ++++++++++--------
 include/linux/ethtool.h                       |  25 +--
 net/ethtool/ioctl.c                           |  46 +++--
 net/ethtool/rss.c                             |  14 ++
 6 files changed, 201 insertions(+), 172 deletions(-)

-- 
2.45.2


^ permalink raw reply	[flat|nested] 31+ messages in thread
* [PATCH net-next 00/11] eth: bnxt: use the new RSS API
@ 2024-07-11 22:07 Jakub Kicinski
  2024-07-11 22:07 ` [PATCH net-next 04/11] eth: bnxt: move from .set_rxfh to .create_rxfh_context and friends Jakub Kicinski
  0 siblings, 1 reply; 31+ messages in thread
From: Jakub Kicinski @ 2024-07-11 22:07 UTC (permalink / raw)
  To: davem
  Cc: netdev, edumazet, pabeni, ecree.xilinx, michael.chan, horms,
	pavan.chebbi, przemyslaw.kitszel, Jakub Kicinski

Convert bnxt from using the set_rxfh API to separate create/modify/remove
callbacks.

Two small extensions to the core APIs are necessary:
 - the ability to discard contexts if for some catastrophic reasons
   device can no longer provide them;
 - the ability to reserve space in the context for RSS table growth.

The driver is adjusted to store indirection tables on u32 to make
it easier to use core structs directly.

With that out of the way the conversion is fairly straightforward.

Since the opposition to discarding contexts was relatively mild
and its what bnxt does already, I'm sticking to that. We may very
well need to revisit that at a later time.

v2:
 - move "lost context" helper to common.c to avoid build problems
   when ethtool-nl isn't enabled
 - add a note about the counter proposal in the commit message
 - move key_off to the end, under the private label (hiding from kdoc)
 - remove bnxt_get_max_rss_ctx_ring()
 - switch from sizeof(u32) to sizeof(*indir_tbl)
 - add a sentence to the commit msg
 - store a pointer to struct ethtool_rxfh_param instead of
   adding the ethtool_rxfh_priv_context() helper
v1: https://lore.kernel.org/all/20240702234757.4188344-1-kuba@kernel.org/

Jakub Kicinski (11):
  net: ethtool: let drivers remove lost RSS contexts
  net: ethtool: let drivers declare max size of RSS indir table and key
  eth: bnxt: allow deleting RSS contexts when the device is down
  eth: bnxt: move from .set_rxfh to .create_rxfh_context and friends
  eth: bnxt: remove rss_ctx_bmap
  eth: bnxt: depend on core cleaning up RSS contexts
  eth: bnxt: use context priv for struct bnxt_rss_ctx
  eth: bnxt: use the RSS context XArray instead of the local list
  eth: bnxt: pad out the correct indirection table
  eth: bnxt: bump the entry size in indir tables to u32
  eth: bnxt: use the indir table from ethtool context

 drivers/net/ethernet/broadcom/bnxt/bnxt.c     | 126 +++++--------
 drivers/net/ethernet/broadcom/bnxt/bnxt.h     |  17 +-
 .../net/ethernet/broadcom/bnxt/bnxt_ethtool.c | 165 ++++++++++--------
 include/linux/ethtool.h                       |  20 +--
 net/ethtool/common.c                          |  14 ++
 net/ethtool/ioctl.c                           |  46 +++--
 6 files changed, 194 insertions(+), 194 deletions(-)

-- 
2.45.2


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

end of thread, other threads:[~2024-07-11 22:07 UTC | newest]

Thread overview: 31+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-07-02 23:47 [PATCH net-next 00/11] eth: bnxt: use the new RSS API Jakub Kicinski
2024-07-02 23:47 ` [PATCH net-next 01/11] net: ethtool: let drivers remove lost RSS contexts Jakub Kicinski
2024-07-03 11:08   ` Edward Cree
2024-07-03 13:43     ` Jakub Kicinski
2024-07-03 14:15       ` Edward Cree
2024-07-02 23:47 ` [PATCH net-next 02/11] net: ethtool: let driver declare max size of RSS indir table and key Jakub Kicinski
2024-07-04  7:34   ` Simon Horman
2024-07-02 23:47 ` [PATCH net-next 02/11] net: ethtool: let drivers " Jakub Kicinski
2024-07-03 11:16   ` Edward Cree
2024-07-02 23:47 ` [PATCH net-next 03/11] eth: bnxt: allow deleting RSS contexts when the device is down Jakub Kicinski
2024-07-02 23:47 ` [PATCH net-next 04/11] eth: bnxt: move from .set_rxfh to .create_rxfh_context and friends Jakub Kicinski
2024-07-03 12:06   ` Edward Cree
2024-07-03 12:49     ` Pavan Chebbi
2024-07-03 13:46       ` Jakub Kicinski
2024-07-04  6:19   ` kernel test robot
2024-07-05  0:34   ` kernel test robot
2024-07-02 23:47 ` [PATCH net-next 05/11] eth: bnxt: remove rss_ctx_bmap Jakub Kicinski
2024-07-02 23:47 ` [PATCH net-next 06/11] eth: bnxt: depend on core cleaning up RSS contexts Jakub Kicinski
2024-07-02 23:47 ` [PATCH net-next 07/11] eth: bnxt: use context priv for struct bnxt_rss_ctx Jakub Kicinski
2024-07-02 23:47 ` [PATCH net-next 08/11] eth: bnxt: use the RSS context XArray instead of the local list Jakub Kicinski
2024-07-02 23:47 ` [PATCH net-next 09/11] eth: bnxt: bump the entry size in indir tables to u32 Jakub Kicinski
2024-07-03 10:51   ` Przemek Kitszel
2024-07-03 13:49     ` Jakub Kicinski
2024-07-03 14:02       ` Przemek Kitszel
2024-07-03 16:02         ` Jakub Kicinski
2024-07-02 23:47 ` [PATCH net-next 10/11] eth: bnxt: use the indir table from ethtool context Jakub Kicinski
2024-07-03 11:08   ` Przemek Kitszel
2024-07-03 11:39   ` Edward Cree
2024-07-03 13:51     ` Jakub Kicinski
2024-07-02 23:47 ` [PATCH net-next 11/11] eth: bnxt: pad out the correct indirection table Jakub Kicinski
  -- strict thread matches above, loose matches on Subject: below --
2024-07-11 22:07 [PATCH net-next 00/11] eth: bnxt: use the new RSS API Jakub Kicinski
2024-07-11 22:07 ` [PATCH net-next 04/11] eth: bnxt: move from .set_rxfh to .create_rxfh_context and friends Jakub Kicinski

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