linux/drivers/net/wireless
Ajay Singh dd66185c23 wifi: wilc1000: add missing read critical sections around vif list traversal
Some code manipulating the vif list is still missing some srcu_read_lock /
srcu_read_unlock, and so can trigger RCU warnings:

=============================
WARNING: suspicious RCU usage
6.8.0-rc1+ #37 Not tainted
-----------------------------
drivers/net/wireless/microchip/wilc1000/hif.c:110 RCU-list traversed without holding the required lock!!
[...]
stack backtrace:
CPU: 0 PID: 6 Comm: kworker/0:0 Not tainted 6.8.0-rc1+ #37
Hardware name: Atmel SAMA5
Workqueue: events sdio_irq_work
 unwind_backtrace from show_stack+0x18/0x1c
 show_stack from dump_stack_lvl+0x34/0x58
 dump_stack_lvl from wilc_get_vif_from_idx+0x158/0x180
 wilc_get_vif_from_idx from wilc_network_info_received+0x80/0x48c
 wilc_network_info_received from wilc_handle_isr+0xa10/0xd30
 wilc_handle_isr from wilc_sdio_interrupt+0x44/0x58
 wilc_sdio_interrupt from process_sdio_pending_irqs+0x1c8/0x60c
 process_sdio_pending_irqs from sdio_irq_work+0x6c/0x14c
 sdio_irq_work from process_one_work+0x8d4/0x169c
 process_one_work from worker_thread+0x8cc/0x1340
 worker_thread from kthread+0x448/0x510
 kthread from ret_from_fork+0x14/0x28

Fix those warnings by adding the needed lock around the corresponding
critical sections

Signed-off-by: Ajay Singh <ajay.kathat@microchip.com>
Co-developed-by: Alexis Lothoré <alexis.lothore@bootlin.com>
Signed-off-by: Alexis Lothoré <alexis.lothore@bootlin.com>
Signed-off-by: Kalle Valo <kvalo@kernel.org>
Link: https://msgid.link/20240215-wilc_fix_rcu_usage-v1-4-f610e46c6f82@bootlin.com
2024-02-19 18:21:36 +02:00
..
admtek wifi: mac80211: simplify non-chanctx drivers 2024-02-08 12:58:32 +01:00
ath wifi: mac80211: remove gfp parameter from ieee80211_obss_color_collision_notify 2024-02-12 21:07:30 +01:00
atmel wifi: mac80211: simplify non-chanctx drivers 2024-02-08 12:58:32 +01:00
broadcom wifi: brcmsmac: avoid function pointer casts 2024-02-16 17:48:59 +02:00
intel wifi: iwlwifi: cancel session protection only if there is one 2024-02-15 10:58:36 +01:00
intersil wifi: mac80211: simplify non-chanctx drivers 2024-02-08 12:58:32 +01:00
marvell wifi: mwifiex: Refactor 1-element array into flexible array in struct mwifiex_ie_types_chan_list_param_set 2024-02-12 17:37:59 +02:00
mediatek wifi: mac80211: add support to call csa_finish on a link 2024-02-08 15:00:45 +01:00
microchip wifi: wilc1000: add missing read critical sections around vif list traversal 2024-02-19 18:21:36 +02:00
purelifi wifi: mac80211: simplify non-chanctx drivers 2024-02-08 12:58:32 +01:00
quantenna wifi: cfg80211/mac80211: move puncturing into chandef 2024-02-08 15:00:39 +01:00
ralink wifi: mac80211: simplify non-chanctx drivers 2024-02-08 12:58:32 +01:00
realtek wifi: rtw89: 8922a: add helper of set_channel 2024-02-19 18:21:00 +02:00
rsi wifi: mac80211: introduce 'channel request' 2024-02-08 13:07:34 +01:00
silabs wifi: mac80211: introduce 'channel request' 2024-02-08 13:07:34 +01:00
st wifi: mac80211: simplify non-chanctx drivers 2024-02-08 12:58:32 +01:00
ti wifi: mac80211: add support to call csa_finish on a link 2024-02-08 15:00:45 +01:00
virtual wifi: mac80211_hwsim: Add 160MHz bw range to regdom_custom_04 2024-02-12 21:17:53 +01:00
zydas wifi: mac80211: simplify non-chanctx drivers 2024-02-08 12:58:32 +01:00
Kconfig wifi: remove orphaned rndis_wlan driver 2023-10-30 19:30:33 +02:00
Makefile wifi: remove orphaned rndis_wlan driver 2023-10-30 19:30:33 +02:00