Skip to content

Commit 253216f

Browse files
Madhuparna Bhowmikjmberg-intel
authored andcommitted
mac80211: rx: avoid RCU list traversal under mutex
local->sta_mtx is held in __ieee80211_check_fast_rx_iface(). No need to use list_for_each_entry_rcu() as it also requires a cond argument to avoid false lockdep warnings when not used in RCU read-side section (with CONFIG_PROVE_RCU_LIST). Therefore use list_for_each_entry(); Signed-off-by: Madhuparna Bhowmik <madhuparnabhowmik10@gmail.com> Link: https://lore.kernel.org/r/20200223143302.15390-1-madhuparnabhowmik10@gmail.com Signed-off-by: Johannes Berg <johannes.berg@intel.com>
1 parent e3ae39e commit 253216f

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

‎net/mac80211/rx.c‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4114,7 +4114,7 @@ void __ieee80211_check_fast_rx_iface(struct ieee80211_sub_if_data *sdata)
41144114

41154115
lockdep_assert_held(&local->sta_mtx);
41164116

4117-
list_for_each_entry_rcu(sta, &local->sta_list, list) {
4117+
list_for_each_entry(sta, &local->sta_list, list) {
41184118
if (sdata != sta->sdata &&
41194119
(!sta->sdata->bss || sta->sdata->bss != sdata->bss))
41204120
continue;

0 commit comments

Comments
 (0)