ath9k: fix beacon resource related race condition
authorRajkumar Manoharan <rmanoharan@atheros.com>
Tue, 7 Dec 2010 12:12:18 +0000 (17:42 +0530)
committerJohn W. Linville <linville@tuxdriver.com>
Tue, 7 Dec 2010 19:57:06 +0000 (14:57 -0500)
commit884a963fa1c828a5c5fa7a46b2877dd463bfd47c
treea44694ceaea70ed4beb362bac3ac6b59054b063a
parent38852b20c8b6d97618204ac64abbf14f0080393e
ath9k: fix beacon resource related race condition

The beacon tasklet is accesssing the bslot info for beacon generation.
Meanwhile the same slot can be freed on interface deletion.
Current the remove_interface disables the beacon alert after freeing the slot.
This may leads to null pointer access.

This patch disables SWBA and kills the beacon tasklet to prevent access
to the slot to be freed. After releasing the slot, swba will be enabled again
upon the availablity of beaconing interfaces.

Signed-off-by: Rajkumar Manoharan <rmanoharan@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/net/wireless/ath/ath9k/main.c