summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLinux Build Service Account <lnxbuild@localhost>2014-05-20 21:27:19 -0700
committerGerrit - the friendly Code Review server <code-review@localhost>2014-05-20 21:27:19 -0700
commit8ca3308efa6abdff347266c0098f2211287d5b1b (patch)
tree6965cfef0d2887214ee93528de3a0d544ee4501b
parent2fa86339070c6ab3b093b685a353181b94b6c7da (diff)
parentc9b21c9176515d0f571f998fb51f56ee4761bae3 (diff)
Merge "Release 1.0.0.112 QCACLD WLAN Driver"
-rw-r--r--CORE/CLD_TXRX/HTT/htt_rx.c10
-rw-r--r--CORE/HDD/inc/wlan_hdd_main.h8
-rw-r--r--CORE/HDD/src/wlan_hdd_cfg80211.c124
-rw-r--r--CORE/HDD/src/wlan_hdd_main.c13
-rw-r--r--CORE/HDD/src/wlan_hdd_tdls.c23
-rw-r--r--CORE/MAC/inc/qwlan_version.h4
-rw-r--r--CORE/MAC/inc/sirApi.h2
-rw-r--r--CORE/MAC/src/pe/lim/limProcessSmeReqMessages.c1
-rw-r--r--CORE/SAP/src/sapChSelect.c53
-rw-r--r--CORE/SERVICES/COMMON/adf/adf_os_mem.h27
-rw-r--r--CORE/SERVICES/COMMON/hif_msg_based.h2
-rw-r--r--CORE/SERVICES/COMMON/osapi_linux.h4
-rw-r--r--CORE/SERVICES/COMMON/osdep_adf.h4
-rw-r--r--CORE/SERVICES/HIF/PCIe/hif_pci.c18
-rw-r--r--CORE/SERVICES/HIF/PCIe/if_pci.c15
-rw-r--r--CORE/SERVICES/HIF/PCIe/if_pci.h1
-rw-r--r--CORE/SERVICES/HTC/htc.c8
-rw-r--r--CORE/SERVICES/WMA/wma.c49
-rw-r--r--CORE/SERVICES/WMA/wma.h5
-rw-r--r--CORE/SME/src/csr/csrApiScan.c2
-rw-r--r--CORE/VOSS/inc/wcnss_api.h10
-rw-r--r--CORE/VOSS/src/vos_memory.c6
22 files changed, 228 insertions, 161 deletions
diff --git a/CORE/CLD_TXRX/HTT/htt_rx.c b/CORE/CLD_TXRX/HTT/htt_rx.c
index ff357d9620f8..766afe73f4e7 100644
--- a/CORE/CLD_TXRX/HTT/htt_rx.c
+++ b/CORE/CLD_TXRX/HTT/htt_rx.c
@@ -876,16 +876,13 @@ htt_rx_amsdu_pop_ll(
*/
#ifdef DEBUG_DMA_DONE
- /* if done bit is not set */
if (adf_os_unlikely(!((*(u_int32_t *) &rx_desc->attention)
& RX_ATTENTION_0_MSDU_DONE_MASK))) {
int dbg_iter = MAX_DONE_BIT_CHECK_ITER;
- htt_rx_print_rx_indication(rx_ind_msg, pdev);
- htt_print_rx_desc(rx_desc);
- adf_os_print("done bit still not set retrying...\n");
+ adf_os_print("malformed frame\n");
while (dbg_iter &&
(!((*(u_int32_t *) &rx_desc->attention) &
@@ -898,18 +895,13 @@ htt_rx_amsdu_pop_ll(
adf_os_print("debug iter %d success %d\n", dbg_iter,
pdev->rx_ring.dbg_sync_success);
- htt_rx_print_rx_indication(rx_ind_msg, pdev);
- htt_print_rx_desc(rx_desc);
dbg_iter--;
}
- /* if the done bit is still not set, ASSERT the target */
if (adf_os_unlikely(!((*(u_int32_t *) &rx_desc->attention)
& RX_ATTENTION_0_MSDU_DONE_MASK)))
{
- htt_rx_print_rx_indication(rx_ind_msg, pdev);
- htt_print_rx_desc(rx_desc);
process_wma_set_command(0,(int)GEN_PARAM_CRASH_INJECT,
0, GEN_CMD);
diff --git a/CORE/HDD/inc/wlan_hdd_main.h b/CORE/HDD/inc/wlan_hdd_main.h
index 395c3caf0d00..ad9c539b55c0 100644
--- a/CORE/HDD/inc/wlan_hdd_main.h
+++ b/CORE/HDD/inc/wlan_hdd_main.h
@@ -305,6 +305,9 @@ extern spinlock_t hdd_context_lock;
#define WLAN_HDD_TX_FLOW_CONTROL_MAX_24BAND_CH 14
#endif /* QCA_LL_TX_FLOW_CT */
+/* Max PMKSAIDS available in cache */
+#define MAX_PMKSAIDS_IN_CACHE 8
+
typedef struct hdd_tx_rx_stats_s
{
// start_xmit stats
@@ -680,6 +683,10 @@ struct hdd_station_ctx
/*Save the wep/wpa-none keys*/
tCsrRoamSetKey ibss_enc_key;
v_BOOL_t hdd_ReassocScenario;
+
+ /* PMKID Cache */
+ tPmkidCacheInfo PMKIDCache[MAX_PMKSAIDS_IN_CACHE];
+ tANI_U32 PMKIDCacheIndex;
};
#define BSS_STOP 0
@@ -882,6 +889,7 @@ typedef enum
#define WLAN_HDD_ADAPTER_MAGIC 0x574c414e //ASCII "WLAN"
+
struct hdd_adapter_s
{
void *pHddCtx;
diff --git a/CORE/HDD/src/wlan_hdd_cfg80211.c b/CORE/HDD/src/wlan_hdd_cfg80211.c
index 808a08c5a31b..b589d932a5bc 100644
--- a/CORE/HDD/src/wlan_hdd_cfg80211.c
+++ b/CORE/HDD/src/wlan_hdd_cfg80211.c
@@ -2588,13 +2588,15 @@ static int wlan_hdd_cfg80211_start_bss(hdd_adapter_t *pHostapdAdapter,
THEN
Fallback to 11N mode
*/
- if (((AUTO_CHANNEL_SELECT != pConfig->channel && pConfig->channel <= 14)
+ if ((((AUTO_CHANNEL_SELECT != pConfig->channel && pConfig->channel <= 14)
|| (AUTO_CHANNEL_SELECT == pConfig->channel &&
- iniConfig->apOperatingBand == eSAP_RF_SUBBAND_2_4_GHZ))
- &&
+ iniConfig->apOperatingBand == eSAP_RF_SUBBAND_2_4_GHZ)) &&
(WLAN_HDD_GET_CTX(pHostapdAdapter)->cfg_ini->enableVhtFor24GHzBand
- == FALSE))
+ == FALSE)) ||
+ (WLAN_HDD_GET_CTX(pHostapdAdapter)->isVHT80Allowed == FALSE))
+ {
pConfig->SapHw_mode = eSAP_DOT11_MODE_11n;
+ }
}
#endif
@@ -3222,13 +3224,6 @@ static int wlan_hdd_change_iface_to_sta_mode(struct net_device *ndev,
wdev = ndev->ieee80211_ptr;
hdd_stop_adapter(pHddCtx, pAdapter);
-#ifdef FEATURE_WLAN_TDLS
- /* A Mutex Lock is introduced while changing the mode to
- * protect the concurrent access for the Adapters by TDLS
- * module.
- */
- mutex_lock(&pHddCtx->tdls_lock);
-#endif
hdd_deinit_adapter(pHddCtx, pAdapter);
wdev->iftype = type;
/*Check for sub-string p2p to confirm its a p2p interface*/
@@ -3246,9 +3241,6 @@ static int wlan_hdd_change_iface_to_sta_mode(struct net_device *ndev,
pHddCtx->change_iface = type;
memset(&pAdapter->sessionCtx, 0, sizeof(pAdapter->sessionCtx));
hdd_set_station_ops(pAdapter->dev);
-#ifdef FEATURE_WLAN_TDLS
- mutex_unlock(&pHddCtx->tdls_lock);
-#endif
status = hdd_init_station_mode(pAdapter);
wext = WLAN_HDD_GET_WEXT_STATE_PTR(pAdapter);
wext->roamProfile.pAddIEScan = pAdapter->scan_info.scanAddIE.addIEdata;
@@ -3466,22 +3458,12 @@ static int __wlan_hdd_cfg80211_change_iface(struct wiphy *wiphy,
}
}
hdd_stop_adapter( pHddCtx, pAdapter );
-#ifdef FEATURE_WLAN_TDLS
- /* A Mutex Lock is introduced while changing the mode to
- * protect the concurrent access for the Adapters by TDLS
- * module.
- */
- mutex_lock(&pHddCtx->tdls_lock);
-#endif
//De-init the adapter.
hdd_deinit_adapter( pHddCtx, pAdapter );
memset(&pAdapter->sessionCtx, 0, sizeof(pAdapter->sessionCtx));
pAdapter->device_mode = (type == NL80211_IFTYPE_AP) ?
WLAN_HDD_SOFTAP : WLAN_HDD_P2P_GO;
-#ifdef FEATURE_WLAN_TDLS
- mutex_unlock(&pHddCtx->tdls_lock);
-#endif
/*
* If Powersave Offload is enabled
@@ -8605,17 +8587,12 @@ static int wlan_hdd_cfg80211_add_station(struct wiphy *wiphy,
#ifdef FEATURE_WLAN_LFR
-#define MAX_PMKSAIDS_IN_CACHE 8
-
-static tPmkidCacheInfo PMKIDCache[MAX_PMKSAIDS_IN_CACHE]; // HDD local cache
-static tANI_U32 PMKIDCacheIndex; // HDD local Cache index
-
-
static int wlan_hdd_cfg80211_set_pmksa(struct wiphy *wiphy, struct net_device *dev,
struct cfg80211_pmksa *pmksa)
{
tANI_U32 j=0;
hdd_adapter_t *pAdapter = WLAN_HDD_GET_PRIV_PTR(dev);
+ hdd_station_ctx_t *pHddStaCtx;
tHalHandle halHandle;
eHalStatus result = eHAL_STATUS_SUCCESS;
int status;
@@ -8644,17 +8621,18 @@ static int wlan_hdd_cfg80211_set_pmksa(struct wiphy *wiphy, struct net_device *d
// Retrieve halHandle
halHandle = WLAN_HDD_GET_HAL_CTX(pAdapter);
+ pHddStaCtx = WLAN_HDD_GET_STATION_CTX_PTR(pAdapter);
- for (j = 0; j < PMKIDCacheIndex; j++)
+ for (j = 0; j < pHddStaCtx->PMKIDCacheIndex; j++)
{
- if(vos_mem_compare(PMKIDCache[j].BSSID,
+ if (vos_mem_compare(pHddStaCtx->PMKIDCache[j].BSSID,
pmksa->bssid, VOS_MAC_ADDR_SIZE))
{
/* BSSID matched previous entry. Overwrite it. */
BSSIDMatched = 1;
- vos_mem_copy(PMKIDCache[j].BSSID,
+ vos_mem_copy(pHddStaCtx->PMKIDCache[j].BSSID,
pmksa->bssid, VOS_MAC_ADDR_SIZE);
- vos_mem_copy(PMKIDCache[j].PMKID,
+ vos_mem_copy(pHddStaCtx->PMKIDCache[j].PMKID,
pmksa->pmkid,
CSR_RSN_PMKID_SIZE);
hddLog(VOS_TRACE_LEVEL_FATAL, "%s: Reusing cache entry %d.",
@@ -8666,35 +8644,37 @@ static int wlan_hdd_cfg80211_set_pmksa(struct wiphy *wiphy, struct net_device *d
}
/* Check we compared all entries,if then take the first slot now */
- if(j == MAX_PMKSAIDS_IN_CACHE) PMKIDCacheIndex=0;
+ if (j == MAX_PMKSAIDS_IN_CACHE) pHddStaCtx->PMKIDCacheIndex=0;
if (!BSSIDMatched)
{
// Now, we DON'T have a BSSID match, so take a new entry in the cache.
- vos_mem_copy(PMKIDCache[PMKIDCacheIndex].BSSID,
+ vos_mem_copy(pHddStaCtx->PMKIDCache[pHddStaCtx->PMKIDCacheIndex].BSSID,
pmksa->bssid, ETHER_ADDR_LEN);
- vos_mem_copy(PMKIDCache[PMKIDCacheIndex].PMKID,
+ vos_mem_copy(pHddStaCtx->PMKIDCache[pHddStaCtx->PMKIDCacheIndex].PMKID,
pmksa->pmkid,
CSR_RSN_PMKID_SIZE);
- hddLog(VOS_TRACE_LEVEL_FATAL, "%s: Adding a new cache entry %d.",
- __func__, PMKIDCacheIndex );
+ hddLog(VOS_TRACE_LEVEL_DEBUG, "%s: Adding a new cache entry %d.",
+ __func__, pHddStaCtx->PMKIDCacheIndex );
dump_bssid(pmksa->bssid);
dump_pmkid(halHandle, pmksa->pmkid);
// Increment the HDD Local Cache index
// The "i=0" doesn't work for the call to sme_RoamSetPMKIDCache() - LFR FIXME
- if (PMKIDCacheIndex <= (MAX_PMKSAIDS_IN_CACHE-1)) PMKIDCacheIndex++; else PMKIDCacheIndex = 0;
+ if (pHddStaCtx->PMKIDCacheIndex <= (MAX_PMKSAIDS_IN_CACHE-1))
+ pHddStaCtx->PMKIDCacheIndex++;
+ else
+ pHddStaCtx->PMKIDCacheIndex = 0;
}
// Calling csrRoamSetPMKIDCache to configure the PMKIDs into the cache
- //hddLog(LOG1, FL("%s: Calling csrRoamSetPMKIDCache with %d cache entries."),
- // __func__, i );
- hddLog(VOS_TRACE_LEVEL_FATAL, "%s: Calling csrRoamSetPMKIDCache with %d cache entries.",
- __func__, PMKIDCacheIndex );
+ hddLog(VOS_TRACE_LEVEL_DEBUG, "%s: Calling csrRoamSetPMKIDCache with %d cache entries.",
+ __func__, pHddStaCtx->PMKIDCacheIndex );
+
// Finally set the PMKSA ID Cache in CSR
result = sme_RoamSetPMKIDCache(halHandle,pAdapter->sessionId,
- PMKIDCache,
- PMKIDCacheIndex);
+ pHddStaCtx->PMKIDCache,
+ pHddStaCtx->PMKIDCacheIndex);
MTRACE(vos_trace(VOS_MODULE_ID_HDD,
TRACE_CODE_HDD_CFG80211_SET_PMKSA,
pAdapter->sessionId, result));
@@ -8708,6 +8688,7 @@ static int wlan_hdd_cfg80211_del_pmksa(struct wiphy *wiphy, struct net_device *d
{
tANI_U32 j=0;
hdd_adapter_t *pAdapter = WLAN_HDD_GET_PRIV_PTR(dev);
+ hdd_station_ctx_t *pHddStaCtx;
tHalHandle halHandle;
tANI_U8 BSSIDMatched = 0;
hdd_context_t *pHddCtx;
@@ -8735,50 +8716,53 @@ static int wlan_hdd_cfg80211_del_pmksa(struct wiphy *wiphy, struct net_device *d
/*Retrieve halHandle*/
halHandle = WLAN_HDD_GET_HAL_CTX(pAdapter);
+ pHddStaCtx = WLAN_HDD_GET_STATION_CTX_PTR(pAdapter);
/*in case index is 0,no entry to delete*/
- if (0 == PMKIDCacheIndex)
+ if (0 == pHddStaCtx->PMKIDCacheIndex)
{
- hddLog(VOS_TRACE_LEVEL_ERROR, FL("No entries to flush"));
- return -EINVAL;
+ hddLog(VOS_TRACE_LEVEL_INFO, FL("No entries to flush"));
+ return 0;
}
/*find the matching PMKSA entry from j=0 to (index-1),
* and delete the matched one
*/
- for (j = 0; j<PMKIDCacheIndex; j++)
+ for (j = 0; j < pHddStaCtx->PMKIDCacheIndex; j++)
{
- if (vos_mem_compare(PMKIDCache[j].BSSID,
+ if (vos_mem_compare(pHddStaCtx->PMKIDCache[j].BSSID,
pmksa->bssid,
VOS_MAC_ADDR_SIZE))
{
/* BSSID matched entry */
BSSIDMatched = 1;
- if (j<PMKIDCacheIndex-1)
+ if (j < pHddStaCtx->PMKIDCacheIndex-1)
{
/*replace the matching entry with the last entry in HDD local cache*/
- vos_mem_copy(PMKIDCache[j].BSSID,
- PMKIDCache[PMKIDCacheIndex-1].BSSID,
- VOS_MAC_ADDR_SIZE);
- vos_mem_copy(PMKIDCache[j].PMKID,
- PMKIDCache[PMKIDCacheIndex-1].PMKID,
- CSR_RSN_PMKID_SIZE);
+ vos_mem_copy(pHddStaCtx->PMKIDCache[j].BSSID,
+ pHddStaCtx->PMKIDCache[pHddStaCtx->PMKIDCacheIndex-1].BSSID,
+ VOS_MAC_ADDR_SIZE);
+ vos_mem_copy(pHddStaCtx->PMKIDCache[j].PMKID,
+ pHddStaCtx->PMKIDCache[pHddStaCtx->PMKIDCacheIndex-1].PMKID,
+ CSR_RSN_PMKID_SIZE);
}
/*clear the last entry in HDD cache ---[index-1]*/
- vos_mem_zero(PMKIDCache[PMKIDCacheIndex-1].BSSID, VOS_MAC_ADDR_SIZE);
- vos_mem_zero(PMKIDCache[PMKIDCacheIndex-1].PMKID, CSR_RSN_PMKID_SIZE);
+ vos_mem_zero(pHddStaCtx->PMKIDCache[pHddStaCtx->PMKIDCacheIndex-1].BSSID,
+ VOS_MAC_ADDR_SIZE);
+ vos_mem_zero(pHddStaCtx->PMKIDCache[pHddStaCtx->PMKIDCacheIndex-1].PMKID,
+ CSR_RSN_PMKID_SIZE);
/*reduce the PMKID array index*/
- PMKIDCacheIndex--;
+ pHddStaCtx->PMKIDCacheIndex--;
/*delete the last PMKID cache in CSR*/
if (eHAL_STATUS_SUCCESS !=
sme_RoamDelPMKIDfromCache(halHandle, pAdapter->sessionId, pmksa->bssid))
{
hddLog(VOS_TRACE_LEVEL_ERROR,"%s: cannot delete PMKSA %d CONTENT.",
- __func__,PMKIDCacheIndex);
+ __func__, pHddStaCtx->PMKIDCacheIndex);
status = -EINVAL;
}
@@ -8808,6 +8792,7 @@ static int wlan_hdd_cfg80211_flush_pmksa(struct wiphy *wiphy, struct net_device
{
tANI_U32 j=0;
hdd_adapter_t *pAdapter = WLAN_HDD_GET_PRIV_PTR(dev);
+ hdd_station_ctx_t *pHddStaCtx;
tHalHandle halHandle;
hdd_context_t *pHddCtx;
tANI_U8 *pBSSId;
@@ -8835,19 +8820,20 @@ static int wlan_hdd_cfg80211_flush_pmksa(struct wiphy *wiphy, struct net_device
/*Retrieve halHandle*/
halHandle = WLAN_HDD_GET_HAL_CTX(pAdapter);
+ pHddStaCtx = WLAN_HDD_GET_STATION_CTX_PTR(pAdapter);
/*in case index is 0,no entry to delete*/
- if (0 == PMKIDCacheIndex)
+ if (0 == pHddStaCtx->PMKIDCacheIndex)
{
hddLog(VOS_TRACE_LEVEL_INFO, "%s: No entries to flush" ,
__func__);
- return -EINVAL;
+ return 0;
}
/*delete all the PMKSA one by one */
- for (j = 0; j<PMKIDCacheIndex; j++)
+ for (j = 0; j < pHddStaCtx->PMKIDCacheIndex; j++)
{
- pBSSId =(tANI_U8 *)(PMKIDCache[j].BSSID);
+ pBSSId =(tANI_U8 *)(pHddStaCtx->PMKIDCache[j].BSSID);
/*delete the PMKID in CSR*/
if (eHAL_STATUS_SUCCESS !=
@@ -8858,11 +8844,11 @@ static int wlan_hdd_cfg80211_flush_pmksa(struct wiphy *wiphy, struct net_device
status = -EINVAL;
}
/*clear the entry in HDD cache 0--index-1 */
- vos_mem_zero(PMKIDCache[j].BSSID, VOS_MAC_ADDR_SIZE);
- vos_mem_zero(PMKIDCache[j].PMKID, CSR_RSN_PMKID_SIZE);
+ vos_mem_zero(pHddStaCtx->PMKIDCache[j].BSSID, VOS_MAC_ADDR_SIZE);
+ vos_mem_zero(pHddStaCtx->PMKIDCache[j].PMKID, CSR_RSN_PMKID_SIZE);
}
- PMKIDCacheIndex = 0;
+ pHddStaCtx->PMKIDCacheIndex = 0;
return status;
}
diff --git a/CORE/HDD/src/wlan_hdd_main.c b/CORE/HDD/src/wlan_hdd_main.c
index 4144f9ad3ba8..fda3f03aa827 100644
--- a/CORE/HDD/src/wlan_hdd_main.c
+++ b/CORE/HDD/src/wlan_hdd_main.c
@@ -8510,14 +8510,6 @@ VOS_STATUS hdd_close_adapter( hdd_context_t *pHddCtx, hdd_adapter_t *pAdapter,
wlan_hdd_clear_concurrency_mode(pHddCtx, pAdapter->device_mode);
hdd_cleanup_adapter( pHddCtx, pAdapterNode->pAdapter, rtnl_held );
-#ifdef FEATURE_WLAN_TDLS
-
- /* A Mutex Lock is introduced while changing/initializing the mode to
- * protect the concurrent access for the Adapters by TDLS module.
- */
- mutex_lock(&pHddCtx->tdls_lock);
-#endif
-
hdd_remove_adapter( pHddCtx, pAdapterNode );
vos_mem_free( pAdapterNode );
pAdapterNode = NULL;
@@ -8526,11 +8518,6 @@ VOS_STATUS hdd_close_adapter( hdd_context_t *pHddCtx, hdd_adapter_t *pAdapter,
if (pHddCtx->current_intf_count != 0)
pHddCtx->current_intf_count--;
-#ifdef FEATURE_WLAN_TDLS
- mutex_unlock(&pHddCtx->tdls_lock);
-#endif
-
-
/*
* If Powersave Offload is enabled,
* Fw will take care incase of concurrency
diff --git a/CORE/HDD/src/wlan_hdd_tdls.c b/CORE/HDD/src/wlan_hdd_tdls.c
index be70e8fa1be3..3444f3d39a8c 100644
--- a/CORE/HDD/src/wlan_hdd_tdls.c
+++ b/CORE/HDD/src/wlan_hdd_tdls.c
@@ -870,35 +870,38 @@ void wlan_hdd_tdls_exit(hdd_adapter_t *pAdapter)
eHalStatus halStatus = eHAL_STATUS_FAILURE;
#endif
- /*
- * NOTE: The Callers of this function should ensure to acquire the
- * tdls_lock to avoid any concurrent access to the Adapter.
- */
-
pHddCtx = WLAN_HDD_GET_CTX( pAdapter );
- if (0 != (wlan_hdd_validate_context(pHddCtx)))
+ if (!pHddCtx)
{
VOS_TRACE(VOS_MODULE_ID_HDD, VOS_TRACE_LEVEL_ERROR,
- FL("pHddCtx is not valid"));
+ FL("pHddCtx is NULL"));
return;
}
pHddTdlsCtx = WLAN_HDD_GET_TDLS_CTX_PTR(pAdapter);
if (NULL == pHddTdlsCtx)
{
- VOS_TRACE(VOS_MODULE_ID_HDD, VOS_TRACE_LEVEL_ERROR,
- FL("pHddTdlsCtx is NULL"));
- return;
+ /* TDLS context can be null and might have been freed up during
+ * cleanup for STA adapter
+ */
+ VOS_TRACE(VOS_MODULE_ID_HDD, VOS_TRACE_LEVEL_INFO_HIGH,
+ FL("pHddTdlsCtx is NULL, adapter device mode: %d"),
+ pAdapter->device_mode);
+ return;
}
vos_flush_work(&pHddTdlsCtx->implicit_setup);
vos_flush_delayed_work(&pHddCtx->tdls_scan_ctxt.tdls_scan_work);
+ mutex_lock(&pHddCtx->tdls_lock);
+
/* must stop timer here before freeing peer list, because peerIdleTimer is
part of peer list structure. */
wlan_hdd_tdls_timers_destroy(pHddTdlsCtx);
wlan_hdd_tdls_free_list(pHddTdlsCtx);
+ mutex_unlock(&pHddCtx->tdls_lock);
+
wlan_hdd_tdls_free_scan_request(&pHddCtx->tdls_scan_ctxt);
#ifdef QCA_WIFI_2_0
diff --git a/CORE/MAC/inc/qwlan_version.h b/CORE/MAC/inc/qwlan_version.h
index 4162ed9ac082..22814ee08df8 100644
--- a/CORE/MAC/inc/qwlan_version.h
+++ b/CORE/MAC/inc/qwlan_version.h
@@ -42,9 +42,9 @@ BRIEF DESCRIPTION:
#define QWLAN_VERSION_MINOR 0
#define QWLAN_VERSION_PATCH 0
#define QWLAN_VERSION_EXTRA ""
-#define QWLAN_VERSION_BUILD 111
+#define QWLAN_VERSION_BUILD 112
-#define QWLAN_VERSIONSTR "1.0.0.111"
+#define QWLAN_VERSIONSTR "1.0.0.112"
#ifdef QCA_WIFI_2_0
diff --git a/CORE/MAC/inc/sirApi.h b/CORE/MAC/inc/sirApi.h
index fa75e425d33a..17d44c0e1a56 100644
--- a/CORE/MAC/inc/sirApi.h
+++ b/CORE/MAC/inc/sirApi.h
@@ -863,6 +863,7 @@ typedef struct sSirSmeScanReq
*/
tANI_U32 minChannelTimeBtc; //in units of milliseconds
tANI_U32 maxChannelTimeBtc; //in units of milliseconds
+ tANI_U32 restTime; //in units of milliseconds, ignored when not connected
tANI_U8 returnAfterFirstMatch;
/**
@@ -4510,6 +4511,7 @@ typedef struct sSirScanOffloadReq {
tSirScanType scanType;
tANI_U32 minChannelTime;
tANI_U32 maxChannelTime;
+ tANI_U32 restTime; //in units of milliseconds, ignored when not connected
tSirP2pScanType p2pScanType;
tANI_U16 uIEFieldLen;
tANI_U16 uIEFieldOffset;
diff --git a/CORE/MAC/src/pe/lim/limProcessSmeReqMessages.c b/CORE/MAC/src/pe/lim/limProcessSmeReqMessages.c
index 75b604d0d090..3777c9b8766f 100644
--- a/CORE/MAC/src/pe/lim/limProcessSmeReqMessages.c
+++ b/CORE/MAC/src/pe/lim/limProcessSmeReqMessages.c
@@ -1155,6 +1155,7 @@ static eHalStatus limSendHalStartScanOffloadReq(tpAniSirGlobal pMac,
pScanOffloadReq->scanType = pScanReq->scanType;
pScanOffloadReq->minChannelTime = pScanReq->minChannelTime;
pScanOffloadReq->maxChannelTime = pScanReq->maxChannelTime;
+ pScanOffloadReq->restTime= pScanReq->restTime;
/* for normal scan, the value for p2pScanType should be 0
always */
diff --git a/CORE/SAP/src/sapChSelect.c b/CORE/SAP/src/sapChSelect.c
index d09c98b2eeca..48da308a60d0 100644
--- a/CORE/SAP/src/sapChSelect.c
+++ b/CORE/SAP/src/sapChSelect.c
@@ -1907,12 +1907,14 @@ void sapSortChlWeight(tSapChSelSpectInfo *pSpectInfoParams)
============================================================================*/
void sapSortChlWeightHT80(tSapChSelSpectInfo *pSpectInfoParams)
{
- v_U8_t i, j;
+ v_U8_t i, j, n;
tSapSpectChInfo *pSpectInfo;
+ v_U32_t minWeight;
+ v_U8_t minIdx;
pSpectInfo = pSpectInfoParams->pSpectCh;
- /* for each HT40 channel, calculate the combined weight of the
- two 20MHz weight */
+ /* for each HT80 channel, calculate the combined weight of the
+ four 20MHz weight */
for (i = 0; i < ARRAY_SIZE(acsHT80Channels); i++)
{
for (j = 0; j < pSpectInfoParams->numSpectChans; j++)
@@ -1932,12 +1934,25 @@ void sapSortChlWeightHT80(tSapChSelSpectInfo *pSpectInfoParams)
pSpectInfo[j+1].weight +
pSpectInfo[j+2].weight +
pSpectInfo[j+3].weight;
- pSpectInfo[j].weight = acsHT80Channels[i].weight;
- /*mark the adjacent channel's weight as max value so
- that it will be sorted to the bottom */
- pSpectInfo[j+1].weight = ACS_WEIGHT_MAX;
- pSpectInfo[j+2].weight = ACS_WEIGHT_MAX;
- pSpectInfo[j+3].weight = ACS_WEIGHT_MAX;
+ /* find best channel among 4 channels as the primary channel */
+ minWeight = pSpectInfo[j].weight;
+ minIdx = 0;
+ for (n=1; n<4; n++)
+ {
+ if (minWeight > pSpectInfo[j+n].weight)
+ {
+ minWeight = pSpectInfo[j+n].weight;
+ minIdx = n;
+ }
+ }
+
+ /* set all 4 channels to max value first, then reset the
+ best channel as the selected primary channel, update its
+ weightage with the combined weight value */
+ for (n=0; n<4; n++)
+ pSpectInfo[j+n].weight = ACS_WEIGHT_MAX;
+
+ pSpectInfo[j+minIdx].weight = acsHT80Channels[i].weight;
}
else
{
@@ -2018,10 +2033,22 @@ void sapSortChlWeightHT40(tSapChSelSpectInfo *pSpectInfoParams,
{
acsHT40Channels5G[i].weight = pSpectInfo[j].weight +
pSpectInfo[j+1].weight;
- pSpectInfo[j].weight = acsHT40Channels5G[i].weight;
- /* mark the adjacent channel's weight as max value so
- that it will be sorted to the bottom */
- pSpectInfo[j+1].weight = ACS_WEIGHT_MAX;
+ /* select better of the adjact channel as the primary channel */
+ if (pSpectInfo[j].weight <= pSpectInfo[j+1].weight)
+ {
+ pSpectInfo[j].weight = acsHT40Channels5G[i].weight;
+ /* mark the adjacent channel's weight as max value so
+ that it will be sorted to the bottom */
+ pSpectInfo[j+1].weight = ACS_WEIGHT_MAX;
+ }
+ else
+ {
+ pSpectInfo[j+1].weight = acsHT40Channels5G[i].weight;
+ /* mark the adjacent channel's weight as max value so
+ that it will be sorted to the bottom */
+ pSpectInfo[j].weight = ACS_WEIGHT_MAX;
+ }
+
}
else
pSpectInfo[j].weight = ACS_WEIGHT_MAX;
diff --git a/CORE/SERVICES/COMMON/adf/adf_os_mem.h b/CORE/SERVICES/COMMON/adf/adf_os_mem.h
index cdb969a67f48..672036240303 100644
--- a/CORE/SERVICES/COMMON/adf/adf_os_mem.h
+++ b/CORE/SERVICES/COMMON/adf/adf_os_mem.h
@@ -36,6 +36,13 @@
#include <adf_os_types.h>
#include <adf_os_mem_pvt.h>
+#ifdef CONFIG_WCNSS_MEM_PRE_ALLOC
+#ifdef CONFIG_CNSS
+#include <net/cnss.h>
+#else
+#include <wcnss_api.h>
+#endif
+#endif
/**
* @brief Allocate a memory buffer. Note this call can block.
@@ -47,6 +54,19 @@
static inline void *
adf_os_mem_alloc(adf_os_device_t osdev, adf_os_size_t size)
{
+#ifdef CONFIG_WCNSS_MEM_PRE_ALLOC
+ void *p_mem;
+#endif
+
+#ifdef CONFIG_WCNSS_MEM_PRE_ALLOC
+ if (size > WCNSS_PRE_ALLOC_GET_THRESHOLD)
+ {
+ p_mem = wcnss_prealloc_get(size);
+ if (NULL != p_mem)
+ return p_mem;
+ }
+#endif
+
return __adf_os_mem_alloc(osdev, size);
}
@@ -61,6 +81,13 @@ adf_os_mem_alloc_outline(adf_os_device_t osdev, adf_os_size_t size);
static inline void
adf_os_mem_free(void *buf)
{
+#ifdef CONFIG_WCNSS_MEM_PRE_ALLOC
+ if (wcnss_prealloc_put(buf))
+ {
+ return;
+ }
+#endif
+
__adf_os_mem_free(buf);
}
diff --git a/CORE/SERVICES/COMMON/hif_msg_based.h b/CORE/SERVICES/COMMON/hif_msg_based.h
index d4e87c71b6d2..c156ea6e9755 100644
--- a/CORE/SERVICES/COMMON/hif_msg_based.h
+++ b/CORE/SERVICES/COMMON/hif_msg_based.h
@@ -69,7 +69,7 @@ int HIF_deregister(void);
void HIFPostInit(HIF_DEVICE *hifDevice, void *hHTC, MSG_BASED_HIF_CALLBACKS *callbacks);
-void HIFStart(HIF_DEVICE *hifDevice);
+A_STATUS HIFStart(HIF_DEVICE *hifDevice);
void HIFStop(HIF_DEVICE *hifDevice);
void HIFFlushSurpriseRemove(HIF_DEVICE *hifDevice);
diff --git a/CORE/SERVICES/COMMON/osapi_linux.h b/CORE/SERVICES/COMMON/osapi_linux.h
index 63755bca5c42..79cfecc0d8f4 100644
--- a/CORE/SERVICES/COMMON/osapi_linux.h
+++ b/CORE/SERVICES/COMMON/osapi_linux.h
@@ -103,10 +103,10 @@ void a_meminfo_report(int clear);
#define A_NETIF_RX_NI(skb) do { a_meminfo_del(skb); netif_rx_ni(skb); } while (0)
#else
#define a_meminfo_report(_c)
-#define A_MALLOC(size) kmalloc((size), GFP_KERNEL)
+#define A_MALLOC(size) adf_os_mem_alloc(NULL, size)
#define A_MALLOC_NOWAIT(size) kmalloc((size), GFP_ATOMIC)
#define a_mem_trace(ptr)
-#define A_FREE(addr) kfree(addr)
+#define A_FREE(addr) adf_os_mem_free(addr)
#define A_NETIF_RX(skb) netif_rx(skb)
#define A_NETIF_RX_NI(skb) netif_rx_ni(skb)
#endif
diff --git a/CORE/SERVICES/COMMON/osdep_adf.h b/CORE/SERVICES/COMMON/osdep_adf.h
index 17111c846e9b..708b6f89fa03 100644
--- a/CORE/SERVICES/COMMON/osdep_adf.h
+++ b/CORE/SERVICES/COMMON/osdep_adf.h
@@ -543,9 +543,9 @@ struct _NIC_DEV {
static INLINE unsigned char *
OS_MALLOC(osdev_t pNicDev, unsigned long ulSizeInBytes, int gfp)
{
- return kmalloc(ulSizeInBytes, gfp);
+ return adf_os_mem_alloc(NULL, ulSizeInBytes);
}
-#define OS_FREE(_p) do { kfree(_p); _p = 0; } while (0)
+#define OS_FREE(_p) adf_os_mem_free(_p)
#define OS_MALLOC_WITH_TAG(_ppMem, _size, _tag) do { \
*(_ppMem) = adf_os_mem_alloc(NULL, _size); \
diff --git a/CORE/SERVICES/HIF/PCIe/hif_pci.c b/CORE/SERVICES/HIF/PCIe/hif_pci.c
index e4e739c54f3c..08672343ccc1 100644
--- a/CORE/SERVICES/HIF/PCIe/hif_pci.c
+++ b/CORE/SERVICES/HIF/PCIe/hif_pci.c
@@ -498,7 +498,7 @@ HIFPostInit(HIF_DEVICE *hif_device, void *unused, MSG_BASED_HIF_CALLBACKS *callb
AR_DEBUG_PRINTF(ATH_DEBUG_TRC, ("-%s\n",__FUNCTION__));
}
-void
+int
hif_completion_thread_startup(struct HIF_CE_state *hif_state)
{
struct CE_handle *ce_diag = hif_state->ce_diag;
@@ -545,7 +545,7 @@ hif_completion_thread_startup(struct HIF_CE_state *hif_state)
A_MALLOC(completions_needed * sizeof(struct HIF_CE_completion_state));
if (!compl_state) {
AR_DEBUG_PRINTF(ATH_DEBUG_ERR, ("ath ERROR: compl_state has no mem\n"));
- return;
+ return -1;
}
pipe_info->completion_space = compl_state;
@@ -565,6 +565,7 @@ hif_completion_thread_startup(struct HIF_CE_state *hif_state)
}
A_TARGET_ACCESS_UNLIKELY(targid);
+ return 0;
}
void
@@ -1374,14 +1375,15 @@ void HIFDump(HIF_DEVICE *hif_device, u_int8_t cmd_id, bool start)
}
}
-void
+A_STATUS
HIFStart(HIF_DEVICE *hif_device)
{
struct HIF_CE_state *hif_state = (struct HIF_CE_state *)hif_device;
AR_DEBUG_PRINTF(ATH_DEBUG_TRC, ("+%s\n",__FUNCTION__));
- hif_completion_thread_startup(hif_state);
+ if (hif_completion_thread_startup(hif_state))
+ return A_ERROR;
hif_msg_callbacks_install(hif_device);
@@ -1391,6 +1393,8 @@ HIFStart(HIF_DEVICE *hif_device)
hif_state->started = TRUE;
AR_DEBUG_PRINTF(ATH_DEBUG_TRC, ("-%s\n",__FUNCTION__));
+
+ return A_OK;
}
void
@@ -2008,9 +2012,11 @@ HIF_sleep_entry(void *arg)
idle_ms = adf_os_ticks_to_msecs(adf_os_ticks()
- hif_state->sleep_ticks);
if (idle_ms >= HIF_MIN_SLEEP_INACTIVITY_TIME_MS) {
- A_PCI_WRITE32(pci_addr + PCIE_LOCAL_BASE_ADDRESS +
+ if (!adf_os_atomic_read(&sc->pci_link_suspended)) {
+ A_PCI_WRITE32(pci_addr + PCIE_LOCAL_BASE_ADDRESS +
PCIE_SOC_WAKE_ADDRESS, PCIE_SOC_WAKE_RESET);
- hif_state->fake_sleep = FALSE;
+ hif_state->fake_sleep = FALSE;
+ }
} else {
adf_os_timer_start(&hif_state->sleep_timer,
HIF_SLEEP_INACTIVITY_TIMER_PERIOD_MS);
diff --git a/CORE/SERVICES/HIF/PCIe/if_pci.c b/CORE/SERVICES/HIF/PCIe/if_pci.c
index 1d233a383994..747ed9bd3f61 100644
--- a/CORE/SERVICES/HIF/PCIe/if_pci.c
+++ b/CORE/SERVICES/HIF/PCIe/if_pci.c
@@ -613,7 +613,8 @@ wlan_tasklet(unsigned long data)
}
irq_handled:
if (LEGACY_INTERRUPTS(sc) && (sc->ol_sc->target_status !=
- OL_TRGET_STATUS_RESET)) {
+ OL_TRGET_STATUS_RESET) &&
+ (!adf_os_atomic_read(&sc->pci_link_suspended))) {
if (sc->hif_init_done == TRUE)
A_TARGET_ACCESS_BEGIN(hif_state->targid);
@@ -882,6 +883,7 @@ again:
adf_os_atomic_init(&sc->tasklet_from_intr);
adf_os_atomic_init(&sc->wow_done);
adf_os_atomic_init(&sc->ce_suspend);
+ adf_os_atomic_init(&sc->pci_link_suspended);
init_waitqueue_head(&ol_sc->sc_osdev->event_queue);
init_completion(&ol_sc->ramdump_event);
@@ -1201,6 +1203,7 @@ again:
adf_os_atomic_init(&sc->tasklet_from_intr);
adf_os_atomic_init(&sc->wow_done);
adf_os_atomic_init(&sc->ce_suspend);
+ adf_os_atomic_init(&sc->pci_link_suspended);
init_waitqueue_head(&ol_sc->sc_osdev->event_queue);
init_completion(&ol_sc->ramdump_event);
@@ -1713,9 +1716,6 @@ hif_pci_suspend(struct pci_dev *pdev, pm_message_t state)
msleep(10);
}
- /* Stop the HIF Sleep Timer */
- HIFCancelDeferredTargetSleep(sc->hif_device);
-
/*Disable PCIe interrupts*/
A_TARGET_ACCESS_BEGIN_RET(targid);
A_PCI_WRITE32(sc->mem+(SOC_CORE_BASE_ADDRESS | PCIE_INTR_ENABLE_ADDRESS), 0);
@@ -1727,6 +1727,11 @@ hif_pci_suspend(struct pci_dev *pdev, pm_message_t state)
}
A_TARGET_ACCESS_END_RET(targid);
+ /* Stop the HIF Sleep Timer */
+ HIFCancelDeferredTargetSleep(sc->hif_device);
+
+ adf_os_atomic_set(&sc->pci_link_suspended, 1);
+
pci_read_config_dword(pdev, OL_ATH_PCI_PM_CONTROL, &val);
if ((val & 0x000000ff) != 0x3) {
pci_save_state(pdev);
@@ -1751,6 +1756,8 @@ hif_pci_resume(struct pci_dev *pdev)
v_VOID_t * temp_module;
u32 tmp;
+ adf_os_atomic_set(&sc->pci_link_suspended, 0);
+
/* Enable Legacy PCI line interrupts */
A_TARGET_ACCESS_BEGIN_RET(targid);
A_PCI_WRITE32(sc->mem+(SOC_CORE_BASE_ADDRESS | PCIE_INTR_ENABLE_ADDRESS),
diff --git a/CORE/SERVICES/HIF/PCIe/if_pci.h b/CORE/SERVICES/HIF/PCIe/if_pci.h
index 8114bc8b019b..a11ef830bea3 100644
--- a/CORE/SERVICES/HIF/PCIe/if_pci.h
+++ b/CORE/SERVICES/HIF/PCIe/if_pci.h
@@ -86,6 +86,7 @@ struct hif_pci_softc {
atomic_t tasklet_from_intr;
atomic_t wow_done;
atomic_t ce_suspend;
+ atomic_t pci_link_suspended;
bool hif_init_done;
bool recovery;
int htc_endpoint;
diff --git a/CORE/SERVICES/HTC/htc.c b/CORE/SERVICES/HTC/htc.c
index c12267c880e9..efe0167ace07 100644
--- a/CORE/SERVICES/HTC/htc.c
+++ b/CORE/SERVICES/HTC/htc.c
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2013 The Linux Foundation. All rights reserved.
+ * Copyright (c) 2013, 2014 The Linux Foundation. All rights reserved.
*
* Previously licensed under the ISC license by Qualcomm Atheros, Inc.
*
@@ -461,7 +461,11 @@ A_STATUS HTCWaitTarget(HTC_HANDLE HTCHandle)
do {
- HIFStart(target->hif_dev);
+ status = HIFStart(target->hif_dev);
+ if (A_FAILED(status)) {
+ AR_DEBUG_PRINTF(ATH_DEBUG_ERROR, ("HIFStart failed\n"));
+ break;
+ }
status = HTCWaitRecvCtrlMessage(target);
diff --git a/CORE/SERVICES/WMA/wma.c b/CORE/SERVICES/WMA/wma.c
index 0840e1fd72f1..eadcb3d16052 100644
--- a/CORE/SERVICES/WMA/wma.c
+++ b/CORE/SERVICES/WMA/wma.c
@@ -4374,6 +4374,7 @@ bool wma_check_scan_in_progress(WMA_HANDLE handle)
return false;
}
+
/* function : wma_get_buf_start_scan_cmd
* Descriptin :
* Args :
@@ -4442,26 +4443,41 @@ VOS_STATUS wma_get_buf_start_scan_cmd(tp_wma_handle wma_handle,
WMI_SCAN_EVENT_PREEMPTED |
WMI_SCAN_EVENT_RESTARTED;
+ /* CSR sends min and max dwell time values, but expects the firmware
+ * to use only max dwell time value. It does not send separate values
+ * for active and passive. We use the same value for now.
+ * CSR will pass 40 or 110 ms as maxChannelTime value to us.
+ */
cmd->dwell_time_active = scan_req->maxChannelTime;
cmd->dwell_time_passive = scan_req->maxChannelTime;
+ /* Ensure correct number of probes are sent on active channel */
+ cmd->repeat_probe_time = cmd->dwell_time_active / WMA_SCAN_NPROBES_DEFAULT;
+
+ /* CSR sends only one value restTime for staying on home channel
+ * to continue data traffic. Rome fw has facility to monitor the traffic
+ * and move to next channel. Stay on the channel for at least half
+ * of the requested time and then leave if there is no traffic.
+ */
+ cmd->min_rest_time = scan_req->restTime / 2;
+ cmd->max_rest_time = scan_req->restTime;
+
+ /* Check for traffic at idle_time interval after min_rest_time.
+ * Default value is 25 ms to allow full use of max_rest_time
+ * when voice packets are running at 20 ms interval.
+ */
+ cmd->idle_time = WMA_SCAN_IDLE_TIME_DEFAULT;
+
+ /* Large timeout value for full scan cycle, 30 seconds */
cmd->max_scan_time = WMA_HW_DEF_SCAN_MAX_DURATION;
+
cmd->scan_ctrl_flags |= WMI_SCAN_ADD_OFDM_RATES;
- if (scan_req->scanType == eSIR_PASSIVE_SCAN)
- cmd->burst_duration = 0;
- else {
- if (scan_req->channelList.numChannels <
- WMA_BURST_SCAN_MAX_NUM_OFFCHANNELS) {
- cmd->burst_duration =
- scan_req->channelList.numChannels *
- scan_req->maxChannelTime;
- } else {
- cmd->burst_duration =
- WMA_BURST_SCAN_MAX_NUM_OFFCHANNELS *
- scan_req->maxChannelTime;
- }
- }
+ /* Do not combine multiple channels in a single burst. Come back
+ * to home channel for data traffic after every foreign channel.
+ * By default, prefer throughput performance over scan cycle time.
+ */
+ cmd->burst_duration = 0;
if (!scan_req->p2pScanType) {
WMA_LOGD("Normal Scan request");
@@ -4471,7 +4487,6 @@ VOS_STATUS wma_get_buf_start_scan_cmd(tp_wma_handle wma_handle,
if (scan_req->scanType == eSIR_PASSIVE_SCAN)
cmd->scan_ctrl_flags |= WMI_SCAN_FLAG_PASSIVE;
cmd->scan_ctrl_flags |= WMI_SCAN_FILTER_PROBE_REQ;
- cmd->repeat_probe_time = scan_req->maxChannelTime/3;
}
else {
WMA_LOGD("P2P Scan");
@@ -4487,6 +4502,10 @@ VOS_STATUS wma_get_buf_start_scan_cmd(tp_wma_handle wma_handle,
WMA_LOGD("P2P_SCAN_TYPE_SEARCH");
cmd->scan_ctrl_flags |= WMI_SCAN_FILTER_PROBE_REQ;
cmd->repeat_probe_time = scan_req->maxChannelTime/3;
+ /* Default P2P burst duration of 120 ms will cover
+ * 3 channels with default max dwell time 40 ms.
+ */
+ cmd->burst_duration = WMA_P2P_SCAN_MAX_BURST_DURATION;
break;
default:
WMA_LOGE("Invalid scan type");
diff --git a/CORE/SERVICES/WMA/wma.h b/CORE/SERVICES/WMA/wma.h
index ae3cd8fad4c0..c18d3033158f 100644
--- a/CORE/SERVICES/WMA/wma.h
+++ b/CORE/SERVICES/WMA/wma.h
@@ -139,7 +139,10 @@
#define WMA_HW_DEF_SCAN_MAX_DURATION 30000 /* 30 secs */
/* Max offchannel duration */
-#define WMA_BURST_SCAN_MAX_NUM_OFFCHANNELS 5
+#define WMA_BURST_SCAN_MAX_NUM_OFFCHANNELS (5)
+#define WMA_SCAN_NPROBES_DEFAULT (2)
+#define WMA_SCAN_IDLE_TIME_DEFAULT (25)
+#define WMA_P2P_SCAN_MAX_BURST_DURATION (120)
/* Roaming default values
* All time and period values are in milliseconds.
diff --git a/CORE/SME/src/csr/csrApiScan.c b/CORE/SME/src/csr/csrApiScan.c
index 50f28cf64f28..3375810f6493 100644
--- a/CORE/SME/src/csr/csrApiScan.c
+++ b/CORE/SME/src/csr/csrApiScan.c
@@ -5673,7 +5673,7 @@ eHalStatus csrSendMBScanReq( tpAniSirGlobal pMac, tANI_U16 sessionId,
//hidden SSID option
pMsg->hiddenSsid = pScanReqParam->hiddenSsid;
//rest time
- //pMsg->restTime = pScanReq->restTime;
+ pMsg->restTime = pScanReq->restTime;
pMsg->returnAfterFirstMatch = pScanReqParam->bReturnAfter1stMatch;
// All the scan results caching will be done by Roaming
// We do not want LIM to do any caching of scan results,
diff --git a/CORE/VOSS/inc/wcnss_api.h b/CORE/VOSS/inc/wcnss_api.h
index 24a660e6acf1..7dd304bacb6f 100644
--- a/CORE/VOSS/inc/wcnss_api.h
+++ b/CORE/VOSS/inc/wcnss_api.h
@@ -137,16 +137,6 @@ static inline int free_riva_power_on_lock(char *driver_name)
return 0;
}
-#ifdef CONFIG_WCNSS_MEM_PRE_ALLOC
-static inline void *wcnss_prealloc_get(size_t size)
-{
- return NULL;
-}
-static inline int wcnss_prealloc_put(void *ptr)
-{
- return 0;
-}
-#endif
#endif /* #ifdef QCA_WIFI_ISOC */
#endif /* #ifndef _WCNSS_API_H_ */
diff --git a/CORE/VOSS/src/vos_memory.c b/CORE/VOSS/src/vos_memory.c
index a85fdff1c32a..2566fb057a7c 100644
--- a/CORE/VOSS/src/vos_memory.c
+++ b/CORE/VOSS/src/vos_memory.c
@@ -55,9 +55,13 @@
#include "vos_trace.h"
#ifdef CONFIG_WCNSS_MEM_PRE_ALLOC
+#ifdef CONFIG_CNSS
+#include <net/cnss.h>
+#else
#include <wcnss_api.h>
-#define WCNSS_PRE_ALLOC_GET_THRESHOLD (4*1024)
#endif
+#endif
+
#ifdef MEMORY_DEBUG
#include "wlan_hdd_dp_utils.h"