[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <20250716221221.442239-1-kuniyu@google.com>
Date: Wed, 16 Jul 2025 22:08:05 +0000
From: Kuniyuki Iwashima <kuniyu@...gle.com>
To: "David S. Miller" <davem@...emloft.net>, Eric Dumazet <edumazet@...gle.com>,
Jakub Kicinski <kuba@...nel.org>, Paolo Abeni <pabeni@...hat.com>, David Ahern <dsahern@...nel.org>
Cc: Simon Horman <horms@...nel.org>, Kuniyuki Iwashima <kuniyu@...gle.com>,
Kuniyuki Iwashima <kuni1840@...il.com>, netdev@...r.kernel.org
Subject: [PATCH v3 net-next 00/15] neighbour: Convert RTM_GETNEIGH to RCU and
make pneigh RTNL-free.
This is kind of v3 of the series below [0] but without NEIGHTBL patches.
Patch 1 ~ 4 and 9 come from the series to convert RTM_GETNEIGH to RCU.
Other patches clean up pneigh_lookup() and convert the pneigh code to
RCU + private mutex so that we can easily remove RTNL from RTM_NEWNEIGH
in the later series.
[0]: https://lore.kernel.org/netdev/20250418012727.57033-1-kuniyu@amazon.com/
Changes:
v3:
* Patch 1:
* Return ERR_PTR() direclty instead of goto in neigh_valid_get_req().
* Patch 2:
* Use NL_SET_ERR_ATTR_MISS() for NDA_DST
* Patch 3:
* Rename err label to err_free_skb
* Patch 8:
* Cache pn->protocol in pneigh_fill_info()
* Patch 9:
* Rename err label to err_unlock
v2: https://lore.kernel.org/netdev/20250712203515.4099110-1-kuniyu@google.com/
* Add patch 6 to silence Sparse __rcu warning
v1: https://lore.kernel.org/netdev/20250711191007.3591938-1-kuniyu@google.com/
Kuniyuki Iwashima (15):
neighbour: Make neigh_valid_get_req() return ndmsg.
neighbour: Move two validations from neigh_get() to
neigh_valid_get_req().
neighbour: Allocate skb in neigh_get().
neighbour: Move neigh_find_table() to neigh_get().
neighbour: Split pneigh_lookup().
neighbour: Annotate neigh_table.phash_buckets and pneigh_entry.next
with __rcu.
neighbour: Free pneigh_entry after RCU grace period.
neighbour: Annotate access to struct pneigh_entry.{flags,protocol}.
neighbour: Convert RTM_GETNEIGH to RCU.
neighbour: Drop read_lock_bh(&tbl->lock) in pneigh_dump_table().
neighbour: Use rcu_dereference() in pneigh_get_{first,next}().
neighbour: Remove __pneigh_lookup().
neighbour: Drop read_lock_bh(&tbl->lock) in pneigh_lookup().
neighbour: Protect tbl->phash_buckets[] with a dedicated mutex.
neighbour: Update pneigh_entry in pneigh_create().
include/net/neighbour.h | 17 +-
net/core/neighbour.c | 384 ++++++++++++++++++++--------------------
net/ipv4/arp.c | 6 +-
net/ipv6/ip6_output.c | 2 +-
net/ipv6/ndisc.c | 8 +-
5 files changed, 207 insertions(+), 210 deletions(-)
--
2.50.0.727.gbf7dc18ff4-goog
Powered by blists - more mailing lists