ip: Batch flushing uncached routes for dying netns.
Get series with b4
b4 am [email protected]Versions newest first
- v1 Latest5 patches 2 repliesIn review
Patches in v1 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/5 | net: Remove net->is_dying.include/ net/ | +1 | 0 replies | |
| 2/5 | net: Add ->pre_exit_batch() to struct pernet_operations.include/ net/ | +4 | 0 replies | |
| 3/5 | net: Track state in ops_undo_list().include/ net/ | +16 | 0 replies | |
| 4/5 | ipv4: Batch rt_flush_dev() for dying netns.net/ net/ | +29 | 2 replies | |
| 5/5 | ipv6: Batch rt6_uncached_list_flush_dev() for dying netns.net/ | +39 | 0 replies |
Reviews trailers per patch
No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.
Cover letter [PATCH v1 net-next 0/5] ip: Batch flushing uncached routes for dying netns.
Chris J Arges reported high RTNL contention during cleanup_net() caused by rt_flush_dev() and rt6_uncached_list_flush_dev() iterating over the global per-cpu uncached route lists for every netdev in dying netns [0].
This series resolves the issue by introducing a new ->pre_exit_batch() hook in struct pernet_operations and batching the uncached route cleanup once per cleanup_net() without holding RTNL.
[0]: https://lore.kernel.org/netdev/20260917-hash-bucket-route-lists-v3-0-30493a37b6eb@cloudflare.com/
Kuniyuki Iwashima (5):
net: Remove net->is_dying.
net: Add ->pre_exit_batch() to struct pernet_operations.
net: Track state in ops_undo_list().
ipv4: Batch rt_flush_dev() for dying netns.
ipv6: Batch rt6_uncached_list_flush_dev() for dying netns.
include/net/net_namespace.h | 11 +++++++- net/core/net_namespace.c | 13 +++++++-- net/ipv4/fib_frontend.c | 6 +++++ net/ipv4/route.c | 28 +++++++++++++++---- net/ipv6/route.c | 54 ++++++++++++++++++++++++++----------- 5 files changed, 89 insertions(+), 23 deletions(-)
Signature · 1 line
2.56.0.rc1.315.gc6ed9934b7-goog