linux/drivers/net/wireless/wl12xx
Juuso Oikarinen 76a029fbfb wl1271: Fix scan race condition
In the scan state machine, the wl1271_mutex is unlocked first then relocked,
and then the scan state variables are modified.

This makes it possible for ieee80211_scan_complete to be called twice in some
scenarios, as the scan completion event from the firmware may be processed
while the mutex is unlocked.

To fix the issue, move the ieee80211_scan_complete call last in the function.
This is generally safer, but there still may be issues is functions calling
the scan state machine rely on states checked before the unlocking of the
global mutex.

(forward ported from 2.6.32 -- this is not strictly needed anymore, because
the mutex doesn't need to be unlocked anymore, but I'm applying this change
anyway, so that the call to ieee80211_scan_complete is in the same place)

Signed-off-by: Juuso Oikarinen <juuso.oikarinen@nokia.com>
Reviewed-by: Saravanan Dhanabal <ext-saravanan.dhanabal@nokia.com>
Signed-off-by: Luciano Coelho <luciano.coelho@nokia.com>
2010-09-28 12:15:05 +03:00
..
Kconfig wl12xx: add platform data passing support 2010-09-21 11:04:57 -04:00
Makefile
wl12xx_80211.h
wl12xx_platform_data.c wl12xx: add platform data passing support 2010-09-21 11:04:57 -04:00
wl1251_acx.c drivers/net/wireless/wl12xx: Use available error codes 2010-08-24 16:28:05 -04:00
wl1251_acx.h wl1251: remove copyright contact person 2010-08-25 14:33:19 -04:00
wl1251_boot.c wl1251: remove copyright contact person 2010-08-25 14:33:19 -04:00
wl1251_boot.h wl1251: remove copyright contact person 2010-08-25 14:33:19 -04:00
wl1251_cmd.c drivers/net/wireless/wl12xx: Use available error codes 2010-08-24 16:28:05 -04:00
wl1251_cmd.h wl1251: remove copyright contact person 2010-08-25 14:33:19 -04:00
wl1251_debugfs.c wl1251: remove copyright contact person 2010-08-25 14:33:19 -04:00
wl1251_debugfs.h wl1251: remove copyright contact person 2010-08-25 14:33:19 -04:00
wl1251_event.c wl12xx: remove unneeded locking 2010-08-27 13:27:06 -04:00
wl1251_event.h wl1251: remove copyright contact person 2010-08-25 14:33:19 -04:00
wl1251_init.c wl1251: remove copyright contact person 2010-08-25 14:33:19 -04:00
wl1251_init.h wl1251: remove copyright contact person 2010-08-25 14:33:19 -04:00
wl1251_io.c wl1251: remove copyright contact person 2010-08-25 14:33:19 -04:00
wl1251_io.h
wl1251_main.c wl1251: Fix queue stopping/waking for TX path 2010-08-31 14:20:40 -04:00
wl1251_ps.c wl1251: remove copyright contact person 2010-08-25 14:33:19 -04:00
wl1251_ps.h wl1251: move include guard after the license 2010-08-25 14:33:19 -04:00
wl1251_reg.h wl1251: remove copyright contact person 2010-08-25 14:33:19 -04:00
wl1251_rx.c wl1251: remove copyright contact person 2010-08-25 14:33:19 -04:00
wl1251_rx.h wl1251: remove copyright contact person 2010-08-25 14:33:19 -04:00
wl1251_sdio.c wl12xx: make wl12xx.h common to both spi and sdio 2010-09-21 11:04:38 -04:00
wl1251_spi.c wl12xx: make wl12xx.h common to both spi and sdio 2010-09-21 11:04:38 -04:00
wl1251_spi.h wl1251: remove copyright contact person 2010-08-25 14:33:19 -04:00
wl1251_tx.c wl1251: Fix queue stopping/waking for TX path 2010-08-31 14:20:40 -04:00
wl1251_tx.h wl1251: remove copyright contact person 2010-08-25 14:33:19 -04:00
wl1251.h wl1251: Fix queue stopping/waking for TX path 2010-08-31 14:20:40 -04:00
wl1271_acx.c drivers/net/wireless/wl12xx: Use available error codes 2010-08-24 16:28:06 -04:00
wl1271_acx.h wl1271: remove deprecated ACX definition 2010-09-28 12:15:02 +03:00
wl1271_boot.c wl1271: Fix overflow in wl1271_boot_upload_nvs 2010-09-27 15:57:38 -04:00
wl1271_boot.h wl1271: make ref_clock configurable by board 2010-09-21 11:05:00 -04:00
wl1271_cmd.c wl1271: Implement CMD_SET_STA_STATE to indicate connection completion to FW 2010-09-28 12:15:03 +03:00
wl1271_cmd.h wl1271: Implement CMD_SET_STA_STATE to indicate connection completion to FW 2010-09-28 12:15:03 +03:00
wl1271_conf.h
wl1271_debugfs.c
wl1271_debugfs.h
wl1271_event.c
wl1271_event.h Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-next-2.6 into for-davem 2010-07-13 15:57:29 -04:00
wl1271_ini.h
wl1271_init.c
wl1271_init.h
wl1271_io.c
wl1271_io.h wl1271: propagate set_power's return value 2010-09-21 11:04:56 -04:00
wl1271_main.c wl1271: Fix scan race condition 2010-09-28 12:15:05 +03:00
wl1271_ps.c
wl1271_ps.h
wl1271_reg.h
wl1271_rx.c wl1271: avoid redundant memcpy of rx_status 2010-09-21 11:05:28 -04:00
wl1271_rx.h
wl1271_scan.c wl1271: Fix scan race condition 2010-09-28 12:15:05 +03:00
wl1271_scan.h wl1271: use __packed annotation 2010-07-12 16:05:31 -04:00
wl1271_sdio.c wl1271: make ref_clock configurable by board 2010-09-21 11:05:00 -04:00
wl1271_spi.c wl1271: make ref_clock configurable by board 2010-09-21 11:05:00 -04:00
wl1271_testmode.c
wl1271_testmode.h
wl1271_tx.c mac80211: use cipher suite selectors 2010-08-16 16:45:11 -04:00
wl1271_tx.h
wl1271.h wl1271: Add trigger to net_device oper_state to change BT coex priority 2010-09-28 12:15:04 +03:00