netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Eric Dumazet <edumazet@google.com>
To: "David S . Miller" <davem@davemloft.net>,
	Jakub Kicinski <kuba@kernel.org>,
	 Paolo Abeni <pabeni@redhat.com>
Cc: netdev@vger.kernel.org, Simon Horman <horms@kernel.org>,
	 Roopa Prabhu <roopa@nvidia.com>,
	Kuniyuki Iwashima <kuniyu@amazon.com>,
	eric.dumazet@gmail.com,  Eric Dumazet <edumazet@google.com>
Subject: [PATCH net-next 0/3] net: prepare for removal of net->dev_index_head
Date: Sat,  7 Dec 2024 16:22:45 +0000	[thread overview]
Message-ID: <20241207162248.18536-1-edumazet@google.com> (raw)

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


             reply	other threads:[~2024-12-07 16:22 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-12-07 16:22 Eric Dumazet [this message]
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

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=20241207162248.18536-1-edumazet@google.com \
    --to=edumazet@google.com \
    --cc=davem@davemloft.net \
    --cc=eric.dumazet@gmail.com \
    --cc=horms@kernel.org \
    --cc=kuba@kernel.org \
    --cc=kuniyu@amazon.com \
    --cc=netdev@vger.kernel.org \
    --cc=pabeni@redhat.com \
    --cc=roopa@nvidia.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
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;
as well as URLs for NNTP newsgroup(s).