netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH net-next 0/3] net: prepare for removal of net->dev_index_head
@ 2024-12-07 16:22 Eric Dumazet
  2024-12-07 16:22 ` [PATCH net-next 1/3] rtnetlink: add ndo_fdb_dump_context Eric Dumazet
                   ` (2 more replies)
  0 siblings, 3 replies; 11+ messages in thread
From: Eric Dumazet @ 2024-12-07 16:22 UTC (permalink / raw)
  To: David S . Miller, Jakub Kicinski, Paolo Abeni
  Cc: netdev, Simon Horman, Roopa Prabhu, Kuniyuki Iwashima,
	eric.dumazet, Eric Dumazet

This series changes rtnl_fdb_dump, last iterator using net->dev_index_head[]

First patch creates ndo_fdb_dump_context structure, to no longer
assume specific layout for the arguments.

Second patch adopts for_each_netdev_dump() in rtnl_fdb_dump(),
while changing two first fields of ndo_fdb_dump_context.

Third patch removes the padding, thus changing the location
of ctx->fdb_idx now that all users agree on how to retrive it.

After this series, the only users of net->dev_index_head
are __dev_get_by_index() and dev_get_by_index_rcu().

We have to evaluate if switching them to dev_by_index xarray
would be sensible.

Eric Dumazet (3):
  rtnetlink: add ndo_fdb_dump_context
  rtnetlink: switch rtnl_fdb_dump() to for_each_netdev_dump()
  rtnetlink: remove pad field in ndo_fdb_dump_context

 .../ethernet/freescale/dpaa2/dpaa2-switch.c   |   3 +-
 drivers/net/ethernet/mscc/ocelot_net.c        |   3 +-
 drivers/net/vxlan/vxlan_core.c                |   5 +-
 include/linux/rtnetlink.h                     |   6 +
 net/bridge/br_fdb.c                           |   3 +-
 net/core/rtnetlink.c                          | 106 +++++++-----------
 net/dsa/user.c                                |   3 +-
 7 files changed, 59 insertions(+), 70 deletions(-)

-- 
2.47.0.338.g60cca15819-goog


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

end of thread, other threads:[~2024-12-09  9:54 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-12-07 16:22 [PATCH net-next 0/3] net: prepare for removal of net->dev_index_head Eric Dumazet
2024-12-07 16:22 ` [PATCH net-next 1/3] rtnetlink: add ndo_fdb_dump_context Eric Dumazet
2024-12-08 17:57   ` Ido Schimmel
2024-12-09  9:53     ` Eric Dumazet
2024-12-09  5:48   ` Kuniyuki Iwashima
2024-12-07 16:22 ` [PATCH net-next 2/3] rtnetlink: switch rtnl_fdb_dump() to for_each_netdev_dump() Eric Dumazet
2024-12-08 18:15   ` Ido Schimmel
2024-12-09  5:52   ` Kuniyuki Iwashima
2024-12-07 16:22 ` [PATCH net-next 3/3] rtnetlink: remove pad field in ndo_fdb_dump_context Eric Dumazet
2024-12-08 18:20   ` Ido Schimmel
2024-12-09  5:54   ` Kuniyuki Iwashima

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