staging: ath6kl: Fixing a race condition during initialization
authorVipin Mehta <vmehta@atheros.com>
Fri, 17 Sep 2010 16:55:15 +0000 (09:55 -0700)
committerGreg Kroah-Hartman <gregkh@suse.de>
Tue, 21 Sep 2010 00:02:02 +0000 (17:02 -0700)
commit9b906a33e0a459ea4d51c8d243154c6998be2a1d
treeb65c3139397cb74da1f0858d7c28c48b3a0bcc01
parent103281df0b7fec07872ef033666a1707b5755b9c
staging: ath6kl: Fixing a race condition during initialization

The commit fixes a race condition in the initialization portion of the
driver. The problem was observed while testing with the kernel in the
staging-next tree. The wait on the ready event is signalled prematurely
before setting the arVersion.wlan_ver and arVersion.abi_ver. The code
waiting on this semaphore checks for the validity of these values and
hence may proceed with an un-updated values of these fields. The wakeup
signal is now sent after these values are set.

Signed-off-by: Vipin Mehta <vmehta@atheros.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/staging/ath6kl/os/linux/ar6000_drv.c