kernel_samsung_a53x/drivers/net/bonding
Johannes Berg 7dc1b04912 net: bonding: correctly annotate RCU in bond_should_notify_peers()
[ Upstream commit 3ba359c0cd6eb5ea772125a7aededb4a2d516684 ]

RCU use in bond_should_notify_peers() looks wrong, since it does
rcu_dereference(), leaves the critical section, and uses the
pointer after that.

Luckily, it's called either inside a nested RCU critical section
or with the RTNL held.

Annotate it with rcu_dereference_rtnl() instead, and remove the
inner RCU critical section.

Fixes: 4cb4f97b7e36 ("bonding: rebuild the lock use for bond_mii_monitor()")
Reviewed-by: Jiri Pirko <jiri@nvidia.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Acked-by: Jay Vosburgh <jv@jvosburgh.net>
Link: https://patch.msgid.link/20240719094119.35c62455087d.I68eb9c0f02545b364b79a59f2110f2cf5682a8e2@changeid
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2024-11-23 23:20:17 +01:00
..
bond_3ad.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
bond_alb.c bonding: return -ENOMEM instead of BUG in alb_upper_dev_walk 2024-11-18 12:13:12 +01:00
bond_debugfs.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
bond_main.c net: bonding: correctly annotate RCU in bond_should_notify_peers() 2024-11-23 23:20:17 +01:00
bond_netlink.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
bond_options.c bonding: Fix out-of-bounds read in bond_option_arp_ip_targets_set() 2024-11-19 14:19:41 +01:00
bond_procfs.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
bond_sysfs.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
bond_sysfs_slave.c Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
bonding_priv.h Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00
Makefile Import A536BXXU9EXDC 2024-06-15 16:02:09 -03:00