]> git.baikalelectronics.ru Git - kernel.git/commit
[PATCH] softmac: make non-operational after being stopped
authorDaniel Drake <dsd@gentoo.org>
Sun, 30 Apr 2006 21:09:07 +0000 (22:09 +0100)
committerJohn W. Linville <linville@tuxdriver.com>
Fri, 5 May 2006 20:55:22 +0000 (16:55 -0400)
commitaa422e37f8c1a6719bc8dd15b7f5d6d6b66c7958
tree5724c4017f744df284fb9f18e5b9c8a8bcb7fbcf
parent00f1a7a928b74e55318ecc54986fd31d35f02fc7
[PATCH] softmac: make non-operational after being stopped

zd1211 with softmac and wpa_supplicant revealed an issue with softmac
and the use of workqueues. Some of the work functions actually
reschedule themselves, so this meant that there could still be
pending work after flush_scheduled_work() had been called during
ieee80211softmac_stop().

This patch introduces a "running" flag which is used to ensure that
rescheduling does not happen in this situation.

I also used this flag to ensure that softmac's hooks into ieee80211 are
non-operational once the stop operation has been started. This simply
makes softmac a little more robust, because I could crash it easily
by receiving frames in the short timeframe after shutting down softmac
and before turning off the ZD1211 radio. (ZD1211 is now fixed as well!)

Signed-off-by: Daniel Drake <dsd@gentoo.org>
Acked-by: Johannes Berg <johannes@sipsolutions.net>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
include/net/ieee80211softmac.h
net/ieee80211/softmac/ieee80211softmac_assoc.c
net/ieee80211/softmac/ieee80211softmac_auth.c
net/ieee80211/softmac/ieee80211softmac_module.c
net/ieee80211/softmac/ieee80211softmac_scan.c