summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKapil Gupta <kapgupta@codeaurora.org>2016-09-22 16:48:12 +0530
committerqcabuildsw <qcabuildsw@localhost>2016-10-04 20:55:42 -0700
commit139c330d9500dcd6dcea9a1ac62054c236a674ee (patch)
tree642d10b91bda8608647503ec7ae572207d1a118e
parent80f4a8dad8cfa605e4e9c97a5eeea55f6ac57ee7 (diff)
qcacld-3.0: Cancel Remain on channel command before stop ap
qcacld-2.0 to qcacld-3.0 propagation If P2P-GO stop comes during ROC, it may cause WLANSAP_StopBss API to fail. ROC is stuck as firmware is running Gscan which is higher priority than p2p ROC scan prioirty. This causes ROC command to be stuck in the active list for 10 seconds and will eventually cause a crash in FW when host will try to add self peer since older peer is still present in the FW with same mac address Add change to increase the priority of P2P scan and cancel ROC before calling stop AP API. CRs-Fixed: 1065161 Change-Id: I3a62234596c8c2acc0155b483847b9adc159d757
-rw-r--r--core/hdd/src/wlan_hdd_hostapd.c1
-rw-r--r--core/wma/src/wma_scan_roam.c3
2 files changed, 4 insertions, 0 deletions
diff --git a/core/hdd/src/wlan_hdd_hostapd.c b/core/hdd/src/wlan_hdd_hostapd.c
index de59d24f7863..46459b386cf0 100644
--- a/core/hdd/src/wlan_hdd_hostapd.c
+++ b/core/hdd/src/wlan_hdd_hostapd.c
@@ -7546,6 +7546,7 @@ static int __wlan_hdd_cfg80211_stop_ap(struct wiphy *wiphy,
}
hdd_cleanup_actionframe(pHddCtx, pAdapter);
+ wlan_hdd_cleanup_remain_on_channel_ctx(pAdapter);
mutex_lock(&pHddCtx->sap_lock);
if (test_bit(SOFTAP_BSS_STARTED, &pAdapter->event_flags)) {
diff --git a/core/wma/src/wma_scan_roam.c b/core/wma/src/wma_scan_roam.c
index 3418f1d19d95..1bba4b8718dd 100644
--- a/core/wma/src/wma_scan_roam.c
+++ b/core/wma/src/wma_scan_roam.c
@@ -566,6 +566,9 @@ QDF_STATUS wma_start_scan(tp_wma_handle wma_handle,
cmd.vdev_id, P2P_SCAN_TYPE_LISTEN);
WMA_LOGI("scan_id 0x%x, vdev_id %d, p2pScanType %d, msg_type 0x%x",
cmd.scan_id, cmd.vdev_id, scan_req->p2pScanType, msg_type);
+
+ if (scan_req->p2pScanType)
+ cmd.scan_priority = WMI_SCAN_PRIORITY_MEDIUM;
/*
* Cache vdev_id and scan_id because cmd is freed after calling
* wmi_unified_cmd_send cmd. WMI internally frees cmd buffer after