wil6210: abort P2P search when stopping P2P device
authorLior David <qca_liord@qca.qualcomm.com>
Wed, 8 Jun 2016 17:07:48 +0000 (20:07 +0300)
committerKalle Valo <kvalo@qca.qualcomm.com>
Tue, 14 Jun 2016 13:20:18 +0000 (16:20 +0300)
commiteb57a5b387d66be1f192a99b3707804e7f63715c
tree3578c780b923366fb664bdcf80fda9a85835a8da
parent9c830abe9194871d6d2846f37930ef373356a016
wil6210: abort P2P search when stopping P2P device

The nl80211 layer expects P2P search operation to be aborted
if needed when stopping P2P device. If the P2P search operation
is still running after returning from stop_p2p_device
it causes a WARN_ON and possibly a kernel crash.
Fix this by aborting the P2P search in wil_cfg80211_stop_p2p_device
and preventing P2P search from being started on a stopped P2P
device.
Note, the fix does not cover the case where a regular scan
is started on the P2P device. It will be completed in the
future when support is added for aborting a scan operation.

Signed-off-by: Lior David <qca_liord@qca.qualcomm.com>
Signed-off-by: Maya Erez <qca_merez@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
drivers/net/wireless/ath/wil6210/cfg80211.c
drivers/net/wireless/ath/wil6210/wil6210.h