mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git
synced 2025-01-09 07:23:14 +00:00
neighbour: fix neigh_master_filtered()
If we no longer hold RTNL, we must use netdev_master_upper_dev_get_rcu()
instead of netdev_master_upper_dev_get().
Fixes: ba0f780694
("neighbour: no longer hold RTNL in neigh_dump_info()")
Signed-off-by: Eric Dumazet <edumazet@google.com>
Reviewed-by: Jiri Pirko <jiri@nvidia.com>
Link: https://lore.kernel.org/r/20240421185753.1808077-1-edumazet@google.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
This commit is contained in:
parent
8d03c1534d
commit
1c04b46cbd
@ -2682,7 +2682,7 @@ static bool neigh_master_filtered(struct net_device *dev, int master_idx)
|
||||
if (!master_idx)
|
||||
return false;
|
||||
|
||||
master = dev ? netdev_master_upper_dev_get(dev) : NULL;
|
||||
master = dev ? netdev_master_upper_dev_get_rcu(dev) : NULL;
|
||||
|
||||
/* 0 is already used to denote NDA_MASTER wasn't passed, therefore need another
|
||||
* invalid value for ifindex to denote "no master".
|
||||
|
Loading…
Reference in New Issue
Block a user