]> git.baikalelectronics.ru Git - kernel.git/commit
brcmfmac: prevent possible race condition on usb rx control.
authorHante Meuleman <meuleman@broadcom.com>
Thu, 30 Aug 2012 17:42:58 +0000 (19:42 +0200)
committerJohn W. Linville <linville@tuxdriver.com>
Fri, 7 Sep 2012 19:03:42 +0000 (15:03 -0400)
commitc023efa81d74291f43c70c22be6d9a4c1b1f8f81
tree0813459a05076a7efd474178e579b48a825a4de7
parenta47732793e7e637ce3b2016b0cfdf0549a927e32
brcmfmac: prevent possible race condition on usb rx control.

brcmf_usb_tx_ctlpkt sends message using brcmf_usb_send_ctl then
clears boolean and waits for boolean to be set (by another
thread). This can result in situation where flag gets cleared
while result was already received. First clearing the flag and
then sending the data will prevent this.

Reviewed-by: Arend Van Spriel (arend@broadcom.com)
Reviewed-by: Franky (Zhenhui) Lin <frankyl@broadcom.com>
Reviewed-by: Pieter-Paul Giesberts <pieterpg@broadcom.com>
Signed-off-by: Hante Meuleman <meuleman@broadcom.com>
Signed-off-by: Arend van Spriel <arend@broadcom.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/net/wireless/brcm80211/brcmfmac/usb.c