arp: Random clean up and RCU conversion for ioctl(SIOCGARP).
Status from this message: This series was applied to netdev/net-next.git (main)
Get series with b4
b4 am [email protected]Versions newest first · linked by author and title
- v3 Latest7 patches 0 repliesApplied 7/7
- v26 patches 4 repliesSuperseded
- v16 patches 2 repliesSuperseded
Changes in v3 from the cover letter
Add Patch 6 to read dev->name safely under seqlock.
Patches in v3 All 7 applied
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/7 | arp: Move ATF_COM setting in arp_req_set().net/ | +6 | 0 replies | Applied |
| 2/7 | arp: Validate netmask earlier for SIOCDARP and SIOCSARP in arp_ioctl().net/ | +15 | 0 replies | Applied |
| 3/7 | arp: Factorise ip_route_output() call in arp_req_set() and arp_req_delete().net/ | +30 | 0 replies | Applied |
| 4/7 | arp: Remove a nest in arp_req_get().net/ | +18 | 0 replies | Applied |
| 5/7 | arp: Get dev after calling arp_req_(delete|set|get)().net/ | +50 | 0 replies | Applied |
| 6/7 | net: Protect dev->name by seqlock.include/ net/ | +24 | 0 replies | Applied |
| 7/7 | arp: Convert ioctl(SIOCGARP) to RCU.net/ | +18 | 0 replies | Applied |
Reviews trailers per patch
No Reviewed-by, Acked-by or Tested-by trailers for v3 yet.
Cover letter [PATCH v3 net-next 0/7] 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() and copy dev->name safely.
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() and netdev_copy_name() for SIOCGARP.
Changes:
v3:
Add Patch 6 to read dev->name safely under seqlock.
v2: https://lore.kernel.org/netdev/[email protected]/
Patch 5: s/!IS_ERR/IS_ERR/ in arp_req_delete().
v1: https://lore.kernel.org/netdev/[email protected]/
Kuniyuki Iwashima (7):
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)().
net: Protect dev->name by seqlock.
arp: Convert ioctl(SIOCGARP) to RCU.
include/linux/netdevice.h | 1 + net/core/dev.c | 27 ++++- net/ipv4/arp.c | 203 +++++++++++++++++++++++--------------- 3 files changed, 147 insertions(+), 84 deletions(-)
Signature · 1 line
2.30.2