mbox series

[net-next,0/4] ipv4: preliminary work for per-netns RTNL

Message ID 20241004134720.579244-1-edumazet@google.com (mailing list archive)
Headers show
Series ipv4: preliminary work for per-netns RTNL | expand

Message

Eric Dumazet Oct. 4, 2024, 1:47 p.m. UTC
Inspired by 9b8ca04854fd ("ipv4: avoid quadratic behavior in
FIB insertion of common address") and per-netns RTNL conversion
started by Kuniyuki this week.

ip_fib_check_default() can use RCU instead of a shared spinlock.

fib_info_lock can be removed, RTNL is already used.

fib_info_devhash[] can be removed in favor of a single
pointer in net_device.

Eric Dumazet (4):
  ipv4: remove fib_devindex_hashfn()
  ipv4: use rcu in ip_fib_check_default()
  ipv4: remove fib_info_lock
  ipv4: remove fib_info_devhash[]

 .../networking/net_cachelines/net_device.rst  |  1 +
 include/linux/netdevice.h                     |  2 +
 net/ipv4/fib_semantics.c                      | 77 +++++++------------
 3 files changed, 31 insertions(+), 49 deletions(-)

Comments

David Ahern Oct. 4, 2024, 2:35 p.m. UTC | #1
On 10/4/24 7:47 AM, Eric Dumazet wrote:
> Inspired by 9b8ca04854fd ("ipv4: avoid quadratic behavior in
> FIB insertion of common address") and per-netns RTNL conversion
> started by Kuniyuki this week.
> 
> ip_fib_check_default() can use RCU instead of a shared spinlock.
> 
> fib_info_lock can be removed, RTNL is already used.
> 
> fib_info_devhash[] can be removed in favor of a single
> pointer in net_device.
> 
> Eric Dumazet (4):
>   ipv4: remove fib_devindex_hashfn()
>   ipv4: use rcu in ip_fib_check_default()
>   ipv4: remove fib_info_lock
>   ipv4: remove fib_info_devhash[]
> 
>  .../networking/net_cachelines/net_device.rst  |  1 +
>  include/linux/netdevice.h                     |  2 +
>  net/ipv4/fib_semantics.c                      | 77 +++++++------------
>  3 files changed, 31 insertions(+), 49 deletions(-)
> 


For the set:
Reviewed-by: David Ahern <dsahern@kernel.org>
patchwork-bot+netdevbpf@kernel.org Oct. 8, 2024, 12:10 a.m. UTC | #2
Hello:

This series was applied to netdev/net-next.git (main)
by Jakub Kicinski <kuba@kernel.org>:

On Fri,  4 Oct 2024 13:47:16 +0000 you wrote:
> Inspired by 9b8ca04854fd ("ipv4: avoid quadratic behavior in
> FIB insertion of common address") and per-netns RTNL conversion
> started by Kuniyuki this week.
> 
> ip_fib_check_default() can use RCU instead of a shared spinlock.
> 
> fib_info_lock can be removed, RTNL is already used.
> 
> [...]

Here is the summary with links:
  - [net-next,1/4] ipv4: remove fib_devindex_hashfn()
    https://git.kernel.org/netdev/net-next/c/8a0f62fdeb9e
  - [net-next,2/4] ipv4: use rcu in ip_fib_check_default()
    https://git.kernel.org/netdev/net-next/c/fc38b28365e5
  - [net-next,3/4] ipv4: remove fib_info_lock
    https://git.kernel.org/netdev/net-next/c/143ca845ec0c
  - [net-next,4/4] ipv4: remove fib_info_devhash[]
    (no matching commit)

You are awesome, thank you!