Fix continuous scan req failure because of connection in progress
In random case, driver rejects all scan request for longer time saying that
connection in progress. There are two changes covered in this patch to fix
that issue.
1) When disconnect request comes from user space, wlan_hdd_disconnect()
issues disconnect request to SME and waits for the disconnect completion
with 500ms timeout. In some rare cases, whole disconnection process
takes more than 500 ms to complete. On such senario, wlan_hdd_disconnect
posts success to upper layer (immediately after 500ms) even before whole
disconnection process completes. To force wlan_hdd_disconnect() to wait
more time, disconnect timeout value is increased from 500 ms to 2 sec.
2) Also, scan done callback changed to report correct scan status to
cfg80211. Earlier scan result status always informed as success
irrespective of actual scan result. This change mainly for cfg80211
not to post any scan results to user space in scan failure cases.
Change-Id: I651a35532d9594615de2731f992ff1b6aeb2cb0b
CRs-Fixed: 623307
diff --git a/CORE/HDD/inc/wlan_hdd_main.h b/CORE/HDD/inc/wlan_hdd_main.h
index 0339d25..0ac38c3 100644
--- a/CORE/HDD/inc/wlan_hdd_main.h
+++ b/CORE/HDD/inc/wlan_hdd_main.h
@@ -100,7 +100,7 @@
#define TDLS_INIT_DONE (6)
/** Maximum time(ms)to wait for disconnect to complete **/
-#define WLAN_WAIT_TIME_DISCONNECT 500
+#define WLAN_WAIT_TIME_DISCONNECT 2000
#define WLAN_WAIT_TIME_STATS 800
#define WLAN_WAIT_TIME_POWER 800
#define WLAN_WAIT_TIME_COUNTRY 1000