wil6210: prevent double disconnect command issuing
authorVladimir Kondratiev <qca_vkondrat@qca.qualcomm.com>
Tue, 28 Oct 2014 14:50:08 +0000 (16:50 +0200)
committerJohn W. Linville <linville@tuxdriver.com>
Thu, 30 Oct 2014 19:26:50 +0000 (15:26 -0400)
commitb516fcc5542d41041156b8e5f93f47cbb603c4b7
tree069bbaf83202f02857d068f30c247de475a50863
parent48516298edb4260748c52064f828319c3bb15536
wil6210: prevent double disconnect command issuing

Disconnect flow may be invoked either from upper layer request,
or from event reported by the firmware.

In case of firmware event, driver need to release resources for the station but
not send another disconnect WMI command.

In case of upper layer request, WMI_DISCONNECT_STA_CMDID command need to
be issued for the firmware to perform disconnect on the MAC layer. Eventually,
event is expected to confirm MAC disconnect, but it is better to not wait for
firmware event and release station resources immediately. FW may fail to
report disconnect for various reasons, so one could not rely on event always reported.

Introduce parameter to distinguish 2 cases above to prevent double WMI command
issuing.

Signed-off-by: Vladimir Kondratiev <qca_vkondrat@qca.qualcomm.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/net/wireless/ath/wil6210/cfg80211.c
drivers/net/wireless/ath/wil6210/main.c
drivers/net/wireless/ath/wil6210/wil6210.h
drivers/net/wireless/ath/wil6210/wmi.c