[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <20240422194755.4221-1-kuniyu@amazon.com>
Date: Mon, 22 Apr 2024 12:47:49 -0700
From: Kuniyuki Iwashima <kuniyu@...zon.com>
To: "David S. Miller" <davem@...emloft.net>, David Ahern <dsahern@...nel.org>,
Eric Dumazet <edumazet@...gle.com>, Jakub Kicinski <kuba@...nel.org>, "Paolo
Abeni" <pabeni@...hat.com>
CC: Kuniyuki Iwashima <kuniyu@...zon.com>, Kuniyuki Iwashima
<kuni1840@...il.com>, <netdev@...r.kernel.org>
Subject: [PATCH v1 net-next 0/6] arp: Random clean up and RCU conversion for ioctl(SIOCGARP).
arp_ioctl() holds rtnl_lock() regardless of cmd (SIOCDARP, SIOCSARP,
and SIOCGARP) to get net_device by __dev_get_by_name().
In the SIOCGARP path, arp_req_get() calls neigh_lookup(), which looks
up a neighbour entry under RCU.
This series cleans up ioctl() code a bit and extends the RCU section not
to take rtnl_lock() and instead use dev_get_by_name_rcu() for SIOCGARP.
Kuniyuki Iwashima (6):
arp: Move ATF_COM setting in arp_req_set().
arp: Validate netmask earlier for SIOCDARP and SIOCSARP in
arp_ioctl().
arp: Factorise ip_route_output() call in arp_req_set() and
arp_req_delete().
arp: Remove a nest in arp_req_get().
arp: Get dev after calling arp_req_(delete|set|get)().
arp: Convert ioctl(SIOCGARP) to RCU.
net/ipv4/arp.c | 203 ++++++++++++++++++++++++++++++-------------------
1 file changed, 123 insertions(+), 80 deletions(-)
--
2.30.2
Powered by blists - more mailing lists