diff options
author | Eric Dumazet <edumazet@google.com> | 2023-03-21 07:01:14 +0300 |
---|---|---|
committer | Jakub Kicinski <kuba@kernel.org> | 2023-03-22 07:32:18 +0300 |
commit | 09eed1192cec1755967f2af8394207acdde579a1 (patch) | |
tree | 56d5468faacd013422de043a3263016b34b300a6 /net/ipv4/nexthop.c | |
parent | 4c5c496a942fa3d2197f5be22762695170c95863 (diff) | |
download | linux-09eed1192cec1755967f2af8394207acdde579a1.tar.xz |
neighbour: switch to standard rcu, instead of rcu_bh
rcu_bh is no longer a win, especially for objects freed
with standard call_rcu().
Switch neighbour code to no longer disable BH when not necessary.
Signed-off-by: Eric Dumazet <edumazet@google.com>
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'net/ipv4/nexthop.c')
-rw-r--r-- | net/ipv4/nexthop.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/net/ipv4/nexthop.c b/net/ipv4/nexthop.c index e28a99f1996b..f95142e56da0 100644 --- a/net/ipv4/nexthop.c +++ b/net/ipv4/nexthop.c @@ -1124,13 +1124,13 @@ static bool ipv6_good_nh(const struct fib6_nh *nh) int state = NUD_REACHABLE; struct neighbour *n; - rcu_read_lock_bh(); + rcu_read_lock(); n = __ipv6_neigh_lookup_noref_stub(nh->fib_nh_dev, &nh->fib_nh_gw6); if (n) state = READ_ONCE(n->nud_state); - rcu_read_unlock_bh(); + rcu_read_unlock(); return !!(state & NUD_VALID); } @@ -1140,14 +1140,14 @@ static bool ipv4_good_nh(const struct fib_nh *nh) int state = NUD_REACHABLE; struct neighbour *n; - rcu_read_lock_bh(); + rcu_read_lock(); n = __ipv4_neigh_lookup_noref(nh->fib_nh_dev, (__force u32)nh->fib_nh_gw4); if (n) state = READ_ONCE(n->nud_state); - rcu_read_unlock_bh(); + rcu_read_unlock(); return !!(state & NUD_VALID); } |