]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
ipv4: fib: Convert fib_net_exit_batch() to ->exit_rtnl().
authorKuniyuki Iwashima <kuniyu@google.com>
Fri, 12 Jun 2026 06:32:08 +0000 (06:32 +0000)
committerJakub Kicinski <kuba@kernel.org>
Mon, 15 Jun 2026 18:49:28 +0000 (11:49 -0700)
commit759923cf03b062b5b8cdc770e2819a67ebe1cacd
treed70e3ba5c6fc2f63858d14d28018c468a52966e6
parent5a7fef12d931f27e09767f8b7a9bf0c1ee096abd
ipv4: fib: Convert fib_net_exit_batch() to ->exit_rtnl().

Currently, IPv4 routes are flushed in ->exit_batch() after
all devices are unregistered.

Unlike IPv6, IPv4 routes are not added from the fast path,
so we can flush routes before default_device_exit_batch().

Let's call ip_fib_net_exit() from ->exit_rtnl() to save
one RTNL locking dance.

ip_fib_net_exit() must use list_del_rcu() for fib_table
for the fast path on dying dev.

Signed-off-by: Kuniyuki Iwashima <kuniyu@google.com>
Reviewed-by: Ido Schimmel <idosch@nvidia.com>
Reviewed-by: Eric Dumazet <edumazet@google.com>
Link: https://patch.msgid.link/20260612063225.455191-6-kuniyu@google.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
net/ipv4/fib_frontend.c