]> git.baikalelectronics.ru Git - kernel.git/commit
net: wirelesse: wcn36xx: pull allocation outside of critical section
authorMichal Nazarewicz <mina86@mina86.com>
Wed, 11 Dec 2013 16:43:39 +0000 (17:43 +0100)
committerJohn W. Linville <linville@tuxdriver.com>
Wed, 18 Dec 2013 20:18:19 +0000 (15:18 -0500)
commit33c974907220cf2ae2ab85fef4bef27eec9868ea
tree1d43bd6a347b3c6c23ff9890876952c5866b77b0
parent5423c79ffc436a9655ae46a50771d94ce75accfd
net: wirelesse: wcn36xx: pull allocation outside of critical section

Commit [61c4b20b: fix potential NULL pointer dereference] introduced
a check of msg_ind allocation, but omitted allocation of msg_ind->msg.
Moreover, it introduced two if statements, which looked a bit clunky.

This commit moves allocation code outside of the critical section so
there's no need to dance around mutex_unlock, and adds the missing
allocation check.

Signed-off-by: Michal Nazarewicz <mina86@mina86.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/net/wireless/ath/wcn36xx/smd.c