From 64bfe9741529fc88896b59212b5692d9a9881d02 Mon Sep 17 00:00:00 2001 From: Deepak Dhamdhere Date: Wed, 14 Jun 2017 18:04:53 -0700 Subject: [PATCH 01/34] qcacld-3.0: Schedule work for peer_unmap_timer_handler actions Mutex cannot be used when peer_unmap_timer_handler() calls cds_trigger_recover() because it runs in soft_irq. Schedule work to perform the recovery instead. CRs-Fixed: 2060775 Change-Id: I9a9554ef0aa9288bf5abe22cd2513d8cc41c29d4 --- core/dp/txrx/ol_txrx.c | 29 ++++++++++++++++++++++++----- core/dp/txrx/ol_txrx.h | 1 + core/dp/txrx/ol_txrx_types.h | 1 + 3 files changed, 26 insertions(+), 5 deletions(-) diff --git a/core/dp/txrx/ol_txrx.c b/core/dp/txrx/ol_txrx.c index fa33c2f4dcc2..b9841269ce66 100644 --- a/core/dp/txrx/ol_txrx.c +++ b/core/dp/txrx/ol_txrx.c @@ -3333,8 +3333,26 @@ static QDF_STATUS ol_txrx_clear_peer(struct cdp_pdev *ppdev, uint8_t sta_id) } +void peer_unmap_timer_work_function(void *param) +{ + WMA_LOGE("Enter: %s", __func__); + /* + * wma_peer_debug_dump() will be replaced with a new routine. + * Add the equivalent of wma_peer_debug_dump() when available. + */ + if (cds_is_self_recovery_enabled()) { + if (!cds_is_driver_recovering()) + cds_trigger_recovery(false); + else + WMA_LOGE("%s: Recovery is in progress, ignore!", + __func__); + } else { + QDF_BUG(0); + } +} + /** - * peer_unmap_timer() - peer unmap timer function + * peer_unmap_timer_handler() - peer unmap timer function * @data: peer object pointer * * Return: none @@ -3342,6 +3360,7 @@ static QDF_STATUS ol_txrx_clear_peer(struct cdp_pdev *ppdev, uint8_t sta_id) void peer_unmap_timer_handler(void *data) { ol_txrx_peer_handle peer = (ol_txrx_peer_handle)data; + ol_txrx_pdev_handle txrx_pdev = cds_get_context(QDF_MODULE_ID_TXRX); ol_txrx_err("all unmap events not received for peer %p, ref_cnt %d", peer, qdf_atomic_read(&peer->ref_cnt)); @@ -3351,10 +3370,10 @@ void peer_unmap_timer_handler(void *data) peer->mac_addr.raw[2], peer->mac_addr.raw[3], peer->mac_addr.raw[4], peer->mac_addr.raw[5]); if (!cds_is_driver_recovering()) { - /* - * Add the equivalent of wma_peer_debug_dump() when available. - */ - QDF_BUG(0); + qdf_create_work(0, &txrx_pdev->peer_unmap_timer_work, + peer_unmap_timer_work_function, + NULL); + qdf_sched_work(0, &txrx_pdev->peer_unmap_timer_work); } else { ol_txrx_err("Recovery is in progress, ignore!"); } diff --git a/core/dp/txrx/ol_txrx.h b/core/dp/txrx/ol_txrx.h index 2ebcf00903c0..f4c992743172 100644 --- a/core/dp/txrx/ol_txrx.h +++ b/core/dp/txrx/ol_txrx.h @@ -128,6 +128,7 @@ void *ol_txrx_find_peer_by_addr(struct cdp_pdev *pdev, uint8_t *peer_id); void htt_pkt_log_init(struct cdp_pdev *pdev_handle, void *scn); +void peer_unmap_timer_work_function(void *); void peer_unmap_timer_handler(void *data); #endif /* _OL_TXRX__H_ */ diff --git a/core/dp/txrx/ol_txrx_types.h b/core/dp/txrx/ol_txrx_types.h index 050818ffda28..91a7c9933784 100644 --- a/core/dp/txrx/ol_txrx_types.h +++ b/core/dp/txrx/ol_txrx_types.h @@ -974,6 +974,7 @@ struct ol_txrx_pdev_t { qdf_atomic_t lro_dev_cnt; } lro_info; struct ol_txrx_peer_t *self_peer; + qdf_work_t peer_unmap_timer_work; }; struct ol_txrx_vdev_t { From 12a960213e228d124f619c9a9cafe65cfa413449 Mon Sep 17 00:00:00 2001 From: Dustin Brown Date: Wed, 12 Jul 2017 10:34:50 -0700 Subject: [PATCH 02/34] qcacld-3.0: Populate stats_mask when requesting stats wma_get_stats_req does not populate the requested statistics bitmask before forwarding the request to WMI. Popluate the given statistics bitmask into the WMI request in wma_get_stats_req, so firmware can provide the desired statistics. Change-Id: I6dbf7bf1fb2cf6b20bcd4f2fb91f9add5dd3d779 CRs-Fixed: 2075379 --- core/wma/src/wma_utils.c | 1 + 1 file changed, 1 insertion(+) diff --git a/core/wma/src/wma_utils.c b/core/wma/src/wma_utils.c index 1f7e3071ba55..4959f461a71a 100644 --- a/core/wma/src/wma_utils.c +++ b/core/wma/src/wma_utils.c @@ -3637,6 +3637,7 @@ void wma_get_stats_req(WMA_HANDLE handle, node->stats_rsp->statsMask, get_stats_param->sessionId); cmd.session_id = get_stats_param->sessionId; + cmd.stats_mask = get_stats_param->statsMask; if (wmi_unified_get_stats_cmd(wma_handle->wmi_handle, &cmd, node->bssid)) { From 65e2e8d0729b6dd77ba15e571bf823d18954c701 Mon Sep 17 00:00:00 2001 From: Zhang Qian Date: Tue, 11 Jul 2017 11:56:43 +0800 Subject: [PATCH 03/34] qcacld-3.0: Add sap operation mode to MAC global context SAP operation mode is not updated to MAC global context once user layer APP updates STA roaming policy. This will make unsafe channel ignoring ineffective. Change-Id: I5727e950e2097d55daf6745b4f443b89cc681dc8 CRs-Fixed: 2074237 --- core/sme/src/csr/csr_api_roam.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/core/sme/src/csr/csr_api_roam.c b/core/sme/src/csr/csr_api_roam.c index 57ffd9130bfc..5add7df3a96d 100644 --- a/core/sme/src/csr/csr_api_roam.c +++ b/core/sme/src/csr/csr_api_roam.c @@ -2775,6 +2775,8 @@ QDF_STATUS csr_change_default_config_param(tpAniSirGlobal pMac, pParam->sta_roam_policy_params.dfs_mode; pMac->roam.configParam.sta_roam_policy.skip_unsafe_channels = pParam->sta_roam_policy_params.skip_unsafe_channels; + pMac->roam.configParam.sta_roam_policy.sap_operating_band = + pParam->sta_roam_policy_params.sap_operating_band; pMac->roam.configParam.tx_aggregation_size = pParam->tx_aggregation_size; From 06488011408f898989fea8912b357d3c62b45196 Mon Sep 17 00:00:00 2001 From: Varun Reddy Yeturu Date: Thu, 25 May 2017 11:44:10 -0700 Subject: [PATCH 04/34] qcacld-3.0: Do not send RSO Stop when roam sync is in progress Avoid sending a RSO stop because of a disconnect when roam sync is in progress. It is not needed to send a RSO stop since the host would eventually trigger a disconnect and send down an RSO stop anyways. Sending a RSO stop woould lead to unnecessary complication where the firmware would send a HO_FAIL and then this would be queued and the host disconnect would be handled first and as part of processing the user disconnect, a peer delete would be sent down to firmware, which has already been cleaned up by the firmware earlier. Change-Id: Ic89f97308c3d63977dda61fcadc450432fb16524 CRs-Fixed: 2052449 --- core/wma/src/wma_scan_roam.c | 30 +++++++++++++++++++++++++++++- 1 file changed, 29 insertions(+), 1 deletion(-) diff --git a/core/wma/src/wma_scan_roam.c b/core/wma/src/wma_scan_roam.c index f9e35bad52dd..ce4fb7e60f7a 100644 --- a/core/wma/src/wma_scan_roam.c +++ b/core/wma/src/wma_scan_roam.c @@ -1846,6 +1846,33 @@ QDF_STATUS wma_process_roaming_config(tp_wma_handle wma_handle, break; case ROAM_SCAN_OFFLOAD_STOP: + /* + * If roam synch propagation is in progress and an user space + * disconnect is requested, then there is no need to send the + * RSO STOP to firmware, since the roaming is already complete. + * If the RSO STOP is sent to firmware, then an HO_FAIL will be + * generated and the expectation from firmware would be to + * clean up the peer context on the host and not send down any + * WMI PEER DELETE commands to firmware. But, if the user space + * disconnect gets processed first, then there is a chance to + * send down the PEER DELETE commands. Hence, if we do not + * receive the HO_FAIL, and we complete the roam sync + * propagation, then the host and firmware will be in sync with + * respect to the peer and then the user space disconnect can + * be handled gracefully in a normal way. + * + * Ensure to check the reason code since the RSO Stop might + * come when roam sync failed as well and at that point it + * should go through to the firmware and receive HO_FAIL + * and clean up. + */ + if (wma_is_roam_synch_in_progress(wma_handle, + roam_req->sessionId) && + roam_req->reason == + REASON_ROAM_STOP_ALL) { + WMA_LOGD("Dont send RSO stop during roam sync"); + break; + } wma_handle->suitable_ap_hb_failure = false; if (wma_handle->roam_offload_enabled) { uint32_t mode; @@ -2416,9 +2443,10 @@ cleanup_label: wma->csr_roam_synch_cb((tpAniSirGlobal)wma->mac_context, roam_synch_ind_ptr, NULL, SIR_ROAMING_ABORT); roam_req = qdf_mem_malloc(sizeof(tSirRoamOffloadScanReq)); - if (roam_req) { + if (roam_req && synch_event) { roam_req->Command = ROAM_SCAN_OFFLOAD_STOP; roam_req->reason = REASON_ROAM_SYNCH_FAILED; + roam_req->sessionId = synch_event->vdev_id; wma_process_roaming_config(wma, roam_req); } } From 421838aae675abefd1aabf652ede010885fda364 Mon Sep 17 00:00:00 2001 From: snandini Date: Mon, 17 Jul 2017 17:39:00 -0700 Subject: [PATCH 05/34] Release 5.2.0.35 Release 5.2.0.35 Change-Id: I2f0bc975e4ac5432fb265f0086585b800d87765a CRs-Fixed: 774533 --- core/mac/inc/qwlan_version.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/core/mac/inc/qwlan_version.h b/core/mac/inc/qwlan_version.h index 565e0091e441..bbcf7566aeeb 100644 --- a/core/mac/inc/qwlan_version.h +++ b/core/mac/inc/qwlan_version.h @@ -41,9 +41,9 @@ #define QWLAN_VERSION_MAJOR 5 #define QWLAN_VERSION_MINOR 2 #define QWLAN_VERSION_PATCH 0 -#define QWLAN_VERSION_EXTRA "Z" -#define QWLAN_VERSION_BUILD 34 +#define QWLAN_VERSION_EXTRA "" +#define QWLAN_VERSION_BUILD 35 -#define QWLAN_VERSIONSTR "5.2.0.34Z" +#define QWLAN_VERSIONSTR "5.2.0.35" #endif /* QWLAN_VERSION_H */ From 3545e64d4aaaef192976c6934d3e33398cb6cbda Mon Sep 17 00:00:00 2001 From: Wu Gao Date: Fri, 14 Jul 2017 19:24:41 +0800 Subject: [PATCH 06/34] qcacld-3.0: Cleanup DFS CAC timer when SSR and reset all adapters In SAP and SSR case, it won't cleanup DFS CAC timer until up layer kill hostapd. It will call wlansap close when hostapd exit. If enable sap internal restart in this case, it will double init DFS CAC timer, which cause abnormal in kernel. Solution is cleanup DFS CAC timer when reset all adapters. Change-Id: I96962349af548074e226976c8c01cd5a8710ed3f CRs-fixed: 2075904 --- core/hdd/src/wlan_hdd_main.c | 14 +++++++++----- core/sap/inc/sap_api.h | 12 ++++++++++++ core/sap/src/sap_module.c | 23 +++++++++++++++++++++++ 3 files changed, 44 insertions(+), 5 deletions(-) diff --git a/core/hdd/src/wlan_hdd_main.c b/core/hdd/src/wlan_hdd_main.c index 9807393bc68e..157defa6d0eb 100644 --- a/core/hdd/src/wlan_hdd_main.c +++ b/core/hdd/src/wlan_hdd_main.c @@ -4316,14 +4316,18 @@ QDF_STATUS hdd_reset_all_adapters(hdd_context_t *hdd_ctx) clear_bit(WMM_INIT_DONE, &adapter->event_flags); } - /* - * If adapter is SAP, set session ID to invalid since SAP - * session will be cleanup during SSR. - */ - if (adapter->device_mode == QDF_SAP_MODE) + if (adapter->device_mode == QDF_SAP_MODE) { + /* + * If adapter is SAP, set session ID to invalid + * since SAP session will be cleanup during SSR. + */ wlansap_set_invalid_session( WLAN_HDD_GET_SAP_CTX_PTR(adapter)); + wlansap_cleanup_cac_timer( + WLAN_HDD_GET_SAP_CTX_PTR(adapter)); + } + /* Delete peers if any for STA and P2P client modes */ if (adapter->device_mode == QDF_STA_MODE || adapter->device_mode == QDF_P2P_CLIENT_MODE) { diff --git a/core/sap/inc/sap_api.h b/core/sap/inc/sap_api.h index c3eb015cc873..e6cd4932b965 100644 --- a/core/sap/inc/sap_api.h +++ b/core/sap/inc/sap_api.h @@ -1055,6 +1055,18 @@ QDF_STATUS wlansap_set_invalid_session(void *cds_ctx); * Return: None */ void sap_dfs_set_current_channel(void *sap_ctx); + +/** + * wlansap_cleanup_cac_timer() - Force cleanup DFS CAC timer + * @sap_ctx: sap context + * + * Force cleanup DFS CAC timer when reset all adapters. It will not + * check concurrency SAP since just called when reset all adapters. + * + * Return: None + */ +void wlansap_cleanup_cac_timer(void *sap_ctx); + #ifdef __cplusplus } #endif diff --git a/core/sap/src/sap_module.c b/core/sap/src/sap_module.c index 55d2e24fd68a..2c810ea32cab 100644 --- a/core/sap/src/sap_module.c +++ b/core/sap/src/sap_module.c @@ -3745,3 +3745,26 @@ wlansap_set_invalid_session(void *cds_ctx) return QDF_STATUS_SUCCESS; } + +void wlansap_cleanup_cac_timer(void *sap_ctx) +{ + tHalHandle hal; + ptSapContext psap_ctx; + tpAniSirGlobal pmac; + + if (!sap_ctx) + return; + + psap_ctx = CDS_GET_SAP_CB(sap_ctx); + hal = CDS_GET_HAL_CB(psap_ctx->p_cds_gctx); + pmac = PMAC_STRUCT(hal); + if (pmac->sap.SapDfsInfo.is_dfs_cac_timer_running) { + qdf_mc_timer_stop(&pmac->sap.SapDfsInfo. + sap_dfs_cac_timer); + pmac->sap.SapDfsInfo.is_dfs_cac_timer_running = 0; + qdf_mc_timer_destroy( + &pmac->sap.SapDfsInfo.sap_dfs_cac_timer); + QDF_TRACE(QDF_MODULE_ID_SAP, QDF_TRACE_LEVEL_ERROR, + FL("sapdfs, force cleanup running dfs cac timer")); + } +} From 48701e295f4677f53ad0abab0557f5fa217a4373 Mon Sep 17 00:00:00 2001 From: Will Huang Date: Fri, 14 Jul 2017 13:13:19 +0800 Subject: [PATCH 07/34] qcacld-3.0: Move short name redefinitions from qca_vendor.h These short name redefinitions should just be used in source file for convenience, should not exist in qca_vendor.h where interfaces are defined there. To avoid checkin two way dependencies, add ifndef/define in source file and first checkin qcacmn head file which remove these redefinitions, then remove these ifndef/define from source file in another change. Change-Id: I5318de88b569085f26212e960b79048e8a2481a8 CRs-Fixed: 2076521 --- core/hdd/src/wlan_hdd_cfg80211.c | 38 ++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) diff --git a/core/hdd/src/wlan_hdd_cfg80211.c b/core/hdd/src/wlan_hdd_cfg80211.c index 2d06abe1460f..5515f07dbaeb 100644 --- a/core/hdd/src/wlan_hdd_cfg80211.c +++ b/core/hdd/src/wlan_hdd_cfg80211.c @@ -112,6 +112,44 @@ #include "wlan_utility.h" #include "wlan_reg_ucfg_api.h" +/* define short names for get station info attributes */ +#ifndef LINK_INFO_STANDARD_NL80211_ATTR +#define LINK_INFO_STANDARD_NL80211_ATTR \ + QCA_WLAN_VENDOR_ATTR_GET_STATION_INFO_LINK_STANDARD_NL80211_ATTR +#endif +#ifndef AP_INFO_STANDARD_NL80211_ATTR +#define AP_INFO_STANDARD_NL80211_ATTR \ + QCA_WLAN_VENDOR_ATTR_GET_STATION_INFO_AP_STANDARD_NL80211_ATTR +#endif +#ifndef INFO_ROAM_COUNT +#define INFO_ROAM_COUNT \ + QCA_WLAN_VENDOR_ATTR_GET_STATION_INFO_ROAM_COUNT +#endif +#ifndef INFO_AKM +#define INFO_AKM \ + QCA_WLAN_VENDOR_ATTR_GET_STATION_INFO_AKM +#endif +#ifndef WLAN802_11_MODE +#define WLAN802_11_MODE \ + QCA_WLAN_VENDOR_ATTR_GET_STATION_INFO_802_11_MODE +#endif +#ifndef AP_INFO_HS20_INDICATION +#define AP_INFO_HS20_INDICATION \ + QCA_WLAN_VENDOR_ATTR_GET_STATION_INFO_AP_HS20_INDICATION +#endif +#ifndef HT_OPERATION +#define HT_OPERATION \ + QCA_WLAN_VENDOR_ATTR_GET_STATION_INFO_HT_OPERATION +#endif +#ifndef VHT_OPERATION +#define VHT_OPERATION \ + QCA_WLAN_VENDOR_ATTR_GET_STATION_INFO_VHT_OPERATION +#endif +#ifndef INFO_ASSOC_FAIL_REASON +#define INFO_ASSOC_FAIL_REASON \ + QCA_WLAN_VENDOR_ATTR_GET_STATION_INFO_ASSOC_FAIL_REASON +#endif + #define g_mode_rates_size (12) #define a_mode_rates_size (8) #define GET_IE_LEN_IN_BSS_DESC(lenInBss) (lenInBss + sizeof(lenInBss) - \ From 9c9e34211dbecb314c43b0291335d5b61145aef3 Mon Sep 17 00:00:00 2001 From: snandini Date: Mon, 17 Jul 2017 18:29:15 -0700 Subject: [PATCH 08/34] Release 5.2.0.35A Release 5.2.0.35A Change-Id: I46f1e1103bdaea51e6724ba4a1eb1b3389ce2a90 CRs-Fixed: 774533 --- core/mac/inc/qwlan_version.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/core/mac/inc/qwlan_version.h b/core/mac/inc/qwlan_version.h index bbcf7566aeeb..074fd37c3ae5 100644 --- a/core/mac/inc/qwlan_version.h +++ b/core/mac/inc/qwlan_version.h @@ -41,9 +41,9 @@ #define QWLAN_VERSION_MAJOR 5 #define QWLAN_VERSION_MINOR 2 #define QWLAN_VERSION_PATCH 0 -#define QWLAN_VERSION_EXTRA "" +#define QWLAN_VERSION_EXTRA "A" #define QWLAN_VERSION_BUILD 35 -#define QWLAN_VERSIONSTR "5.2.0.35" +#define QWLAN_VERSIONSTR "5.2.0.35A" #endif /* QWLAN_VERSION_H */ From 9e0032c720c50735f52e474ff12c29c97ca8a507 Mon Sep 17 00:00:00 2001 From: Varun Reddy Yeturu Date: Wed, 12 Jul 2017 18:39:59 -0700 Subject: [PATCH 09/34] qcacld-3.0: Use API to change the connection state Use the API hdd_conn_set_connection_state to change the HDD connection state Change-Id: I3635cec841a3788c9576e8e49ab859e21d89e32d CRs-Fixed: 2076017 --- core/hdd/src/wlan_hdd_assoc.c | 37 ++++++++++++++-------------- core/hdd/src/wlan_hdd_cfg80211.c | 3 ++- core/hdd/src/wlan_hdd_main.c | 5 +--- core/hdd/src/wlan_hdd_nan_datapath.c | 5 ++-- 4 files changed, 24 insertions(+), 26 deletions(-) diff --git a/core/hdd/src/wlan_hdd_assoc.c b/core/hdd/src/wlan_hdd_assoc.c index f24a80faead2..74a2fe80f68f 100644 --- a/core/hdd/src/wlan_hdd_assoc.c +++ b/core/hdd/src/wlan_hdd_assoc.c @@ -165,31 +165,30 @@ hdd_conn_set_authenticated(hdd_adapter_t *pAdapter, uint8_t authState) /** * hdd_conn_set_connection_state() - set connection state - * @pAdapter: pointer to the adapter - * @connState: connection state + * @adapter: pointer to the adapter + * @conn_state: connection state * * This function updates the global HDD station context connection state. * * Return: none */ -void hdd_conn_set_connection_state(hdd_adapter_t *pAdapter, - eConnectionState connState) +void hdd_conn_set_connection_state(hdd_adapter_t *adapter, + eConnectionState conn_state) { - hdd_station_ctx_t *pHddStaCtx = WLAN_HDD_GET_STATION_CTX_PTR(pAdapter); - hdd_context_t *pHddCtx = WLAN_HDD_GET_CTX(pAdapter); + hdd_station_ctx_t *hdd_sta_ctx = WLAN_HDD_GET_STATION_CTX_PTR(adapter); + hdd_context_t *hdd_ctx = WLAN_HDD_GET_CTX(adapter); /* save the new connection state */ - hdd_debug("%pS Changed connectionState Changed from oldState:%d to State:%d", - (void *)_RET_IP_, pHddStaCtx->conn_info.connState, - connState); + hdd_debug("%pS Changed conn state from old:%d to new:%d for dev %s", + (void *)_RET_IP_, hdd_sta_ctx->conn_info.connState, + conn_state, adapter->dev->name); - hdd_tsf_notify_wlan_state_change(pAdapter, - pHddStaCtx->conn_info.connState, - connState); - pHddStaCtx->conn_info.connState = connState; + hdd_tsf_notify_wlan_state_change(adapter, + hdd_sta_ctx->conn_info.connState, + conn_state); + hdd_sta_ctx->conn_info.connState = conn_state; - /* Check is pending ROC request or not when connection state changed */ - schedule_delayed_work(&pHddCtx->roc_req_work, 0); + schedule_delayed_work(&hdd_ctx->roc_req_work, 0); } /** @@ -2474,7 +2473,9 @@ static QDF_STATUS hdd_association_completion_handler(hdd_adapter_t *pAdapter, pHddStaCtx->conn_info.connState)) && ((eCSR_ROAM_RESULT_ASSOCIATED == roamResult) || (eCSR_ROAM_ASSOCIATION_FAILURE == roamStatus))) { - hdd_info("Disconnect from HDD in progress"); + hdd_info("hddDisconInProgress state=%d, result=%d, status=%d", + pHddStaCtx->conn_info.connState, + roamResult, roamStatus); hddDisconInProgress = true; } @@ -3350,8 +3351,8 @@ static bool roam_remove_ibss_station(hdd_adapter_t *pAdapter, uint8_t staId) if (MAX_PEERS == empty_slots) { /* Last peer departed, set the IBSS state appropriately */ - pHddStaCtx->conn_info.connState = - eConnectionState_IbssDisconnected; + hdd_conn_set_connection_state(pAdapter, + eConnectionState_IbssDisconnected); hdd_debug("Last IBSS Peer Departed!!!"); } /* Find next active staId, to have a valid sta trigger for TL. */ diff --git a/core/hdd/src/wlan_hdd_cfg80211.c b/core/hdd/src/wlan_hdd_cfg80211.c index 5515f07dbaeb..b569c3cad84e 100644 --- a/core/hdd/src/wlan_hdd_cfg80211.c +++ b/core/hdd/src/wlan_hdd_cfg80211.c @@ -15491,7 +15491,8 @@ static int wlan_hdd_disconnect(hdd_adapter_t *pAdapter, u16 reason) wlan_hdd_netif_queue_control(pAdapter, WLAN_STOP_ALL_NETIF_QUEUE_N_CARRIER, WLAN_CONTROL_PATH); hdd_debug("Set HDD connState to eConnectionState_Disconnecting"); - pHddStaCtx->conn_info.connState = eConnectionState_Disconnecting; + hdd_conn_set_connection_state(pAdapter, eConnectionState_Disconnecting); + INIT_COMPLETION(pAdapter->disconnect_comp_var); /* issue disconnect */ diff --git a/core/hdd/src/wlan_hdd_main.c b/core/hdd/src/wlan_hdd_main.c index 157defa6d0eb..c8e032251e8a 100644 --- a/core/hdd/src/wlan_hdd_main.c +++ b/core/hdd/src/wlan_hdd_main.c @@ -3196,10 +3196,7 @@ QDF_STATUS hdd_init_station_mode(hdd_adapter_t *adapter) hdd_err("failed to register wireless extensions: %d", status); goto error_register_wext; } - - /* Set the Connection State to Not Connected */ - hdd_debug("Set HDD connState to eConnectionState_NotConnected"); - pHddStaCtx->conn_info.connState = eConnectionState_NotConnected; + hdd_conn_set_connection_state(adapter, eConnectionState_NotConnected); qdf_mem_set(pHddStaCtx->conn_info.staId, sizeof(pHddStaCtx->conn_info.staId), HDD_WLAN_INVALID_STA_ID); diff --git a/core/hdd/src/wlan_hdd_nan_datapath.c b/core/hdd/src/wlan_hdd_nan_datapath.c index 16eed61348c7..23eae3c843ca 100644 --- a/core/hdd/src/wlan_hdd_nan_datapath.c +++ b/core/hdd/src/wlan_hdd_nan_datapath.c @@ -1251,8 +1251,8 @@ static void hdd_ndp_new_peer_ind_handler(hdd_adapter_t *adapter, hdd_ctx->sta_to_adapter[new_peer_ind->sta_id] = adapter; /* perform following steps for first new peer ind */ if (ndp_ctx->active_ndp_peers == 1) { - hdd_info("Set ctx connection state to connected"); - sta_ctx->conn_info.connState = eConnectionState_NdiConnected; + hdd_conn_set_connection_state(adapter, + eConnectionState_NdiConnected); hdd_wmm_connect(adapter, &roam_info, eCSR_BSS_TYPE_NDI); wlan_hdd_netif_queue_control(adapter, WLAN_WAKE_ALL_NETIF_QUEUE, WLAN_CONTROL_PATH); @@ -1281,7 +1281,6 @@ static void hdd_ndp_peer_departed_ind_handler(hdd_adapter_t *adapter, if (--ndp_ctx->active_ndp_peers == 0) { hdd_info("No more ndp peers."); - sta_ctx->conn_info.connState = eConnectionState_NdiDisconnected; hdd_conn_set_connection_state(adapter, eConnectionState_NdiDisconnected); hdd_info("Stop netif tx queues."); From 7c5fd6877a6e295b81e32c0db98e9313a9f58372 Mon Sep 17 00:00:00 2001 From: Srinivas Girigowda Date: Fri, 14 Jul 2017 12:59:51 -0700 Subject: [PATCH 10/34] qcacld-3.0: Remove CONFIG_ from CONFIG_INET_LRO in Kconfig Kernel, by default prepends "CONFIG_", hence Remove CONFIG_ from CONFIG_INET_LRO. Change-Id: I9bfec30e1814d8f3b7875a8a8926e251dd282441 CRs-Fixed: 2076950 --- Kconfig | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Kconfig b/Kconfig index 6536ec753bb5..f8feafca0e66 100644 --- a/Kconfig +++ b/Kconfig @@ -105,7 +105,7 @@ config WLAN_TX_FLOW_CONTROL_V2 config WLAN_LRO bool "Enable Large Receive Offload" depends on HELIUMPLUS - depends on CONFIG_INET_LRO + depends on INET_LRO default n config WLAN_SYNC_TSF From d0072c5516a41fff08f5e619420caf53528efc8e Mon Sep 17 00:00:00 2001 From: snandini Date: Mon, 17 Jul 2017 20:05:16 -0700 Subject: [PATCH 11/34] Release 5.2.0.35B Release 5.2.0.35B Change-Id: I9e5594851d10f1fda5274f6a638b5d6a7f7494d6 CRs-Fixed: 774533 --- core/mac/inc/qwlan_version.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/core/mac/inc/qwlan_version.h b/core/mac/inc/qwlan_version.h index 074fd37c3ae5..42a6b78a6288 100644 --- a/core/mac/inc/qwlan_version.h +++ b/core/mac/inc/qwlan_version.h @@ -41,9 +41,9 @@ #define QWLAN_VERSION_MAJOR 5 #define QWLAN_VERSION_MINOR 2 #define QWLAN_VERSION_PATCH 0 -#define QWLAN_VERSION_EXTRA "A" +#define QWLAN_VERSION_EXTRA "B" #define QWLAN_VERSION_BUILD 35 -#define QWLAN_VERSIONSTR "5.2.0.35A" +#define QWLAN_VERSIONSTR "5.2.0.35B" #endif /* QWLAN_VERSION_H */ From 7f8cb144b8d8200fbb12c77aeb21c13b2e2cf7e1 Mon Sep 17 00:00:00 2001 From: Srinivas Girigowda Date: Tue, 27 Jun 2017 23:37:24 -0700 Subject: [PATCH 12/34] qcacld-3.0: Fix clang warnings implicit conversion from enum tLimSmeStates warning: implicit conversion from enumeration type 'tLimSmeStates (aka 'enum eLimSmeStates') to different enumeration type 'tLimMlmStates' (aka 'enum eLimMlmStates') [-Wenum-conversion]. Change-Id: I659776ce18feaf1e566d6c9ff5cbd6d348016d65 CRs-Fixed: 2055487 --- core/mac/src/pe/lim/lim_link_monitoring_algo.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/mac/src/pe/lim/lim_link_monitoring_algo.c b/core/mac/src/pe/lim/lim_link_monitoring_algo.c index 95d4390c14ef..1734eee46329 100644 --- a/core/mac/src/pe/lim/lim_link_monitoring_algo.c +++ b/core/mac/src/pe/lim/lim_link_monitoring_algo.c @@ -231,7 +231,7 @@ void lim_delete_sta_context(tpAniSirGlobal mac_ctx, pe_err("Do not process in limMlmState %s(%x) limSmeState %s(%x)", lim_mlm_state_str(session_entry->limMlmState), session_entry->limMlmState, - lim_mlm_state_str(session_entry->limSmeState), + lim_sme_state_str(session_entry->limSmeState), session_entry->limSmeState); qdf_mem_free(msg); return; From d3b31e205a1d600ea2c9dce79490bd450088e1f5 Mon Sep 17 00:00:00 2001 From: Srinivas Girigowda Date: Wed, 28 Jun 2017 00:15:10 -0700 Subject: [PATCH 13/34] qcacld-3.0: Fix clang warnings in LIM qcacld-3.0/core/mac/src/pe/lim/lim_process_mlm_req_messages.c:487:10: warning: implicit conversion from enumeration type 'enum eSirRetStatus' to different enumeration type 'tSirResultCodes' (aka 'enum eSirResultCodes') [-Wenum-conversion] qcacld-3.0/core/mac/src/pe/lim/lim_process_mlm_rsp_messages.c:459:37: warning: implicit conversion from enumeration type 'tLimSmeStates' (aka 'enum eLimSmeStates') to different enumeration type 'tLimMlmStates' (aka 'enum eLimMlmStates') [-Wenum-conversion]. Change-Id: I649618105b220d69c8b79dcae0983ae6d75746c0 CRs-Fixed: 2055487 --- core/mac/src/pe/include/lim_session.h | 2 +- core/mac/src/pe/lim/lim_process_mlm_req_messages.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/core/mac/src/pe/include/lim_session.h b/core/mac/src/pe/include/lim_session.h index a1d37e616c8c..ee757fe5c3f0 100644 --- a/core/mac/src/pe/include/lim_session.h +++ b/core/mac/src/pe/include/lim_session.h @@ -55,7 +55,7 @@ typedef struct tagComebackTimerInfo { tpAniSirGlobal pMac; uint8_t sessionID; tLimMlmStates limPrevMlmState; /* Previous MLM State */ - tLimSmeStates limMlmState; /* MLM State */ + tLimMlmStates limMlmState; /* MLM State */ } tComebackTimerInfo; #endif /* WLAN_FEATURE_11W */ /*-------------------------------------------------------------------------- diff --git a/core/mac/src/pe/lim/lim_process_mlm_req_messages.c b/core/mac/src/pe/lim/lim_process_mlm_req_messages.c index 030e1fd7ffd8..7b0d693e728d 100644 --- a/core/mac/src/pe/lim/lim_process_mlm_req_messages.c +++ b/core/mac/src/pe/lim/lim_process_mlm_req_messages.c @@ -489,7 +489,7 @@ lim_mlm_add_bss(tpAniSirGlobal mac_ctx, if (NULL == addbss_param) { pe_err("Unable to allocate memory during ADD_BSS"); /* Respond to SME with LIM_MLM_START_CNF */ - return eSIR_MEM_ALLOC_FAILED; + return eSIR_SME_RESOURCES_UNAVAILABLE; } /* Fill in tAddBssParams members */ From 38f1deda4edd8fd5b07fde86cc67a400516054b3 Mon Sep 17 00:00:00 2001 From: Srinivas Girigowda Date: Mon, 12 Jun 2017 23:00:38 -0700 Subject: [PATCH 14/34] qcacld-3.0: Fix clang warnings implicit enum nl80211_band warning: implicit conversion from enumeration type 'enum nl80211_band' to different enumeration type 'enum ieee80211_band' [-Wenum-conversion] Change-Id: I084e015626611ae90be00b11a599ae82f9bf6f60 CRs-Fixed: 2055487 --- core/hdd/inc/wlan_hdd_main.h | 8 ++++++++ core/hdd/src/wlan_hdd_assoc.c | 4 ++-- core/hdd/src/wlan_hdd_cfg80211.c | 12 ++++++------ core/hdd/src/wlan_hdd_main.c | 4 ++-- 4 files changed, 18 insertions(+), 10 deletions(-) diff --git a/core/hdd/inc/wlan_hdd_main.h b/core/hdd/inc/wlan_hdd_main.h index 98d43c5fa2c2..322e1d4dc9e1 100644 --- a/core/hdd/inc/wlan_hdd_main.h +++ b/core/hdd/inc/wlan_hdd_main.h @@ -92,6 +92,14 @@ #define NUM_TX_QUEUES 4 #endif +#if (LINUX_VERSION_CODE >= KERNEL_VERSION(4, 7, 0)) +#define HDD_NL80211_BAND_2GHZ NL80211_BAND_2GHZ +#define HDD_NL80211_BAND_5GHZ NL80211_BAND_5GHZ +#else +#define HDD_NL80211_BAND_2GHZ IEEE80211_BAND_2GHZ +#define HDD_NL80211_BAND_5GHZ IEEE80211_BAND_5GHZ +#endif + /** Length of the TX queue for the netdev */ #define HDD_NETDEV_TX_QUEUE_LEN (3000) diff --git a/core/hdd/src/wlan_hdd_assoc.c b/core/hdd/src/wlan_hdd_assoc.c index 74a2fe80f68f..3a245949d4da 100644 --- a/core/hdd/src/wlan_hdd_assoc.c +++ b/core/hdd/src/wlan_hdd_assoc.c @@ -3208,10 +3208,10 @@ static void hdd_roam_ibss_indication_handler(hdd_adapter_t *pAdapter, if (chan_no <= 14) freq = ieee80211_channel_to_frequency(chan_no, - NL80211_BAND_2GHZ); + HDD_NL80211_BAND_2GHZ); else freq = ieee80211_channel_to_frequency(chan_no, - NL80211_BAND_5GHZ); + HDD_NL80211_BAND_5GHZ); chan = ieee80211_get_channel(pAdapter->wdev.wiphy, freq); diff --git a/core/hdd/src/wlan_hdd_cfg80211.c b/core/hdd/src/wlan_hdd_cfg80211.c index b569c3cad84e..b70fede5603c 100644 --- a/core/hdd/src/wlan_hdd_cfg80211.c +++ b/core/hdd/src/wlan_hdd_cfg80211.c @@ -177,7 +177,7 @@ } #define HDD5GHZCHAN(freq, chan, flag) { \ - .band = NL80211_BAND_5GHZ, \ + .band = HDD_NL80211_BAND_5GHZ, \ .center_freq = (freq), \ .hw_value = (chan), \ .flags = (flag), \ @@ -315,7 +315,7 @@ static struct ieee80211_rate a_mode_rates[] = { static struct ieee80211_supported_band wlan_hdd_band_2_4_ghz = { .channels = NULL, .n_channels = ARRAY_SIZE(hdd_channels_2_4_ghz), - .band = NL80211_BAND_2GHZ, + .band = HDD_NL80211_BAND_2GHZ, .bitrates = g_mode_rates, .n_bitrates = g_mode_rates_size, .ht_cap.ht_supported = 1, @@ -6694,11 +6694,11 @@ static int __wlan_hdd_cfg80211_get_preferred_freq_list(struct wiphy *wiphy, if (pcl[i] <= ARRAY_SIZE(hdd_channels_2_4_ghz)) freq_list[i] = ieee80211_channel_to_frequency(pcl[i], - NL80211_BAND_2GHZ); + HDD_NL80211_BAND_2GHZ); else freq_list[i] = ieee80211_channel_to_frequency(pcl[i], - NL80211_BAND_5GHZ); + HDD_NL80211_BAND_5GHZ); } /* send the freq_list back to supplicant */ @@ -13467,12 +13467,12 @@ struct cfg80211_bss *wlan_hdd_cfg80211_inform_bss_frame(hdd_adapter_t *pAdapter, (wiphy->bands[NL80211_BAND_2GHZ] != NULL)) { freq = ieee80211_channel_to_frequency(chan_no, - NL80211_BAND_2GHZ); + HDD_NL80211_BAND_2GHZ); } else if ((chan_no > ARRAY_SIZE(hdd_channels_2_4_ghz)) && (wiphy->bands[NL80211_BAND_5GHZ] != NULL)) { freq = ieee80211_channel_to_frequency(chan_no, - NL80211_BAND_5GHZ); + HDD_NL80211_BAND_5GHZ); } else { hdd_err("Invalid channel: %d", chan_no); qdf_mem_free(mgmt); diff --git a/core/hdd/src/wlan_hdd_main.c b/core/hdd/src/wlan_hdd_main.c index c8e032251e8a..08ae14c70ea9 100644 --- a/core/hdd/src/wlan_hdd_main.c +++ b/core/hdd/src/wlan_hdd_main.c @@ -4589,10 +4589,10 @@ void hdd_connect_result(struct net_device *dev, const u8 *bssid, if (chan_no <= 14) freq = ieee80211_channel_to_frequency(chan_no, - NL80211_BAND_2GHZ); + HDD_NL80211_BAND_2GHZ); else freq = ieee80211_channel_to_frequency(chan_no, - NL80211_BAND_5GHZ); + HDD_NL80211_BAND_5GHZ); chan = ieee80211_get_channel(padapter->wdev.wiphy, freq); bss = hdd_cfg80211_get_bss(padapter->wdev.wiphy, chan, bssid, From 11c28e0022c54cb2d78130e608940291d6ef554f Mon Sep 17 00:00:00 2001 From: Srinivas Girigowda Date: Tue, 27 Jun 2017 20:06:21 -0700 Subject: [PATCH 15/34] qcacld-3.0: Replace NL80211_BAND_2GHZ with HDD_NL80211_BAND_2GHZ warning: implicit conversion from enumeration type 'enum nl80211_band' to different enumeration type 'enum ieee80211_band' [-Wenum-conversion] Replace NL80211_BAND_2GHZ with HDD_NL80211_BAND_2GHZ and NL80211_BAND_5GHZ with HDD_NL80211_BAND_5GHZ. Change-Id: I15a905a599b87fc1a876c5f1b7bd6d69b2ba0f15 CRs-Fixed: 2055487 --- core/hdd/src/wlan_hdd_cfg80211.c | 57 +++++++++++++++--------------- core/hdd/src/wlan_hdd_main.c | 2 +- core/hdd/src/wlan_hdd_regulatory.c | 4 +-- core/hdd/src/wlan_hdd_wext.c | 4 +-- 4 files changed, 34 insertions(+), 33 deletions(-) diff --git a/core/hdd/src/wlan_hdd_cfg80211.c b/core/hdd/src/wlan_hdd_cfg80211.c index b70fede5603c..22761531e1be 100644 --- a/core/hdd/src/wlan_hdd_cfg80211.c +++ b/core/hdd/src/wlan_hdd_cfg80211.c @@ -168,7 +168,7 @@ #define IBSS_CFG_PROTECTION_ENABLE_MASK 0x8282 #define HDD2GHZCHAN(freq, chan, flag) { \ - .band = NL80211_BAND_2GHZ, \ + .band = HDD_NL80211_BAND_2GHZ, \ .center_freq = (freq), \ .hw_value = (chan), \ .flags = (flag), \ @@ -334,7 +334,7 @@ static struct ieee80211_supported_band wlan_hdd_band_2_4_ghz = { static struct ieee80211_supported_band wlan_hdd_band_5_ghz = { .channels = NULL, .n_channels = ARRAY_SIZE(hdd_channels_5_ghz), - .band = NL80211_BAND_5GHZ, + .band = HDD_NL80211_BAND_5GHZ, .bitrates = a_mode_rates, .n_bitrates = a_mode_rates_size, .ht_cap.ht_supported = 1, @@ -9916,10 +9916,10 @@ static int wlan_hdd_cfg80211_sar_convert_band(u32 nl80211_value, u32 *wmi_value) int ret = 0; switch (nl80211_value) { - case NL80211_BAND_2GHZ: + case HDD_NL80211_BAND_2GHZ: *wmi_value = WMI_SAR_2G_ID; break; - case NL80211_BAND_5GHZ: + case HDD_NL80211_BAND_5GHZ: *wmi_value = WMI_SAR_5G_ID; break; default: @@ -11217,7 +11217,8 @@ int wlan_hdd_cfg80211_update_band(hdd_context_t *hdd_ctx, struct wiphy *wiphy, hdd_ctx->hdd_pdev, band->channels[j].hw_value); - if (NL80211_BAND_2GHZ == i && eCSR_BAND_5G == eBand) { + if (HDD_NL80211_BAND_2GHZ == i && + eCSR_BAND_5G == eBand) { /* 5G only */ #ifdef WLAN_ENABLE_SOCIAL_CHANNELS_5G_ONLY /* Enable Social channels for P2P */ @@ -11232,7 +11233,7 @@ int wlan_hdd_cfg80211_update_band(hdd_context_t *hdd_ctx, struct wiphy *wiphy, band->channels[j].flags |= IEEE80211_CHAN_DISABLED; continue; - } else if (NL80211_BAND_5GHZ == i && + } else if (HDD_NL80211_BAND_5GHZ == i && eCSR_BAND_24 == eBand) { /* 2G only */ band->channels[j].flags |= @@ -11375,14 +11376,14 @@ int wlan_hdd_cfg80211_init(struct device *dev, * wiphy flags don't get reset because of static memory. * It's better not to store channel in static memory. */ - wiphy->bands[NL80211_BAND_2GHZ] = &wlan_hdd_band_2_4_ghz; - wiphy->bands[NL80211_BAND_2GHZ]->channels = + wiphy->bands[HDD_NL80211_BAND_2GHZ] = &wlan_hdd_band_2_4_ghz; + wiphy->bands[HDD_NL80211_BAND_2GHZ]->channels = qdf_mem_malloc(sizeof(hdd_channels_2_4_ghz)); - if (wiphy->bands[NL80211_BAND_2GHZ]->channels == NULL) { + if (wiphy->bands[HDD_NL80211_BAND_2GHZ]->channels == NULL) { hdd_err("Not enough memory to allocate channels"); return -ENOMEM; } - qdf_mem_copy(wiphy->bands[NL80211_BAND_2GHZ]->channels, + qdf_mem_copy(wiphy->bands[HDD_NL80211_BAND_2GHZ]->channels, &hdd_channels_2_4_ghz[0], sizeof(hdd_channels_2_4_ghz)); if ((hdd_is_5g_supported(pHddCtx)) && @@ -11390,17 +11391,17 @@ int wlan_hdd_cfg80211_init(struct device *dev, (eHDD_DOT11_MODE_11g != pCfg->dot11Mode) && (eHDD_DOT11_MODE_11b_ONLY != pCfg->dot11Mode) && (eHDD_DOT11_MODE_11g_ONLY != pCfg->dot11Mode))) { - wiphy->bands[NL80211_BAND_5GHZ] = &wlan_hdd_band_5_ghz; - wiphy->bands[NL80211_BAND_5GHZ]->channels = + wiphy->bands[HDD_NL80211_BAND_5GHZ] = &wlan_hdd_band_5_ghz; + wiphy->bands[HDD_NL80211_BAND_5GHZ]->channels = qdf_mem_malloc(sizeof(hdd_channels_5_ghz)); - if (wiphy->bands[NL80211_BAND_5GHZ]->channels == NULL) { + if (wiphy->bands[HDD_NL80211_BAND_5GHZ]->channels == NULL) { hdd_err("Not enough memory to allocate channels"); qdf_mem_free(wiphy-> - bands[NL80211_BAND_2GHZ]->channels); - wiphy->bands[NL80211_BAND_2GHZ]->channels = NULL; + bands[HDD_NL80211_BAND_2GHZ]->channels); + wiphy->bands[HDD_NL80211_BAND_2GHZ]->channels = NULL; return -ENOMEM; } - qdf_mem_copy(wiphy->bands[NL80211_BAND_5GHZ]->channels, + qdf_mem_copy(wiphy->bands[HDD_NL80211_BAND_5GHZ]->channels, &hdd_channels_5_ghz[0], sizeof(hdd_channels_5_ghz)); } @@ -11413,7 +11414,7 @@ int wlan_hdd_cfg80211_init(struct device *dev, for (j = 0; j < wiphy->bands[i]->n_channels; j++) { struct ieee80211_supported_band *band = wiphy->bands[i]; - if (NL80211_BAND_2GHZ == i && + if (HDD_NL80211_BAND_2GHZ == i && eCSR_BAND_5G == pCfg->nBandCapability) { /* 5G only */ #ifdef WLAN_ENABLE_SOCIAL_CHANNELS_5G_ONLY @@ -11427,7 +11428,7 @@ int wlan_hdd_cfg80211_init(struct device *dev, band->channels[j].flags |= IEEE80211_CHAN_DISABLED; continue; - } else if (NL80211_BAND_5GHZ == i && + } else if (HDD_NL80211_BAND_5GHZ == i && eCSR_BAND_24 == pCfg->nBandCapability) { /* 2G only */ band->channels[j].flags |= @@ -11528,21 +11529,21 @@ static void wlan_hdd_update_band_cap(hdd_context_t *hdd_ctx) ht_cap_info = (tSirMacHTCapabilityInfo *)&val16; if (ht_cap_info->txSTBC == true) { - if (NULL != hdd_ctx->wiphy->bands[NL80211_BAND_2GHZ]) - hdd_ctx->wiphy->bands[NL80211_BAND_2GHZ]->ht_cap.cap |= + if (NULL != hdd_ctx->wiphy->bands[HDD_NL80211_BAND_2GHZ]) + hdd_ctx->wiphy->bands[HDD_NL80211_BAND_2GHZ]->ht_cap.cap |= IEEE80211_HT_CAP_TX_STBC; - if (NULL != hdd_ctx->wiphy->bands[NL80211_BAND_5GHZ]) - hdd_ctx->wiphy->bands[NL80211_BAND_5GHZ]->ht_cap.cap |= + if (NULL != hdd_ctx->wiphy->bands[HDD_NL80211_BAND_5GHZ]) + hdd_ctx->wiphy->bands[HDD_NL80211_BAND_5GHZ]->ht_cap.cap |= IEEE80211_HT_CAP_TX_STBC; } if (!sme_is_feature_supported_by_fw(DOT11AC)) { - hdd_ctx->wiphy->bands[NL80211_BAND_2GHZ]-> + hdd_ctx->wiphy->bands[HDD_NL80211_BAND_2GHZ]-> vht_cap.vht_supported = 0; - hdd_ctx->wiphy->bands[NL80211_BAND_2GHZ]->vht_cap.cap = 0; - hdd_ctx->wiphy->bands[NL80211_BAND_5GHZ]-> + hdd_ctx->wiphy->bands[HDD_NL80211_BAND_2GHZ]->vht_cap.cap = 0; + hdd_ctx->wiphy->bands[HDD_NL80211_BAND_5GHZ]-> vht_cap.vht_supported = 0; - hdd_ctx->wiphy->bands[NL80211_BAND_5GHZ]->vht_cap.cap = 0; + hdd_ctx->wiphy->bands[HDD_NL80211_BAND_5GHZ]->vht_cap.cap = 0; } } @@ -13464,12 +13465,12 @@ struct cfg80211_bss *wlan_hdd_cfg80211_inform_bss_frame(hdd_adapter_t *pAdapter, } if (chan_no <= ARRAY_SIZE(hdd_channels_2_4_ghz) && - (wiphy->bands[NL80211_BAND_2GHZ] != NULL)) { + (wiphy->bands[HDD_NL80211_BAND_2GHZ] != NULL)) { freq = ieee80211_channel_to_frequency(chan_no, HDD_NL80211_BAND_2GHZ); } else if ((chan_no > ARRAY_SIZE(hdd_channels_2_4_ghz)) - && (wiphy->bands[NL80211_BAND_5GHZ] != NULL)) { + && (wiphy->bands[HDD_NL80211_BAND_5GHZ] != NULL)) { freq = ieee80211_channel_to_frequency(chan_no, HDD_NL80211_BAND_5GHZ); diff --git a/core/hdd/src/wlan_hdd_main.c b/core/hdd/src/wlan_hdd_main.c index 08ae14c70ea9..267a22948dfe 100644 --- a/core/hdd/src/wlan_hdd_main.c +++ b/core/hdd/src/wlan_hdd_main.c @@ -1061,7 +1061,7 @@ static void hdd_update_tgt_vht_cap(hdd_context_t *hdd_ctx, struct hdd_config *pconfig = hdd_ctx->config; struct wiphy *wiphy = hdd_ctx->wiphy; struct ieee80211_supported_band *band_5g = - wiphy->bands[NL80211_BAND_5GHZ]; + wiphy->bands[HDD_NL80211_BAND_5GHZ]; uint32_t temp = 0; uint32_t ch_width = eHT_CHANNEL_WIDTH_80MHZ; diff --git a/core/hdd/src/wlan_hdd_regulatory.c b/core/hdd/src/wlan_hdd_regulatory.c index db6043481744..e64702991bc1 100644 --- a/core/hdd/src/wlan_hdd_regulatory.c +++ b/core/hdd/src/wlan_hdd_regulatory.c @@ -259,9 +259,9 @@ static void hdd_regulatory_wiphy_init(hdd_context_t *hdd_ctx, * disable 2.4 Ghz channels that dont have 20 mhz bw */ for (chan_num = 0; - chan_num < wiphy->bands[NL80211_BAND_2GHZ]->n_channels; + chan_num < wiphy->bands[HDD_NL80211_BAND_2GHZ]->n_channels; chan_num++) { - chan = &(wiphy->bands[NL80211_BAND_2GHZ]->channels[chan_num]); + chan = &(wiphy->bands[HDD_NL80211_BAND_2GHZ]->channels[chan_num]); if (chan->flags & IEEE80211_CHAN_NO_20MHZ) chan->flags |= IEEE80211_CHAN_DISABLED; } diff --git a/core/hdd/src/wlan_hdd_wext.c b/core/hdd/src/wlan_hdd_wext.c index f544878830e7..eb6e24a2eedd 100644 --- a/core/hdd/src/wlan_hdd_wext.c +++ b/core/hdd/src/wlan_hdd_wext.c @@ -7569,10 +7569,10 @@ int wlan_hdd_update_phymode(struct net_device *net, tHalHandle hal, return -EIO; } if (phddctx->config->nChannelBondingMode5GHz) - phddctx->wiphy->bands[NL80211_BAND_5GHZ]->ht_cap.cap + phddctx->wiphy->bands[HDD_NL80211_BAND_5GHZ]->ht_cap.cap |= IEEE80211_HT_CAP_SUP_WIDTH_20_40; else - phddctx->wiphy->bands[NL80211_BAND_5GHZ]->ht_cap.cap + phddctx->wiphy->bands[HDD_NL80211_BAND_5GHZ]->ht_cap.cap &= ~IEEE80211_HT_CAP_SUP_WIDTH_20_40; hdd_debug("New_Phymode= %d ch_bonding=%d band=%d VHT_ch_width=%u", From fc8b4ffc0fb8a3fac0c8b38b4e359e734eebc800 Mon Sep 17 00:00:00 2001 From: Srinivas Girigowda Date: Thu, 13 Jul 2017 22:33:14 -0700 Subject: [PATCH 16/34] qcacld-3.0: Move the logs to appropriate log levels Move the logs to appropriate log levels. Change-Id: I184a8a58541daa1b29f042db9bcbeadc254b5c38 CRs-Fixed: 2063642 --- core/wma/src/wma_data.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/wma/src/wma_data.c b/core/wma/src/wma_data.c index 97eec991fc82..6a0d56752027 100644 --- a/core/wma/src/wma_data.c +++ b/core/wma/src/wma_data.c @@ -968,7 +968,7 @@ int wma_peer_state_change_event_handler(void *handle, event = param_buf->fixed_param; vdev = wma_find_vdev_by_id(wma_handle, event->vdev_id); if (NULL == vdev) { - WMA_LOGP("%s: Couldn't find vdev for vdev_id: %d", + WMA_LOGD("%s: Couldn't find vdev for vdev_id: %d", __func__, event->vdev_id); return -EINVAL; } From 4aa3e5aac443d0c4b22694cb9926f6d80bd9f944 Mon Sep 17 00:00:00 2001 From: snandini Date: Mon, 17 Jul 2017 20:55:27 -0700 Subject: [PATCH 17/34] Release 5.2.0.35C Release 5.2.0.35C Change-Id: Ic7f6c518fd011ddeee896d070c1b08e79a5b5925 CRs-Fixed: 774533 --- core/mac/inc/qwlan_version.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/core/mac/inc/qwlan_version.h b/core/mac/inc/qwlan_version.h index 42a6b78a6288..3c05260054aa 100644 --- a/core/mac/inc/qwlan_version.h +++ b/core/mac/inc/qwlan_version.h @@ -41,9 +41,9 @@ #define QWLAN_VERSION_MAJOR 5 #define QWLAN_VERSION_MINOR 2 #define QWLAN_VERSION_PATCH 0 -#define QWLAN_VERSION_EXTRA "B" +#define QWLAN_VERSION_EXTRA "C" #define QWLAN_VERSION_BUILD 35 -#define QWLAN_VERSIONSTR "5.2.0.35B" +#define QWLAN_VERSIONSTR "5.2.0.35C" #endif /* QWLAN_VERSION_H */ From 77bf407f75377114dc836719445efc00ca812ea8 Mon Sep 17 00:00:00 2001 From: Houston Hoffman Date: Mon, 17 Jul 2017 01:01:18 -0700 Subject: [PATCH 18/34] qcacld-3.0: free memory in csr_get_snr error path Free allocated message container when csr_roam_get_session_id_from_bssid fails. Change-Id: I088d3866d2c8052ef65ce5a719dd6c478d98e293 CRs-Fixed: 2077460 --- core/sme/src/csr/csr_api_roam.c | 1 + 1 file changed, 1 insertion(+) diff --git a/core/sme/src/csr/csr_api_roam.c b/core/sme/src/csr/csr_api_roam.c index 5add7df3a96d..4f622bf83ebf 100644 --- a/core/sme/src/csr/csr_api_roam.c +++ b/core/sme/src/csr/csr_api_roam.c @@ -16461,6 +16461,7 @@ QDF_STATUS csr_get_snr(tpAniSirGlobal pMac, status = csr_roam_get_session_id_from_bssid(pMac, &bssId, &sessionId); if (!QDF_IS_STATUS_SUCCESS(status)) { + qdf_mem_free(pMsg); sme_err("Couldn't find session_id for given BSSID"); return status; } From ceb4d64b3e753c674fd2a717eb77edccc2d2c332 Mon Sep 17 00:00:00 2001 From: Lin Bai Date: Fri, 2 Jun 2017 11:20:44 +0800 Subject: [PATCH 19/34] qcacld-3.0: Fix fragile code in dphInitStaState qcacld-2.0 to qcacld-3.0 propagation In dphInitStaState function, it will implicitly assume that, the last member of structure tDphHashNode is *next* pointer, which is fragile and risky. Save the *next* pointer in local variant and restore after whole structure zeroed. This will need additional CPU ticks but eliminate the risk. CRs-Fixed: 2055505 Change-Id: I6baf3eddea965eda4e7f7ca88fef54709964febc --- core/mac/src/dph/dph_hash_table.c | 9 +++++---- core/mac/src/pe/lim/lim_process_tdls.c | 4 ---- 2 files changed, 5 insertions(+), 8 deletions(-) diff --git a/core/mac/src/dph/dph_hash_table.c b/core/mac/src/dph/dph_hash_table.c index 3ebcb6a6d55f..3fd4940a67db 100644 --- a/core/mac/src/dph/dph_hash_table.c +++ b/core/mac/src/dph/dph_hash_table.c @@ -240,7 +240,7 @@ tpDphHashNode dph_init_sta_state(tpAniSirGlobal pMac, tSirMacAddr staAddr, { uint32_t val; - tpDphHashNode pStaDs; + tpDphHashNode pStaDs, pnext; uint16_t staIdx = STA_INVALID_IDX; if (assocId >= pDphHashTable->size) { @@ -250,10 +250,11 @@ tpDphHashNode dph_init_sta_state(tpAniSirGlobal pMac, tSirMacAddr staAddr, pStaDs = get_node(pMac, (uint8_t) assocId, pDphHashTable); staIdx = pStaDs->staIndex; + pnext = pStaDs->next; - /* Clear the STA node except for the next pointer (last 4 bytes) */ - qdf_mem_set((uint8_t *) pStaDs, - sizeof(tDphHashNode) - sizeof(tpDphHashNode), 0); + /* Clear the STA node except for the next pointer */ + qdf_mem_set((uint8_t *)pStaDs, sizeof(tDphHashNode), 0); + pStaDs->next = pnext; /* Initialize the assocId */ pStaDs->assocId = assocId; diff --git a/core/mac/src/pe/lim/lim_process_tdls.c b/core/mac/src/pe/lim/lim_process_tdls.c index f1103f7eb9f6..85d5e9b74b1c 100644 --- a/core/mac/src/pe/lim/lim_process_tdls.c +++ b/core/mac/src/pe/lim/lim_process_tdls.c @@ -2416,8 +2416,6 @@ static void lim_tdls_update_hash_node_info(tpAniSirGlobal pMac, tDot11fIEVHTCaps *pVhtCaps_txbf = NULL; tDot11fIEVHTCaps vhtCap; uint8_t cbMode; - tpDphHashNode pSessStaDs = NULL; - uint16_t aid; if (pTdlsAddStaReq->tdlsAddOper == TDLS_OPER_ADD) { populate_dot11f_ht_caps(pMac, psessionEntry, &htCap); @@ -2516,8 +2514,6 @@ static void lim_tdls_update_hash_node_info(tpAniSirGlobal pMac, else pStaDs->htSecondaryChannelOffset = cbMode; } - pSessStaDs = dph_lookup_hash_entry(pMac, psessionEntry->bssId, &aid, - &psessionEntry->dph.dphHashTable); /* Lets enable QOS parameter */ pStaDs->qosMode = (pTdlsAddStaReq->capability & CAPABILITIES_QOS_OFFSET) || pTdlsAddStaReq->htcap_present; From 303ebe9dbf745ef1a72ad41af54e16b7a74e25c2 Mon Sep 17 00:00:00 2001 From: Zhang Qian Date: Thu, 18 May 2017 13:59:07 +0800 Subject: [PATCH 20/34] qcacld-3.0: Add mac counters for per-antenna TX/RX stats qcacld-2.0 to qcacld-3.0 propagation New MAC counters are added to count MPDUs received and transferred on each antenna. Change-Id: Ia7fbf7642922f006882619848459192dcfca3c40 CRs-Fixed: 2043156 --- core/hdd/src/wlan_hdd_stats.c | 21 +++++++++++++++++---- core/mac/inc/sir_api.h | 7 +++++++ core/wma/src/wma_utils.c | 21 +++++++++++++++++++-- 3 files changed, 43 insertions(+), 6 deletions(-) diff --git a/core/hdd/src/wlan_hdd_stats.c b/core/hdd/src/wlan_hdd_stats.c index b29e56b2b474..f96a2e0e6f2c 100644 --- a/core/hdd/src/wlan_hdd_stats.c +++ b/core/hdd/src/wlan_hdd_stats.c @@ -1855,16 +1855,18 @@ static int hdd_populate_wifi_signal_info(struct sir_wifi_peer_signal_stats *peer_signal, struct sk_buff *skb) { - uint32_t i; + uint32_t i, chain_count; struct nlattr *chains, *att; /* There might be no signal info for a peer */ if (!peer_signal) return 0; + chain_count = peer_signal->num_chain < WIFI_MAX_CHAINS ? + peer_signal->num_chain : WIFI_MAX_CHAINS; if (nla_put_u32(skb, QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_PEER_ANT_NUM, - WIFI_MAX_CHAINS)) { + chain_count)) { hdd_err("QCA_WLAN_VENDOR_ATTR put fail"); return -EINVAL; } @@ -1876,7 +1878,7 @@ hdd_populate_wifi_signal_info(struct sir_wifi_peer_signal_stats *peer_signal, return -EINVAL; } - for (i = 0; i < WIFI_MAX_CHAINS; i++) { + for (i = 0; i < chain_count; i++) { chains = nla_nest_start(skb, i); if (!chains) { @@ -1884,12 +1886,23 @@ hdd_populate_wifi_signal_info(struct sir_wifi_peer_signal_stats *peer_signal, return -EINVAL; } + hdd_debug("SNR=%d, NF=%d, Rx=%d, Tx=%d", + peer_signal->per_ant_snr[i], + peer_signal->nf[i], + peer_signal->per_ant_rx_mpdus[i], + peer_signal->per_ant_tx_mpdus[i]); if (nla_put_u32(skb, QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_ANT_SNR, peer_signal->per_ant_snr[i]) || nla_put_u32(skb, QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_ANT_NF, - peer_signal->nf[i])) { + peer_signal->nf[i]) || + nla_put_u32(skb, + QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_RX_MPDU, + peer_signal->per_ant_rx_mpdus[i]) || + nla_put_u32(skb, + QCA_WLAN_VENDOR_ATTR_LL_STATS_EXT_TX_MPDU, + peer_signal->per_ant_tx_mpdus[i])) { hdd_err("QCA_WLAN_VENDOR_ATTR put fail"); return -EINVAL; } diff --git a/core/mac/inc/sir_api.h b/core/mac/inc/sir_api.h index 6e6a0dbfd4a3..bfe2ce0a94f7 100644 --- a/core/mac/inc/sir_api.h +++ b/core/mac/inc/sir_api.h @@ -5225,6 +5225,9 @@ struct sir_wifi_chan_cca_stats { * @peer_id: peer ID * @per_ant_snr: per antenna SNR * @nf: peer background noise + * @per_ant_rx_mpdus: MPDUs received per antenna + * @per_ant_tx_mpdus: MPDUs transferred per antenna + * @num_chain: valid chain count */ struct sir_wifi_peer_signal_stats { uint32_t vdev_id; @@ -5235,6 +5238,10 @@ struct sir_wifi_peer_signal_stats { /* Background noise */ int32_t nf[WIFI_MAX_CHAINS]; + + int32_t per_ant_rx_mpdus[WIFI_MAX_CHAINS]; + int32_t per_ant_tx_mpdus[WIFI_MAX_CHAINS]; + int32_t num_chain; }; #define WIFI_VDEV_NUM 4 diff --git a/core/wma/src/wma_utils.c b/core/wma/src/wma_utils.c index 4959f461a71a..7473d75d5462 100644 --- a/core/wma/src/wma_utils.c +++ b/core/wma/src/wma_utils.c @@ -1064,9 +1064,26 @@ static int wma_ll_stats_evt_handler(void *handle, u_int8_t *event, peer_stats[i].vdev_id = wmi_peer_signal->vdev_id; peer_signal = &peer_stats[i].peer_signal_stats; + WMA_LOGD("%d antennas for peer %d", + wmi_peer_signal->num_chains_valid, + wmi_peer_signal->peer_id); if (dst_len <= result_size) { - qdf_mem_copy(peer_signal, - &wmi_peer_signal->vdev_id, dst_len); + peer_signal->vdev_id = wmi_peer_signal->vdev_id; + peer_signal->peer_id = wmi_peer_signal->peer_id; + peer_signal->num_chain = + wmi_peer_signal->num_chains_valid; + qdf_mem_copy(peer_signal->per_ant_snr, + wmi_peer_signal->per_chain_snr, + sizeof(peer_signal->per_ant_snr)); + qdf_mem_copy(peer_signal->nf, + wmi_peer_signal->per_chain_nf, + sizeof(peer_signal->nf)); + qdf_mem_copy(peer_signal->per_ant_rx_mpdus, + wmi_peer_signal->per_antenna_rx_mpdus, + sizeof(peer_signal->per_ant_rx_mpdus)); + qdf_mem_copy(peer_signal->per_ant_tx_mpdus, + wmi_peer_signal->per_antenna_tx_mpdus, + sizeof(peer_signal->per_ant_tx_mpdus)); result_size -= dst_len; } else { WMA_LOGE(FL("Invalid length of PEER signal.")); From 5c84bf791655163f0f60176760b035f2e510e269 Mon Sep 17 00:00:00 2001 From: snandini Date: Mon, 17 Jul 2017 21:48:06 -0700 Subject: [PATCH 21/34] Release 5.2.0.35D Release 5.2.0.35D Change-Id: I3c91be28c44c18af7ac4ded98397605311356626 CRs-Fixed: 774533 --- core/mac/inc/qwlan_version.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/core/mac/inc/qwlan_version.h b/core/mac/inc/qwlan_version.h index 3c05260054aa..9f49b6a48117 100644 --- a/core/mac/inc/qwlan_version.h +++ b/core/mac/inc/qwlan_version.h @@ -41,9 +41,9 @@ #define QWLAN_VERSION_MAJOR 5 #define QWLAN_VERSION_MINOR 2 #define QWLAN_VERSION_PATCH 0 -#define QWLAN_VERSION_EXTRA "C" +#define QWLAN_VERSION_EXTRA "D" #define QWLAN_VERSION_BUILD 35 -#define QWLAN_VERSIONSTR "5.2.0.35C" +#define QWLAN_VERSIONSTR "5.2.0.35D" #endif /* QWLAN_VERSION_H */ From f46083e0e55d7137c950be9137fc151992cee9a3 Mon Sep 17 00:00:00 2001 From: Rajeev Kumar Date: Mon, 17 Jul 2017 17:48:16 -0700 Subject: [PATCH 22/34] qcacld-3.0: Move CLD components outside core folder Core is legacy module folder in CLD. Hence move MCL specific components folder outside core. Change-Id: Iba3f9fdb06ad10dc4a5b19f3ff1ffa23f7372605 CRs-Fixed: 2077963 --- Kbuild | 4 ++-- {core/components => components}/pmo/core/inc/wlan_pmo_arp.h | 0 {core/components => components}/pmo/core/inc/wlan_pmo_gtk.h | 0 .../pmo/core/inc/wlan_pmo_hw_filter.h | 0 {core/components => components}/pmo/core/inc/wlan_pmo_lphb.h | 0 {core/components => components}/pmo/core/inc/wlan_pmo_main.h | 0 .../pmo/core/inc/wlan_pmo_mc_addr_filtering.h | 0 {core/components => components}/pmo/core/inc/wlan_pmo_ns.h | 0 .../components => components}/pmo/core/inc/wlan_pmo_objmgr.h | 0 .../pmo/core/inc/wlan_pmo_pkt_filter.h | 0 {core/components => components}/pmo/core/inc/wlan_pmo_priv.h | 0 .../pmo/core/inc/wlan_pmo_static_config.h | 0 .../pmo/core/inc/wlan_pmo_suspend_resume.h | 0 {core/components => components}/pmo/core/inc/wlan_pmo_wow.h | 0 {core/components => components}/pmo/core/src/wlan_pmo_arp.c | 0 {core/components => components}/pmo/core/src/wlan_pmo_gtk.c | 0 .../pmo/core/src/wlan_pmo_hw_filter.c | 0 {core/components => components}/pmo/core/src/wlan_pmo_lphb.c | 0 {core/components => components}/pmo/core/src/wlan_pmo_main.c | 0 .../pmo/core/src/wlan_pmo_mc_addr_filtering.c | 0 {core/components => components}/pmo/core/src/wlan_pmo_ns.c | 0 .../pmo/core/src/wlan_pmo_pkt_filter.c | 0 .../pmo/core/src/wlan_pmo_static_config.c | 0 .../pmo/core/src/wlan_pmo_suspend_resume.c | 0 {core/components => components}/pmo/core/src/wlan_pmo_wow.c | 0 .../pmo/dispatcher/inc/wlan_pmo_arp_public_struct.h | 0 .../pmo/dispatcher/inc/wlan_pmo_common_public_struct.h | 0 .../pmo/dispatcher/inc/wlan_pmo_gtk_public_struct.h | 0 .../pmo/dispatcher/inc/wlan_pmo_hw_filter_public_struct.h | 0 .../pmo/dispatcher/inc/wlan_pmo_lphb_public_struct.h | 0 .../dispatcher/inc/wlan_pmo_mc_addr_filtering_public_struct.h | 0 .../pmo/dispatcher/inc/wlan_pmo_ns_public_struct.h | 0 .../pmo/dispatcher/inc/wlan_pmo_obj_mgmt_api.h | 0 .../pmo/dispatcher/inc/wlan_pmo_obj_mgmt_public_struct.h | 0 .../pmo/dispatcher/inc/wlan_pmo_pkt_filter_public_struct.h | 0 .../pmo/dispatcher/inc/wlan_pmo_tgt_api.h | 0 .../pmo/dispatcher/inc/wlan_pmo_ucfg_api.h | 0 .../pmo/dispatcher/inc/wlan_pmo_wow_public_struct.h | 0 .../pmo/dispatcher/src/wlan_pmo_obj_mgmt_api.c | 0 .../pmo/dispatcher/src/wlan_pmo_tgt_arp.c | 0 .../pmo/dispatcher/src/wlan_pmo_tgt_gtk.c | 0 .../pmo/dispatcher/src/wlan_pmo_tgt_hw_filter.c | 0 .../pmo/dispatcher/src/wlan_pmo_tgt_lphb.c | 0 .../pmo/dispatcher/src/wlan_pmo_tgt_mc_addr_filtering.c | 0 .../pmo/dispatcher/src/wlan_pmo_tgt_ns.c | 0 .../pmo/dispatcher/src/wlan_pmo_tgt_pkt_filter.c | 0 .../pmo/dispatcher/src/wlan_pmo_tgt_static_config.c | 0 .../pmo/dispatcher/src/wlan_pmo_tgt_suspend_resume.c | 0 .../pmo/dispatcher/src/wlan_pmo_tgt_wow.c | 0 .../pmo/dispatcher/src/wlan_pmo_ucfg_api.c | 0 .../target_if/pmo/inc/target_if_pmo.h | 0 .../target_if/pmo/src/target_if_pmo_arp.c | 0 .../target_if/pmo/src/target_if_pmo_gtk.c | 0 .../target_if/pmo/src/target_if_pmo_hw_filter.c | 0 .../target_if/pmo/src/target_if_pmo_lphb.c | 0 .../target_if/pmo/src/target_if_pmo_main.c | 0 .../target_if/pmo/src/target_if_pmo_mc_addr_filtering.c | 0 .../target_if/pmo/src/target_if_pmo_ns.c | 0 .../target_if/pmo/src/target_if_pmo_pkt_filter.c | 0 .../target_if/pmo/src/target_if_pmo_static_config.c | 0 .../target_if/pmo/src/target_if_pmo_suspend_resume.c | 0 .../target_if/pmo/src/target_if_pmo_wow.c | 0 62 files changed, 2 insertions(+), 2 deletions(-) rename {core/components => components}/pmo/core/inc/wlan_pmo_arp.h (100%) rename {core/components => components}/pmo/core/inc/wlan_pmo_gtk.h (100%) rename {core/components => components}/pmo/core/inc/wlan_pmo_hw_filter.h (100%) rename {core/components => components}/pmo/core/inc/wlan_pmo_lphb.h (100%) rename {core/components => components}/pmo/core/inc/wlan_pmo_main.h (100%) rename {core/components => components}/pmo/core/inc/wlan_pmo_mc_addr_filtering.h (100%) rename {core/components => components}/pmo/core/inc/wlan_pmo_ns.h (100%) rename {core/components => components}/pmo/core/inc/wlan_pmo_objmgr.h (100%) rename {core/components => components}/pmo/core/inc/wlan_pmo_pkt_filter.h (100%) rename {core/components => components}/pmo/core/inc/wlan_pmo_priv.h (100%) rename {core/components => components}/pmo/core/inc/wlan_pmo_static_config.h (100%) rename {core/components => components}/pmo/core/inc/wlan_pmo_suspend_resume.h (100%) rename {core/components => components}/pmo/core/inc/wlan_pmo_wow.h (100%) rename {core/components => components}/pmo/core/src/wlan_pmo_arp.c (100%) rename {core/components => components}/pmo/core/src/wlan_pmo_gtk.c (100%) rename {core/components => components}/pmo/core/src/wlan_pmo_hw_filter.c (100%) rename {core/components => components}/pmo/core/src/wlan_pmo_lphb.c (100%) rename {core/components => components}/pmo/core/src/wlan_pmo_main.c (100%) rename {core/components => components}/pmo/core/src/wlan_pmo_mc_addr_filtering.c (100%) rename {core/components => components}/pmo/core/src/wlan_pmo_ns.c (100%) rename {core/components => components}/pmo/core/src/wlan_pmo_pkt_filter.c (100%) rename {core/components => components}/pmo/core/src/wlan_pmo_static_config.c (100%) rename {core/components => components}/pmo/core/src/wlan_pmo_suspend_resume.c (100%) rename {core/components => components}/pmo/core/src/wlan_pmo_wow.c (100%) rename {core/components => components}/pmo/dispatcher/inc/wlan_pmo_arp_public_struct.h (100%) rename {core/components => components}/pmo/dispatcher/inc/wlan_pmo_common_public_struct.h (100%) rename {core/components => components}/pmo/dispatcher/inc/wlan_pmo_gtk_public_struct.h (100%) rename {core/components => components}/pmo/dispatcher/inc/wlan_pmo_hw_filter_public_struct.h (100%) rename {core/components => components}/pmo/dispatcher/inc/wlan_pmo_lphb_public_struct.h (100%) rename {core/components => components}/pmo/dispatcher/inc/wlan_pmo_mc_addr_filtering_public_struct.h (100%) rename {core/components => components}/pmo/dispatcher/inc/wlan_pmo_ns_public_struct.h (100%) rename {core/components => components}/pmo/dispatcher/inc/wlan_pmo_obj_mgmt_api.h (100%) rename {core/components => components}/pmo/dispatcher/inc/wlan_pmo_obj_mgmt_public_struct.h (100%) rename {core/components => components}/pmo/dispatcher/inc/wlan_pmo_pkt_filter_public_struct.h (100%) rename {core/components => components}/pmo/dispatcher/inc/wlan_pmo_tgt_api.h (100%) rename {core/components => components}/pmo/dispatcher/inc/wlan_pmo_ucfg_api.h (100%) rename {core/components => components}/pmo/dispatcher/inc/wlan_pmo_wow_public_struct.h (100%) rename {core/components => components}/pmo/dispatcher/src/wlan_pmo_obj_mgmt_api.c (100%) rename {core/components => components}/pmo/dispatcher/src/wlan_pmo_tgt_arp.c (100%) rename {core/components => components}/pmo/dispatcher/src/wlan_pmo_tgt_gtk.c (100%) rename {core/components => components}/pmo/dispatcher/src/wlan_pmo_tgt_hw_filter.c (100%) rename {core/components => components}/pmo/dispatcher/src/wlan_pmo_tgt_lphb.c (100%) rename {core/components => components}/pmo/dispatcher/src/wlan_pmo_tgt_mc_addr_filtering.c (100%) rename {core/components => components}/pmo/dispatcher/src/wlan_pmo_tgt_ns.c (100%) rename {core/components => components}/pmo/dispatcher/src/wlan_pmo_tgt_pkt_filter.c (100%) rename {core/components => components}/pmo/dispatcher/src/wlan_pmo_tgt_static_config.c (100%) rename {core/components => components}/pmo/dispatcher/src/wlan_pmo_tgt_suspend_resume.c (100%) rename {core/components => components}/pmo/dispatcher/src/wlan_pmo_tgt_wow.c (100%) rename {core/components => components}/pmo/dispatcher/src/wlan_pmo_ucfg_api.c (100%) rename {core/components => components}/target_if/pmo/inc/target_if_pmo.h (100%) rename {core/components => components}/target_if/pmo/src/target_if_pmo_arp.c (100%) rename {core/components => components}/target_if/pmo/src/target_if_pmo_gtk.c (100%) rename {core/components => components}/target_if/pmo/src/target_if_pmo_hw_filter.c (100%) rename {core/components => components}/target_if/pmo/src/target_if_pmo_lphb.c (100%) rename {core/components => components}/target_if/pmo/src/target_if_pmo_main.c (100%) rename {core/components => components}/target_if/pmo/src/target_if_pmo_mc_addr_filtering.c (100%) rename {core/components => components}/target_if/pmo/src/target_if_pmo_ns.c (100%) rename {core/components => components}/target_if/pmo/src/target_if_pmo_pkt_filter.c (100%) rename {core/components => components}/target_if/pmo/src/target_if_pmo_static_config.c (100%) rename {core/components => components}/target_if/pmo/src/target_if_pmo_suspend_resume.c (100%) rename {core/components => components}/target_if/pmo/src/target_if_pmo_wow.c (100%) diff --git a/Kbuild b/Kbuild index ee372fd4b9c6..d439762d7a48 100644 --- a/Kbuild +++ b/Kbuild @@ -883,7 +883,7 @@ UMAC_MGMT_TXRX_OBJS := $(UMAC_MGMT_TXRX_DIR)/core/src/wlan_mgmt_txrx_main.o \ $(UMAC_MGMT_TXRX_DIR)/dispatcher/src/wlan_mgmt_txrx_tgt_api.o ########## POWER MANAGEMENT OFFLOADS (PMO) ########## -PMO_DIR := core/components/pmo +PMO_DIR := components/pmo PMO_INC := -I$(WLAN_ROOT)/$(PMO_DIR)/core/inc \ -I$(WLAN_ROOT)/$(PMO_DIR)/core/src \ -I$(WLAN_ROOT)/$(PMO_DIR)/dispatcher/inc \ @@ -914,7 +914,7 @@ PMO_OBJS := $(PMO_DIR)/core/src/wlan_pmo_main.o \ $(PMO_DIR)/dispatcher/src/wlan_pmo_tgt_pkt_filter.o ########## CLD TARGET_IF ####### -CLD_TARGET_IF_DIR := core/components/target_if +CLD_TARGET_IF_DIR := components/target_if CLD_TARGET_IF_INC := -I$(WLAN_ROOT)/$(CLD_TARGET_IF_DIR)/pmo/inc \ -I$(WLAN_ROOT)/$(CLD_TARGET_IF_DIR)/pmo/src \ diff --git a/core/components/pmo/core/inc/wlan_pmo_arp.h b/components/pmo/core/inc/wlan_pmo_arp.h similarity index 100% rename from core/components/pmo/core/inc/wlan_pmo_arp.h rename to components/pmo/core/inc/wlan_pmo_arp.h diff --git a/core/components/pmo/core/inc/wlan_pmo_gtk.h b/components/pmo/core/inc/wlan_pmo_gtk.h similarity index 100% rename from core/components/pmo/core/inc/wlan_pmo_gtk.h rename to components/pmo/core/inc/wlan_pmo_gtk.h diff --git a/core/components/pmo/core/inc/wlan_pmo_hw_filter.h b/components/pmo/core/inc/wlan_pmo_hw_filter.h similarity index 100% rename from core/components/pmo/core/inc/wlan_pmo_hw_filter.h rename to components/pmo/core/inc/wlan_pmo_hw_filter.h diff --git a/core/components/pmo/core/inc/wlan_pmo_lphb.h b/components/pmo/core/inc/wlan_pmo_lphb.h similarity index 100% rename from core/components/pmo/core/inc/wlan_pmo_lphb.h rename to components/pmo/core/inc/wlan_pmo_lphb.h diff --git a/core/components/pmo/core/inc/wlan_pmo_main.h b/components/pmo/core/inc/wlan_pmo_main.h similarity index 100% rename from core/components/pmo/core/inc/wlan_pmo_main.h rename to components/pmo/core/inc/wlan_pmo_main.h diff --git a/core/components/pmo/core/inc/wlan_pmo_mc_addr_filtering.h b/components/pmo/core/inc/wlan_pmo_mc_addr_filtering.h similarity index 100% rename from core/components/pmo/core/inc/wlan_pmo_mc_addr_filtering.h rename to components/pmo/core/inc/wlan_pmo_mc_addr_filtering.h diff --git a/core/components/pmo/core/inc/wlan_pmo_ns.h b/components/pmo/core/inc/wlan_pmo_ns.h similarity index 100% rename from core/components/pmo/core/inc/wlan_pmo_ns.h rename to components/pmo/core/inc/wlan_pmo_ns.h diff --git a/core/components/pmo/core/inc/wlan_pmo_objmgr.h b/components/pmo/core/inc/wlan_pmo_objmgr.h similarity index 100% rename from core/components/pmo/core/inc/wlan_pmo_objmgr.h rename to components/pmo/core/inc/wlan_pmo_objmgr.h diff --git a/core/components/pmo/core/inc/wlan_pmo_pkt_filter.h b/components/pmo/core/inc/wlan_pmo_pkt_filter.h similarity index 100% rename from core/components/pmo/core/inc/wlan_pmo_pkt_filter.h rename to components/pmo/core/inc/wlan_pmo_pkt_filter.h diff --git a/core/components/pmo/core/inc/wlan_pmo_priv.h b/components/pmo/core/inc/wlan_pmo_priv.h similarity index 100% rename from core/components/pmo/core/inc/wlan_pmo_priv.h rename to components/pmo/core/inc/wlan_pmo_priv.h diff --git a/core/components/pmo/core/inc/wlan_pmo_static_config.h b/components/pmo/core/inc/wlan_pmo_static_config.h similarity index 100% rename from core/components/pmo/core/inc/wlan_pmo_static_config.h rename to components/pmo/core/inc/wlan_pmo_static_config.h diff --git a/core/components/pmo/core/inc/wlan_pmo_suspend_resume.h b/components/pmo/core/inc/wlan_pmo_suspend_resume.h similarity index 100% rename from core/components/pmo/core/inc/wlan_pmo_suspend_resume.h rename to components/pmo/core/inc/wlan_pmo_suspend_resume.h diff --git a/core/components/pmo/core/inc/wlan_pmo_wow.h b/components/pmo/core/inc/wlan_pmo_wow.h similarity index 100% rename from core/components/pmo/core/inc/wlan_pmo_wow.h rename to components/pmo/core/inc/wlan_pmo_wow.h diff --git a/core/components/pmo/core/src/wlan_pmo_arp.c b/components/pmo/core/src/wlan_pmo_arp.c similarity index 100% rename from core/components/pmo/core/src/wlan_pmo_arp.c rename to components/pmo/core/src/wlan_pmo_arp.c diff --git a/core/components/pmo/core/src/wlan_pmo_gtk.c b/components/pmo/core/src/wlan_pmo_gtk.c similarity index 100% rename from core/components/pmo/core/src/wlan_pmo_gtk.c rename to components/pmo/core/src/wlan_pmo_gtk.c diff --git a/core/components/pmo/core/src/wlan_pmo_hw_filter.c b/components/pmo/core/src/wlan_pmo_hw_filter.c similarity index 100% rename from core/components/pmo/core/src/wlan_pmo_hw_filter.c rename to components/pmo/core/src/wlan_pmo_hw_filter.c diff --git a/core/components/pmo/core/src/wlan_pmo_lphb.c b/components/pmo/core/src/wlan_pmo_lphb.c similarity index 100% rename from core/components/pmo/core/src/wlan_pmo_lphb.c rename to components/pmo/core/src/wlan_pmo_lphb.c diff --git a/core/components/pmo/core/src/wlan_pmo_main.c b/components/pmo/core/src/wlan_pmo_main.c similarity index 100% rename from core/components/pmo/core/src/wlan_pmo_main.c rename to components/pmo/core/src/wlan_pmo_main.c diff --git a/core/components/pmo/core/src/wlan_pmo_mc_addr_filtering.c b/components/pmo/core/src/wlan_pmo_mc_addr_filtering.c similarity index 100% rename from core/components/pmo/core/src/wlan_pmo_mc_addr_filtering.c rename to components/pmo/core/src/wlan_pmo_mc_addr_filtering.c diff --git a/core/components/pmo/core/src/wlan_pmo_ns.c b/components/pmo/core/src/wlan_pmo_ns.c similarity index 100% rename from core/components/pmo/core/src/wlan_pmo_ns.c rename to components/pmo/core/src/wlan_pmo_ns.c diff --git a/core/components/pmo/core/src/wlan_pmo_pkt_filter.c b/components/pmo/core/src/wlan_pmo_pkt_filter.c similarity index 100% rename from core/components/pmo/core/src/wlan_pmo_pkt_filter.c rename to components/pmo/core/src/wlan_pmo_pkt_filter.c diff --git a/core/components/pmo/core/src/wlan_pmo_static_config.c b/components/pmo/core/src/wlan_pmo_static_config.c similarity index 100% rename from core/components/pmo/core/src/wlan_pmo_static_config.c rename to components/pmo/core/src/wlan_pmo_static_config.c diff --git a/core/components/pmo/core/src/wlan_pmo_suspend_resume.c b/components/pmo/core/src/wlan_pmo_suspend_resume.c similarity index 100% rename from core/components/pmo/core/src/wlan_pmo_suspend_resume.c rename to components/pmo/core/src/wlan_pmo_suspend_resume.c diff --git a/core/components/pmo/core/src/wlan_pmo_wow.c b/components/pmo/core/src/wlan_pmo_wow.c similarity index 100% rename from core/components/pmo/core/src/wlan_pmo_wow.c rename to components/pmo/core/src/wlan_pmo_wow.c diff --git a/core/components/pmo/dispatcher/inc/wlan_pmo_arp_public_struct.h b/components/pmo/dispatcher/inc/wlan_pmo_arp_public_struct.h similarity index 100% rename from core/components/pmo/dispatcher/inc/wlan_pmo_arp_public_struct.h rename to components/pmo/dispatcher/inc/wlan_pmo_arp_public_struct.h diff --git a/core/components/pmo/dispatcher/inc/wlan_pmo_common_public_struct.h b/components/pmo/dispatcher/inc/wlan_pmo_common_public_struct.h similarity index 100% rename from core/components/pmo/dispatcher/inc/wlan_pmo_common_public_struct.h rename to components/pmo/dispatcher/inc/wlan_pmo_common_public_struct.h diff --git a/core/components/pmo/dispatcher/inc/wlan_pmo_gtk_public_struct.h b/components/pmo/dispatcher/inc/wlan_pmo_gtk_public_struct.h similarity index 100% rename from core/components/pmo/dispatcher/inc/wlan_pmo_gtk_public_struct.h rename to components/pmo/dispatcher/inc/wlan_pmo_gtk_public_struct.h diff --git a/core/components/pmo/dispatcher/inc/wlan_pmo_hw_filter_public_struct.h b/components/pmo/dispatcher/inc/wlan_pmo_hw_filter_public_struct.h similarity index 100% rename from core/components/pmo/dispatcher/inc/wlan_pmo_hw_filter_public_struct.h rename to components/pmo/dispatcher/inc/wlan_pmo_hw_filter_public_struct.h diff --git a/core/components/pmo/dispatcher/inc/wlan_pmo_lphb_public_struct.h b/components/pmo/dispatcher/inc/wlan_pmo_lphb_public_struct.h similarity index 100% rename from core/components/pmo/dispatcher/inc/wlan_pmo_lphb_public_struct.h rename to components/pmo/dispatcher/inc/wlan_pmo_lphb_public_struct.h diff --git a/core/components/pmo/dispatcher/inc/wlan_pmo_mc_addr_filtering_public_struct.h b/components/pmo/dispatcher/inc/wlan_pmo_mc_addr_filtering_public_struct.h similarity index 100% rename from core/components/pmo/dispatcher/inc/wlan_pmo_mc_addr_filtering_public_struct.h rename to components/pmo/dispatcher/inc/wlan_pmo_mc_addr_filtering_public_struct.h diff --git a/core/components/pmo/dispatcher/inc/wlan_pmo_ns_public_struct.h b/components/pmo/dispatcher/inc/wlan_pmo_ns_public_struct.h similarity index 100% rename from core/components/pmo/dispatcher/inc/wlan_pmo_ns_public_struct.h rename to components/pmo/dispatcher/inc/wlan_pmo_ns_public_struct.h diff --git a/core/components/pmo/dispatcher/inc/wlan_pmo_obj_mgmt_api.h b/components/pmo/dispatcher/inc/wlan_pmo_obj_mgmt_api.h similarity index 100% rename from core/components/pmo/dispatcher/inc/wlan_pmo_obj_mgmt_api.h rename to components/pmo/dispatcher/inc/wlan_pmo_obj_mgmt_api.h diff --git a/core/components/pmo/dispatcher/inc/wlan_pmo_obj_mgmt_public_struct.h b/components/pmo/dispatcher/inc/wlan_pmo_obj_mgmt_public_struct.h similarity index 100% rename from core/components/pmo/dispatcher/inc/wlan_pmo_obj_mgmt_public_struct.h rename to components/pmo/dispatcher/inc/wlan_pmo_obj_mgmt_public_struct.h diff --git a/core/components/pmo/dispatcher/inc/wlan_pmo_pkt_filter_public_struct.h b/components/pmo/dispatcher/inc/wlan_pmo_pkt_filter_public_struct.h similarity index 100% rename from core/components/pmo/dispatcher/inc/wlan_pmo_pkt_filter_public_struct.h rename to components/pmo/dispatcher/inc/wlan_pmo_pkt_filter_public_struct.h diff --git a/core/components/pmo/dispatcher/inc/wlan_pmo_tgt_api.h b/components/pmo/dispatcher/inc/wlan_pmo_tgt_api.h similarity index 100% rename from core/components/pmo/dispatcher/inc/wlan_pmo_tgt_api.h rename to components/pmo/dispatcher/inc/wlan_pmo_tgt_api.h diff --git a/core/components/pmo/dispatcher/inc/wlan_pmo_ucfg_api.h b/components/pmo/dispatcher/inc/wlan_pmo_ucfg_api.h similarity index 100% rename from core/components/pmo/dispatcher/inc/wlan_pmo_ucfg_api.h rename to components/pmo/dispatcher/inc/wlan_pmo_ucfg_api.h diff --git a/core/components/pmo/dispatcher/inc/wlan_pmo_wow_public_struct.h b/components/pmo/dispatcher/inc/wlan_pmo_wow_public_struct.h similarity index 100% rename from core/components/pmo/dispatcher/inc/wlan_pmo_wow_public_struct.h rename to components/pmo/dispatcher/inc/wlan_pmo_wow_public_struct.h diff --git a/core/components/pmo/dispatcher/src/wlan_pmo_obj_mgmt_api.c b/components/pmo/dispatcher/src/wlan_pmo_obj_mgmt_api.c similarity index 100% rename from core/components/pmo/dispatcher/src/wlan_pmo_obj_mgmt_api.c rename to components/pmo/dispatcher/src/wlan_pmo_obj_mgmt_api.c diff --git a/core/components/pmo/dispatcher/src/wlan_pmo_tgt_arp.c b/components/pmo/dispatcher/src/wlan_pmo_tgt_arp.c similarity index 100% rename from core/components/pmo/dispatcher/src/wlan_pmo_tgt_arp.c rename to components/pmo/dispatcher/src/wlan_pmo_tgt_arp.c diff --git a/core/components/pmo/dispatcher/src/wlan_pmo_tgt_gtk.c b/components/pmo/dispatcher/src/wlan_pmo_tgt_gtk.c similarity index 100% rename from core/components/pmo/dispatcher/src/wlan_pmo_tgt_gtk.c rename to components/pmo/dispatcher/src/wlan_pmo_tgt_gtk.c diff --git a/core/components/pmo/dispatcher/src/wlan_pmo_tgt_hw_filter.c b/components/pmo/dispatcher/src/wlan_pmo_tgt_hw_filter.c similarity index 100% rename from core/components/pmo/dispatcher/src/wlan_pmo_tgt_hw_filter.c rename to components/pmo/dispatcher/src/wlan_pmo_tgt_hw_filter.c diff --git a/core/components/pmo/dispatcher/src/wlan_pmo_tgt_lphb.c b/components/pmo/dispatcher/src/wlan_pmo_tgt_lphb.c similarity index 100% rename from core/components/pmo/dispatcher/src/wlan_pmo_tgt_lphb.c rename to components/pmo/dispatcher/src/wlan_pmo_tgt_lphb.c diff --git a/core/components/pmo/dispatcher/src/wlan_pmo_tgt_mc_addr_filtering.c b/components/pmo/dispatcher/src/wlan_pmo_tgt_mc_addr_filtering.c similarity index 100% rename from core/components/pmo/dispatcher/src/wlan_pmo_tgt_mc_addr_filtering.c rename to components/pmo/dispatcher/src/wlan_pmo_tgt_mc_addr_filtering.c diff --git a/core/components/pmo/dispatcher/src/wlan_pmo_tgt_ns.c b/components/pmo/dispatcher/src/wlan_pmo_tgt_ns.c similarity index 100% rename from core/components/pmo/dispatcher/src/wlan_pmo_tgt_ns.c rename to components/pmo/dispatcher/src/wlan_pmo_tgt_ns.c diff --git a/core/components/pmo/dispatcher/src/wlan_pmo_tgt_pkt_filter.c b/components/pmo/dispatcher/src/wlan_pmo_tgt_pkt_filter.c similarity index 100% rename from core/components/pmo/dispatcher/src/wlan_pmo_tgt_pkt_filter.c rename to components/pmo/dispatcher/src/wlan_pmo_tgt_pkt_filter.c diff --git a/core/components/pmo/dispatcher/src/wlan_pmo_tgt_static_config.c b/components/pmo/dispatcher/src/wlan_pmo_tgt_static_config.c similarity index 100% rename from core/components/pmo/dispatcher/src/wlan_pmo_tgt_static_config.c rename to components/pmo/dispatcher/src/wlan_pmo_tgt_static_config.c diff --git a/core/components/pmo/dispatcher/src/wlan_pmo_tgt_suspend_resume.c b/components/pmo/dispatcher/src/wlan_pmo_tgt_suspend_resume.c similarity index 100% rename from core/components/pmo/dispatcher/src/wlan_pmo_tgt_suspend_resume.c rename to components/pmo/dispatcher/src/wlan_pmo_tgt_suspend_resume.c diff --git a/core/components/pmo/dispatcher/src/wlan_pmo_tgt_wow.c b/components/pmo/dispatcher/src/wlan_pmo_tgt_wow.c similarity index 100% rename from core/components/pmo/dispatcher/src/wlan_pmo_tgt_wow.c rename to components/pmo/dispatcher/src/wlan_pmo_tgt_wow.c diff --git a/core/components/pmo/dispatcher/src/wlan_pmo_ucfg_api.c b/components/pmo/dispatcher/src/wlan_pmo_ucfg_api.c similarity index 100% rename from core/components/pmo/dispatcher/src/wlan_pmo_ucfg_api.c rename to components/pmo/dispatcher/src/wlan_pmo_ucfg_api.c diff --git a/core/components/target_if/pmo/inc/target_if_pmo.h b/components/target_if/pmo/inc/target_if_pmo.h similarity index 100% rename from core/components/target_if/pmo/inc/target_if_pmo.h rename to components/target_if/pmo/inc/target_if_pmo.h diff --git a/core/components/target_if/pmo/src/target_if_pmo_arp.c b/components/target_if/pmo/src/target_if_pmo_arp.c similarity index 100% rename from core/components/target_if/pmo/src/target_if_pmo_arp.c rename to components/target_if/pmo/src/target_if_pmo_arp.c diff --git a/core/components/target_if/pmo/src/target_if_pmo_gtk.c b/components/target_if/pmo/src/target_if_pmo_gtk.c similarity index 100% rename from core/components/target_if/pmo/src/target_if_pmo_gtk.c rename to components/target_if/pmo/src/target_if_pmo_gtk.c diff --git a/core/components/target_if/pmo/src/target_if_pmo_hw_filter.c b/components/target_if/pmo/src/target_if_pmo_hw_filter.c similarity index 100% rename from core/components/target_if/pmo/src/target_if_pmo_hw_filter.c rename to components/target_if/pmo/src/target_if_pmo_hw_filter.c diff --git a/core/components/target_if/pmo/src/target_if_pmo_lphb.c b/components/target_if/pmo/src/target_if_pmo_lphb.c similarity index 100% rename from core/components/target_if/pmo/src/target_if_pmo_lphb.c rename to components/target_if/pmo/src/target_if_pmo_lphb.c diff --git a/core/components/target_if/pmo/src/target_if_pmo_main.c b/components/target_if/pmo/src/target_if_pmo_main.c similarity index 100% rename from core/components/target_if/pmo/src/target_if_pmo_main.c rename to components/target_if/pmo/src/target_if_pmo_main.c diff --git a/core/components/target_if/pmo/src/target_if_pmo_mc_addr_filtering.c b/components/target_if/pmo/src/target_if_pmo_mc_addr_filtering.c similarity index 100% rename from core/components/target_if/pmo/src/target_if_pmo_mc_addr_filtering.c rename to components/target_if/pmo/src/target_if_pmo_mc_addr_filtering.c diff --git a/core/components/target_if/pmo/src/target_if_pmo_ns.c b/components/target_if/pmo/src/target_if_pmo_ns.c similarity index 100% rename from core/components/target_if/pmo/src/target_if_pmo_ns.c rename to components/target_if/pmo/src/target_if_pmo_ns.c diff --git a/core/components/target_if/pmo/src/target_if_pmo_pkt_filter.c b/components/target_if/pmo/src/target_if_pmo_pkt_filter.c similarity index 100% rename from core/components/target_if/pmo/src/target_if_pmo_pkt_filter.c rename to components/target_if/pmo/src/target_if_pmo_pkt_filter.c diff --git a/core/components/target_if/pmo/src/target_if_pmo_static_config.c b/components/target_if/pmo/src/target_if_pmo_static_config.c similarity index 100% rename from core/components/target_if/pmo/src/target_if_pmo_static_config.c rename to components/target_if/pmo/src/target_if_pmo_static_config.c diff --git a/core/components/target_if/pmo/src/target_if_pmo_suspend_resume.c b/components/target_if/pmo/src/target_if_pmo_suspend_resume.c similarity index 100% rename from core/components/target_if/pmo/src/target_if_pmo_suspend_resume.c rename to components/target_if/pmo/src/target_if_pmo_suspend_resume.c diff --git a/core/components/target_if/pmo/src/target_if_pmo_wow.c b/components/target_if/pmo/src/target_if_pmo_wow.c similarity index 100% rename from core/components/target_if/pmo/src/target_if_pmo_wow.c rename to components/target_if/pmo/src/target_if_pmo_wow.c From 2a54dc402b0e2e1c66f2c1ed2e5c00e5c2f5d7b0 Mon Sep 17 00:00:00 2001 From: snandini Date: Tue, 18 Jul 2017 01:58:53 -0700 Subject: [PATCH 23/34] Release 5.2.0.35E Release 5.2.0.35E Change-Id: I4cbd0656dcea0068e181b06eb648e696e2a87089 CRs-Fixed: 774533 --- core/mac/inc/qwlan_version.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/core/mac/inc/qwlan_version.h b/core/mac/inc/qwlan_version.h index 9f49b6a48117..dc3d4296efd5 100644 --- a/core/mac/inc/qwlan_version.h +++ b/core/mac/inc/qwlan_version.h @@ -41,9 +41,9 @@ #define QWLAN_VERSION_MAJOR 5 #define QWLAN_VERSION_MINOR 2 #define QWLAN_VERSION_PATCH 0 -#define QWLAN_VERSION_EXTRA "D" +#define QWLAN_VERSION_EXTRA "E" #define QWLAN_VERSION_BUILD 35 -#define QWLAN_VERSIONSTR "5.2.0.35D" +#define QWLAN_VERSIONSTR "5.2.0.35E" #endif /* QWLAN_VERSION_H */ From 41a5a77621d58973c9d5cb082231f3381cff5608 Mon Sep 17 00:00:00 2001 From: Ashish Kumar Dhanotiya Date: Thu, 13 Jul 2017 12:42:20 +0530 Subject: [PATCH 24/34] qcacld-3.0: Fix out of bound memory access There is a possibility of OOB memory access within api wlan_hdd_qcmbr_command. To resolve this issue add appropriate buffer length check before using the buffer. Change-Id: I3bc0bb74e07fbf4b5c1f2163c9fb0b80d8839d0d CRs-Fixed: 2075278 --- core/hdd/src/wlan_hdd_ftm.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/core/hdd/src/wlan_hdd_ftm.c b/core/hdd/src/wlan_hdd_ftm.c index 4546e60980b9..67c9b30aa0ea 100644 --- a/core/hdd/src/wlan_hdd_ftm.c +++ b/core/hdd/src/wlan_hdd_ftm.c @@ -186,7 +186,8 @@ static int wlan_hdd_qcmbr_command(hdd_adapter_t *adapter, switch (pqcmbr_data->cmd) { case ATH_XIOCTL_UNIFIED_UTF_CMD: { pqcmbr_data->copy_to_user = 0; - if (pqcmbr_data->length) { + if (pqcmbr_data->length && + pqcmbr_data->length <= sizeof(pqcmbr_data->buf)) { if (wlan_hdd_ftm_testmode_cmd(pqcmbr_data->buf, pqcmbr_data-> length) From 7810c7708208d1b72a17be03cba1bcb26ccc365d Mon Sep 17 00:00:00 2001 From: snandini Date: Tue, 18 Jul 2017 03:49:25 -0700 Subject: [PATCH 25/34] Release 5.2.0.35F Release 5.2.0.35F Change-Id: I1bb3517717e520a09a8ea4faeb422d984f30e719 CRs-Fixed: 774533 --- core/mac/inc/qwlan_version.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/core/mac/inc/qwlan_version.h b/core/mac/inc/qwlan_version.h index dc3d4296efd5..308d5ed6473a 100644 --- a/core/mac/inc/qwlan_version.h +++ b/core/mac/inc/qwlan_version.h @@ -41,9 +41,9 @@ #define QWLAN_VERSION_MAJOR 5 #define QWLAN_VERSION_MINOR 2 #define QWLAN_VERSION_PATCH 0 -#define QWLAN_VERSION_EXTRA "E" +#define QWLAN_VERSION_EXTRA "F" #define QWLAN_VERSION_BUILD 35 -#define QWLAN_VERSIONSTR "5.2.0.35E" +#define QWLAN_VERSIONSTR "5.2.0.35F" #endif /* QWLAN_VERSION_H */ From 2972b6e3cbd366b4fd6cc6a5ff0946c2152167d9 Mon Sep 17 00:00:00 2001 From: Sreelakshmi Konamki Date: Mon, 17 Jul 2017 12:10:36 +0530 Subject: [PATCH 26/34] qcacld-3.0: Do not remove addts/delts command in csr_roam_sync_callback Currently addts and delts commands are removed as part of csr_roam_sync_callback. After successful roaming add_tspec of old connection is not processed in SME (entry of addts command is NULL in smeCmdActiveList). As there is no active add tspec in SME, VO data is downgraded to BE. To fix above issue, do not remove addts/delts commands from SME queue and in PE layer do the error handling for addts to send resp for all failure cases. Change-Id: Ibc7364d188c3002dd8067738f6bcc8fee2af2126 CRs-Fixed: 2076713 --- .../src/pe/lim/lim_process_sme_req_messages.c | 43 +++++++------------ core/sme/inc/sme_qos_internal.h | 11 ----- core/sme/src/csr/csr_api_roam.c | 1 - core/sme/src/qos/sme_qos.c | 21 --------- 4 files changed, 15 insertions(+), 61 deletions(-) diff --git a/core/mac/src/pe/lim/lim_process_sme_req_messages.c b/core/mac/src/pe/lim/lim_process_sme_req_messages.c index e9d23e1297fb..b4253308a3f4 100644 --- a/core/mac/src/pe/lim/lim_process_sme_req_messages.c +++ b/core/mac/src/pe/lim/lim_process_sme_req_messages.c @@ -3569,10 +3569,7 @@ static void __lim_process_sme_addts_req(tpAniSirGlobal pMac, uint32_t *pMsgBuf) if (!LIM_IS_STA_ROLE(psessionEntry)) { pe_err("AddTs received on AP - ignoring"); - lim_send_sme_addts_rsp(pMac, pSirAddts->rspReqd, eSIR_FAILURE, - psessionEntry, pSirAddts->req.tspec, - smesessionId, smetransactionId); - return; + goto send_failure_addts_rsp; } pStaDs = @@ -3581,19 +3578,13 @@ static void __lim_process_sme_addts_req(tpAniSirGlobal pMac, uint32_t *pMsgBuf) if (pStaDs == NULL) { pe_err("Cannot find AP context for addts req"); - lim_send_sme_addts_rsp(pMac, pSirAddts->rspReqd, eSIR_FAILURE, - psessionEntry, pSirAddts->req.tspec, - smesessionId, smetransactionId); - return; + goto send_failure_addts_rsp; } if ((!pStaDs->valid) || (pStaDs->mlmStaContext.mlmState != eLIM_MLM_LINK_ESTABLISHED_STATE)) { pe_err("AddTs received in invalid MLM state"); - lim_send_sme_addts_rsp(pMac, pSirAddts->rspReqd, eSIR_FAILURE, - psessionEntry, pSirAddts->req.tspec, - smesessionId, smetransactionId); - return; + goto send_failure_addts_rsp; } pSirAddts->req.wsmTspecPresent = 0; @@ -3610,20 +3601,14 @@ static void __lim_process_sme_addts_req(tpAniSirGlobal pMac, uint32_t *pMsgBuf) pSirAddts->req.lleTspecPresent = 1; else { pe_warn("ADDTS_REQ ignore - qos is disabled"); - lim_send_sme_addts_rsp(pMac, pSirAddts->rspReqd, eSIR_FAILURE, - psessionEntry, pSirAddts->req.tspec, - smesessionId, smetransactionId); - return; + goto send_failure_addts_rsp; } if ((psessionEntry->limSmeState != eLIM_SME_ASSOCIATED_STATE) && (psessionEntry->limSmeState != eLIM_SME_LINK_EST_STATE)) { pe_err("AddTs received in invalid LIMsme state (%d)", psessionEntry->limSmeState); - lim_send_sme_addts_rsp(pMac, pSirAddts->rspReqd, eSIR_FAILURE, - psessionEntry, pSirAddts->req.tspec, - smesessionId, smetransactionId); - return; + goto send_failure_addts_rsp; } if (pMac->lim.gLimAddtsSent) { @@ -3632,10 +3617,7 @@ static void __lim_process_sme_addts_req(tpAniSirGlobal pMac, uint32_t *pMsgBuf) pMac->lim.gLimAddtsReq.req.tspec.tsinfo.traffic.tsid, pMac->lim.gLimAddtsReq.req.tspec.tsinfo.traffic. userPrio); - lim_send_sme_addts_rsp(pMac, pSirAddts->rspReqd, eSIR_FAILURE, - psessionEntry, pSirAddts->req.tspec, - smesessionId, smetransactionId); - return; + goto send_failure_addts_rsp; } sir_copy_mac_addr(peerMac, psessionEntry->bssId); @@ -3656,21 +3638,21 @@ static void __lim_process_sme_addts_req(tpAniSirGlobal pMac, uint32_t *pMsgBuf) eSIR_SUCCESS) { pe_err("Unable to get Cfg param %d (Addts Rsp Timeout)", WNI_CFG_ADDTS_RSP_TIMEOUT); - return; + goto send_failure_addts_rsp; } timeout = SYS_MS_TO_TICKS(timeout); if (tx_timer_change(&pMac->lim.limTimers.gLimAddtsRspTimer, timeout, 0) != TX_SUCCESS) { pe_err("AddtsRsp timer change failed!"); - return; + goto send_failure_addts_rsp; } pMac->lim.gLimAddtsRspTimerCount++; if (tx_timer_change_context(&pMac->lim.limTimers.gLimAddtsRspTimer, pMac->lim.gLimAddtsRspTimerCount) != TX_SUCCESS) { pe_err("AddtsRsp timer change failed!"); - return; + goto send_failure_addts_rsp; } MTRACE(mac_trace (pMac, TRACE_CODE_TIMER_ACTIVATE, psessionEntry->peSessionId, @@ -3681,9 +3663,14 @@ static void __lim_process_sme_addts_req(tpAniSirGlobal pMac, uint32_t *pMsgBuf) if (tx_timer_activate(&pMac->lim.limTimers.gLimAddtsRspTimer) != TX_SUCCESS) { pe_err("AddtsRsp timer activation failed!"); - return; + goto send_failure_addts_rsp; } return; + +send_failure_addts_rsp: + lim_send_sme_addts_rsp(pMac, pSirAddts->rspReqd, eSIR_FAILURE, + psessionEntry, pSirAddts->req.tspec, + smesessionId, smetransactionId); } static void __lim_process_sme_delts_req(tpAniSirGlobal pMac, uint32_t *pMsgBuf) diff --git a/core/sme/inc/sme_qos_internal.h b/core/sme/inc/sme_qos_internal.h index 109fd50cfa67..9c66febfa6ea 100644 --- a/core/sme/inc/sme_qos_internal.h +++ b/core/sme/inc/sme_qos_internal.h @@ -123,17 +123,6 @@ QDF_STATUS sme_qos_msg_processor(tpAniSirGlobal pMac, uint16_t msg_type, ------------------------------------------------------------------------*/ QDF_STATUS sme_qos_validate_params(tpAniSirGlobal pMac, tSirBssDescription *pBssDesc); -/** - * sme_qos_remove_addts_delts_cmd - Remove addts/delts command - * @mac_ctx: Pointer to the global MAC structure. - * @session_id: Session id - * - * This function is used to remove addts/delts command - * during csr roam sync callback. - * - * Return: void - */ -void sme_qos_remove_addts_delts_cmd(tpAniSirGlobal mac_ctx, uint8_t session_id); QDF_STATUS sme_qos_csr_event_ind(tpAniSirGlobal pMac, uint8_t sessionId, sme_qos_csr_event_indType ind, void *pEvent_info); diff --git a/core/sme/src/csr/csr_api_roam.c b/core/sme/src/csr/csr_api_roam.c index 4f622bf83ebf..77d89deb2c20 100644 --- a/core/sme/src/csr/csr_api_roam.c +++ b/core/sme/src/csr/csr_api_roam.c @@ -19987,7 +19987,6 @@ static QDF_STATUS csr_process_roam_sync_callback(tpAniSirGlobal mac_ctx, eCSR_ASSOC_STATE_TYPE_INFRA_ASSOCIATED; sme_qos_csr_event_ind(mac_ctx, session_id, SME_QOS_CSR_REASSOC_COMPLETE, &assoc_info); - sme_qos_remove_addts_delts_cmd(mac_ctx, session_id); roam_info->pBssDesc = bss_desc; conn_profile->acm_mask = sme_qos_get_acm_mask(mac_ctx, bss_desc, NULL); diff --git a/core/sme/src/qos/sme_qos.c b/core/sme/src/qos/sme_qos.c index bf0d34686e35..b5bbe98017c1 100644 --- a/core/sme/src/qos/sme_qos.c +++ b/core/sme/src/qos/sme_qos.c @@ -908,27 +908,6 @@ QDF_STATUS sme_qos_validate_params(tpAniSirGlobal pMac, return status; } -void sme_qos_remove_addts_delts_cmd(tpAniSirGlobal mac_ctx, uint8_t session_id) -{ - tListElem *entry; - tSmeCmd *command; - - entry = csr_nonscan_active_ll_peek_head(mac_ctx, LL_ACCESS_LOCK); - if (NULL == entry) - return; - command = GET_BASE_ADDR(entry, tSmeCmd, Link); - if ((eSmeCommandAddTs == command->command || - eSmeCommandDelTs == command->command) && - command->sessionId == session_id) { - if (csr_nonscan_active_ll_remove_entry(mac_ctx, entry, - LL_ACCESS_LOCK)) { - QDF_TRACE(QDF_MODULE_ID_SME, QDF_TRACE_LEVEL_INFO, - "%s: removed addts/delts command", __func__); - qos_release_command(mac_ctx, command); - } - } -} - /*-------------------------------------------------------------------------- \brief sme_qos_csr_event_ind() - The QoS sub-module in SME expects notifications from CSR when certain events occur as mentioned in sme_qos_csr_event_indType. From 57ce4dfde2b3ca03cb5afeb20959ae2a82c492a4 Mon Sep 17 00:00:00 2001 From: "Selvaraj, Sridhar" Date: Mon, 29 May 2017 18:30:49 +0530 Subject: [PATCH 27/34] qcacld-3.0: Add ini params to avoid roam ping pong MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit In roaming scenario, to avoid ping pong with bad AP’s around, fw blacklist certain Ap’s based on timestamps and penalize certain AP’s of the same channel so they won’t be selected and back and forth roaming could be avoided. This change adds the following INI parametres to configure the parametres of this fw feature. 1) groam_disallow_duration - Amount of time LCA[Last Connected AP] will be disallowed before it can be a roaming candidate again. 2) grssi_channel_penalization - RSSI to be penalized if candidate(s) are found in the same channel as disallowed AP's. 3) groam_num_disallowed_aps - number of AP's the target should maintain in its LCA list. Change-Id: I41cb36caf1b42caeb2bf77846bd0279eb43d2018 CRs-Fixed: 2054188 --- core/hdd/inc/wlan_hdd_cfg.h | 69 +++++++++++++++++++++++++++++++++ core/hdd/src/wlan_hdd_cfg.c | 37 ++++++++++++++++++ core/mac/inc/sir_api.h | 15 +++++++ core/sme/inc/csr_api.h | 3 ++ core/sme/inc/csr_internal.h | 3 ++ core/sme/src/csr/csr_api_roam.c | 35 ++++++++++++++--- core/wma/src/wma_scan_roam.c | 20 ++++++++++ 7 files changed, 176 insertions(+), 6 deletions(-) diff --git a/core/hdd/inc/wlan_hdd_cfg.h b/core/hdd/inc/wlan_hdd_cfg.h index 5375635c7c70..07f28b07388b 100644 --- a/core/hdd/inc/wlan_hdd_cfg.h +++ b/core/hdd/inc/wlan_hdd_cfg.h @@ -10456,6 +10456,70 @@ enum hdd_external_acs_freq_band { #define CFG_ITO_REPEAT_COUNT_MIN (0) #define CFG_ITO_REPEAT_COUNT_MAX (5) #define CFG_ITO_REPEAT_COUNT_DEFAULT (0) +/* + * + * groam_disallow_duration -disallow duration before roaming + * @Min: 0 + * @Max: 3600 + * @Default: 30 + * + * This ini is used to configure how long LCA[Last Connected AP] AP will + * be disallowed before it can be a roaming candidate again, in units of + * seconds. + * + * Related: LFR + * + * Usage: Internal + * + * + */ +#define CFG_ROAM_DISALLOW_DURATION_NAME "groam_disallow_duration" +#define CFG_ROAM_DISALLOW_DURATION_MIN (0) +#define CFG_ROAM_DISALLOW_DURATION_MAX (3600) +#define CFG_ROAM_DISALLOW_DURATION_DEFAULT (30) + +/* + * + * grssi_channel_penalization - RSSI penalization + * @Min: 0 + * @Max: 15 + * @Default: 5 + * + * This ini is used to configure RSSI that will be penalized if candidate(s) + * are found to be in the same channel as disallowed AP's, in units of db. + * + * Related: LFR + * + * Usage: Internal + * + * + */ +#define CFG_ROAM_RSSI_CHANNEL_PENALIZATION_NAME "grssi_channel_penalization" +#define CFG_ROAM_RSSI_CHANNEL_PENALIZATION_MIN (0) +#define CFG_ROAM_RSSI_CHANNEL_PENALIZATION_MAX (15) +#define CFG_ROAM_RSSI_CHANNEL_PENALIZATION_DEFAULT (5) + +/* + * + * groam_num_disallowed_aps - Max number of AP's to maintain in LCA list + * @Min: 0 + * @Max: 8 + * @Default: 3 + * + * This ini is used to set the maximum number of AP's to be maintained + * in LCA [Last Connected AP] list. + * + * Related: LFR + * + * Usage: Internal + * + * + */ +#define CFG_ROAM_NUM_DISALLOWED_APS_NAME "groam_num_disallowed_aps" +#define CFG_ROAM_NUM_DISALLOWED_APS_MIN (0) +#define CFG_ROAM_NUM_DISALLOWED_APS_MAX (8) +#define CFG_ROAM_NUM_DISALLOWED_APS_DEFAULT (3) + /* * Type declarations */ @@ -11200,6 +11264,11 @@ struct hdd_config { uint16_t num_11b_tx_chains; uint16_t num_11ag_tx_chains; uint8_t ito_repeat_count; + + /* LCA(Last connected AP) disallow configs */ + uint32_t disallow_duration; + uint32_t rssi_channel_penalization; + uint32_t num_disallowed_aps; }; #define VAR_OFFSET(_Struct, _Var) (offsetof(_Struct, _Var)) diff --git a/core/hdd/src/wlan_hdd_cfg.c b/core/hdd/src/wlan_hdd_cfg.c index e84b0c9691e7..6e69b7206480 100644 --- a/core/hdd/src/wlan_hdd_cfg.c +++ b/core/hdd/src/wlan_hdd_cfg.c @@ -4463,6 +4463,27 @@ struct reg_table_entry g_registry_table[] = { CFG_ITO_REPEAT_COUNT_MIN, CFG_ITO_REPEAT_COUNT_MAX), + REG_VARIABLE(CFG_ROAM_DISALLOW_DURATION_NAME, WLAN_PARAM_Integer, + struct hdd_config, disallow_duration, + VAR_FLAGS_OPTIONAL | VAR_FLAGS_RANGE_CHECK_ASSUME_DEFAULT, + CFG_ROAM_DISALLOW_DURATION_DEFAULT, + CFG_ROAM_DISALLOW_DURATION_MIN, + CFG_ROAM_DISALLOW_DURATION_MAX), + + REG_VARIABLE(CFG_ROAM_RSSI_CHANNEL_PENALIZATION_NAME, + WLAN_PARAM_Integer, struct hdd_config, + rssi_channel_penalization, + VAR_FLAGS_OPTIONAL | VAR_FLAGS_RANGE_CHECK_ASSUME_DEFAULT, + CFG_ROAM_RSSI_CHANNEL_PENALIZATION_DEFAULT, + CFG_ROAM_RSSI_CHANNEL_PENALIZATION_MIN, + CFG_ROAM_RSSI_CHANNEL_PENALIZATION_MAX), + + REG_VARIABLE(CFG_ROAM_NUM_DISALLOWED_APS_NAME, WLAN_PARAM_Integer, + struct hdd_config, num_disallowed_aps, + VAR_FLAGS_OPTIONAL | VAR_FLAGS_RANGE_CHECK_ASSUME_DEFAULT, + CFG_ROAM_NUM_DISALLOWED_APS_DEFAULT, + CFG_ROAM_NUM_DISALLOWED_APS_MIN, + CFG_ROAM_NUM_DISALLOWED_APS_MAX), }; @@ -6004,6 +6025,15 @@ void hdd_cfg_print(hdd_context_t *pHddCtx) hdd_debug("Name = [%s] value = [%u]", CFG_ITO_REPEAT_COUNT_NAME, pHddCtx->config->ito_repeat_count); + hdd_debug("Name = [%s] Value = [%u]", + CFG_ROAM_DISALLOW_DURATION_NAME, + pHddCtx->config->disallow_duration); + hdd_debug("Name = [%s] Value = [%u]", + CFG_ROAM_RSSI_CHANNEL_PENALIZATION_NAME, + pHddCtx->config->rssi_channel_penalization); + hdd_debug("Name = [%s] Value = [%u]", + CFG_ROAM_NUM_DISALLOWED_APS_NAME, + pHddCtx->config->num_disallowed_aps); } @@ -7626,6 +7656,13 @@ QDF_STATUS hdd_set_sme_config(hdd_context_t *pHddCtx) smeConfig->csrConfig.pkt_err_disconn_th = pHddCtx->config->pkt_err_disconn_th; + smeConfig->csrConfig.disallow_duration = + pHddCtx->config->disallow_duration; + smeConfig->csrConfig.rssi_channel_penalization = + pHddCtx->config->rssi_channel_penalization; + smeConfig->csrConfig.num_disallowed_aps = + pHddCtx->config->num_disallowed_aps; + smeConfig->csrConfig.is_force_1x1 = pHddCtx->config->is_force_1x1; smeConfig->csrConfig.num_11b_tx_chains = diff --git a/core/mac/inc/sir_api.h b/core/mac/inc/sir_api.h index bfe2ce0a94f7..1dc99e34558b 100644 --- a/core/mac/inc/sir_api.h +++ b/core/mac/inc/sir_api.h @@ -2983,6 +2983,20 @@ struct pmkid_mode_bits { uint32_t unused:30; }; +/** + * struct lca_disallow_config_params - LCA[Last Connected AP] + * disallow config params + * @disallow_duration: LCA AP disallowed duration + * @rssi_channel_penalization: RSSI channel Penalization + * @num_disallowed_aps: Maximum number of AP's in LCA list + * + */ +struct lca_disallow_config_params{ + uint32_t disallow_duration; + uint32_t rssi_channel_penalization; + uint32_t num_disallowed_aps; +}; + typedef struct sSirRoamOffloadScanReq { uint16_t message_type; uint16_t length; @@ -3040,6 +3054,7 @@ typedef struct sSirRoamOffloadScanReq { int8_t early_stop_scan_max_threshold; enum wmi_dwelltime_adaptive_mode roamscan_adaptive_dwell_mode; tSirAddie assoc_ie; + struct lca_disallow_config_params lca_config_params; } tSirRoamOffloadScanReq, *tpSirRoamOffloadScanReq; typedef struct sSirRoamOffloadScanRsp { diff --git a/core/sme/inc/csr_api.h b/core/sme/inc/csr_api.h index 837a4e39b79e..14eb6e80e8a3 100644 --- a/core/sme/inc/csr_api.h +++ b/core/sme/inc/csr_api.h @@ -1319,6 +1319,9 @@ typedef struct tagCsrConfigParam { bool is_force_1x1; uint16_t num_11b_tx_chains; uint16_t num_11ag_tx_chains; + uint32_t disallow_duration; + uint32_t rssi_channel_penalization; + uint32_t num_disallowed_aps; } tCsrConfigParam; /* Tush */ diff --git a/core/sme/inc/csr_internal.h b/core/sme/inc/csr_internal.h index e4ee1c6ac2f5..f0edfd7305dc 100644 --- a/core/sme/inc/csr_internal.h +++ b/core/sme/inc/csr_internal.h @@ -624,6 +624,9 @@ typedef struct tagCsrConfig { bool is_force_1x1; uint16_t num_11b_tx_chains; uint16_t num_11ag_tx_chains; + uint32_t disallow_duration; + uint32_t rssi_channel_penalization; + uint32_t num_disallowed_aps; } tCsrConfig; typedef struct tagCsrChannelPowerInfo { diff --git a/core/sme/src/csr/csr_api_roam.c b/core/sme/src/csr/csr_api_roam.c index 77d89deb2c20..34e6256b8413 100644 --- a/core/sme/src/csr/csr_api_roam.c +++ b/core/sme/src/csr/csr_api_roam.c @@ -2788,6 +2788,12 @@ QDF_STATUS csr_change_default_config_param(tpAniSirGlobal pMac, pParam->qcn_ie_support; pMac->roam.configParam.fils_max_chan_guard_time = pParam->fils_max_chan_guard_time; + pMac->roam.configParam.disallow_duration = + pParam->disallow_duration; + pMac->roam.configParam.rssi_channel_penalization = + pParam->rssi_channel_penalization; + pMac->roam.configParam.num_disallowed_aps = + pParam->num_disallowed_aps; csr_update_he_config_param(pMac, pParam); } @@ -3027,6 +3033,12 @@ QDF_STATUS csr_get_config_param(tpAniSirGlobal pMac, tCsrConfigParam *pParam) pMac->roam.configParam.qcn_ie_support; pParam->fils_max_chan_guard_time = pMac->roam.configParam.fils_max_chan_guard_time; + pParam->disallow_duration = + pMac->roam.configParam.disallow_duration; + pParam->rssi_channel_penalization = + pMac->roam.configParam.rssi_channel_penalization; + pParam->num_disallowed_aps = + pMac->roam.configParam.num_disallowed_aps; csr_get_he_config_param(pParam, pMac); @@ -17211,15 +17223,26 @@ csr_create_roam_scan_offload_request(tpAniSirGlobal mac_ctx, mac_ctx->roam.configParam.early_stop_scan_min_threshold; req_buf->early_stop_scan_max_threshold = mac_ctx->roam.configParam.early_stop_scan_max_threshold; - QDF_TRACE(QDF_MODULE_ID_SME, QDF_TRACE_LEVEL_DEBUG, - FL("HomeAwayTime=%d EarlyStopFeature Enable=%d, MinThresh=%d, MaxThresh=%d PMK len=%d"), - req_buf->HomeAwayTime, req_buf->early_stop_scan_enable, - req_buf->early_stop_scan_min_threshold, - req_buf->early_stop_scan_max_threshold, - req_buf->pmk_len); req_buf->roamscan_adaptive_dwell_mode = mac_ctx->roam.configParam.roamscan_adaptive_dwell_mode; + req_buf->lca_config_params.disallow_duration = + mac_ctx->roam.configParam.disallow_duration; + req_buf->lca_config_params.rssi_channel_penalization = + mac_ctx->roam.configParam.rssi_channel_penalization; + req_buf->lca_config_params.num_disallowed_aps = + mac_ctx->roam.configParam.num_disallowed_aps; + #ifdef WLAN_FEATURE_ROAM_OFFLOAD + QDF_TRACE(QDF_MODULE_ID_SME, QDF_TRACE_LEVEL_DEBUG, + FL("HomeAwayTime=%d EarlyStopFeature Enable=%d, MinThresh=%d, MaxThresh=%d PMK len=%d disallow_dur=%d rssi_chan_pen=%d num_disallowed_aps=%d"), + req_buf->HomeAwayTime, + req_buf->early_stop_scan_enable, + req_buf->early_stop_scan_min_threshold, + req_buf->early_stop_scan_max_threshold, + req_buf->pmk_len, + req_buf->lca_config_params.disallow_duration, + req_buf->lca_config_params.rssi_channel_penalization, + req_buf->lca_config_params.num_disallowed_aps); req_buf->RoamOffloadEnabled = csr_roamIsRoamOffloadEnabled(mac_ctx); req_buf->RoamKeyMgmtOffloadEnabled = session->RoamKeyMgmtOffloadEnabled; req_buf->pmkid_modes = session->pmkid_modes; diff --git a/core/wma/src/wma_scan_roam.c b/core/wma/src/wma_scan_roam.c index ce4fb7e60f7a..65276c1cf9ec 100644 --- a/core/wma/src/wma_scan_roam.c +++ b/core/wma/src/wma_scan_roam.c @@ -1582,6 +1582,7 @@ static QDF_STATUS wma_roam_scan_filter(tp_wma_handle wma_handle, uint32_t op_bitmap = 0; struct roam_ext_params *roam_params; struct roam_scan_filter_params *params; + struct lca_disallow_config_params *lca_config_params; params = qdf_mem_malloc(sizeof(struct roam_scan_filter_params)); if (params == NULL) { @@ -1590,6 +1591,7 @@ static QDF_STATUS wma_roam_scan_filter(tp_wma_handle wma_handle, } roam_params = &roam_req->roam_params; + lca_config_params = &roam_req->lca_config_params; if (roam_req->Command != ROAM_SCAN_OFFLOAD_STOP) { switch (roam_req->reason) { case REASON_ROAM_SET_BLACKLIST_BSSID: @@ -1607,6 +1609,16 @@ static QDF_STATUS wma_roam_scan_filter(tp_wma_handle wma_handle, num_bssid_preferred_list = roam_params->num_bssid_favored; break; + case REASON_CTX_INIT: + if (roam_req->Command == ROAM_SCAN_OFFLOAD_START) { + params->lca_disallow_config_present = true; + op_bitmap |= ROAM_FILTER_OP_BITMAP_LCA_DISALLOW; + } else { + WMA_LOGD("%s : Roam Filter need not be sent", __func__); + qdf_mem_free(params); + return QDF_STATUS_SUCCESS; + } + break; default: WMA_LOGD("%s : Roam Filter need not be sent", __func__); qdf_mem_free(params); @@ -1648,6 +1660,14 @@ static QDF_STATUS wma_roam_scan_filter(tp_wma_handle wma_handle, qdf_mem_copy(params->bssid_favored_factor, roam_params->bssid_favored_factor, MAX_BSSID_FAVORED); + if (params->lca_disallow_config_present) { + params->disallow_duration + = lca_config_params->disallow_duration; + params->rssi_channel_penalization + = lca_config_params->rssi_channel_penalization; + params->num_disallowed_aps + = lca_config_params->num_disallowed_aps; + } status = wmi_unified_roam_scan_filter_cmd(wma_handle->wmi_handle, params); From 558f8085c4a01de1ac8b596cffde5b714687ebcd Mon Sep 17 00:00:00 2001 From: Will Huang Date: Wed, 31 May 2017 16:22:24 +0800 Subject: [PATCH 28/34] qcacld-3.0: Add support of request peer stats info(part 2) qcacld-2.0 to qcacld-3.0 propagation FW has limitation to support old WMI_REQUEST_STATS_CMDID and WMI_UPDATE_STATS_EVENTID interface on AP vDev. FW suggest to use new WMI_REQUEST_PEER_STATS_INFO_CMDID and WMI_PEER_STATS_INFO_EVENTID to get tx/rx rate. This checkin is about LIM/SME/SAP layer, provide SME APIs/callbacks to HDD layer to get SAP's peer station tx/rx related information, fill these information from wma layer get-peer-stat-info APIs and peer station's association request frame. It also fixed function csr_send_assoc_ind_to_upper_layer_cnf_msg when copy information between different structures and using offset style. Change-Id: Icb1aaa126663af7eaedd1c4db86ca25c40ce6ee9 CRs-Fixed: 2051628 --- core/mac/inc/sir_api.h | 17 +++ .../src/pe/lim/lim_process_assoc_req_frame.c | 96 ++++++++++++++++ .../src/pe/lim/lim_process_mlm_rsp_messages.c | 11 ++ core/mac/src/pe/lim/lim_types.h | 11 ++ .../src/sys/legacy/src/utils/src/mac_trace.c | 2 + core/sap/inc/sap_api.h | 11 ++ core/sap/src/sap_fsm.c | 11 ++ core/sme/inc/csr_api.h | 22 ++++ core/sme/inc/sme_api.h | 33 ++++++ core/sme/inc/sme_internal.h | 8 ++ core/sme/src/common/sme_api.c | 106 ++++++++++++++++++ core/sme/src/csr/csr_api_roam.c | 103 ++++++++++++----- 12 files changed, 403 insertions(+), 28 deletions(-) diff --git a/core/mac/inc/sir_api.h b/core/mac/inc/sir_api.h index 1dc99e34558b..e30acfd1d330 100644 --- a/core/mac/inc/sir_api.h +++ b/core/mac/inc/sir_api.h @@ -1287,6 +1287,12 @@ typedef struct sSirSmeChanInfo { enum phy_ch_width ch_width; } tSirSmeChanInfo, *tpSirSmeChanInfo; +enum sir_sme_phy_mode { + SIR_SME_PHY_MODE_LEGACY = 0, + SIR_SME_PHY_MODE_HT = 1, + SIR_SME_PHY_MODE_VHT = 2 +}; + /* / Definition for Association indication from peer */ /* / MAC ---> */ typedef struct sSirSmeAssocInd { @@ -1324,6 +1330,17 @@ typedef struct sSirSmeAssocInd { /* Timing measurement capability */ uint8_t timingMeasCap; tSirSmeChanInfo chan_info; + bool ampdu; + bool sgi_enable; + bool tx_stbc; + bool rx_stbc; + tSirMacHTChannelWidth ch_width; + enum sir_sme_phy_mode mode; + uint8_t max_supp_idx; + uint8_t max_ext_idx; + uint8_t max_mcs_idx; + uint8_t rx_mcs_map; + uint8_t tx_mcs_map; } tSirSmeAssocInd, *tpSirSmeAssocInd; /* / Definition for Association confirm */ diff --git a/core/mac/src/pe/lim/lim_process_assoc_req_frame.c b/core/mac/src/pe/lim/lim_process_assoc_req_frame.c index d13d49aeca2a..9c39b71e694a 100644 --- a/core/mac/src/pe/lim/lim_process_assoc_req_frame.c +++ b/core/mac/src/pe/lim/lim_process_assoc_req_frame.c @@ -2110,6 +2110,50 @@ static void lim_fill_assoc_ind_vht_info(tpAniSirGlobal mac_ctx, return; } +static uint8_t lim_get_max_rate_idx(tSirMacRateSet *rateset) +{ + uint8_t maxidx; + int i; + + maxidx = rateset->rate[0] & 0x7f; + for (i = 1; i < rateset->numRates; i++) { + if ((rateset->rate[i] & 0x7f) > maxidx) + maxidx = rateset->rate[i] & 0x7f; + } + + return maxidx; +} + +static void fill_mlm_assoc_ind_vht(tpSirAssocReq assocreq, + tpDphHashNode stads, + tpLimMlmAssocInd assocind) +{ + if (stads->mlmStaContext.vhtCapability) { + /* ampdu */ + assocind->ampdu = true; + + /* sgi */ + if (assocreq->VHTCaps.shortGI80MHz || + assocreq->VHTCaps.shortGI160and80plus80MHz) + assocind->sgi_enable = true; + + /* stbc */ + assocind->tx_stbc = assocreq->VHTCaps.txSTBC; + assocind->rx_stbc = assocreq->VHTCaps.rxSTBC; + + /* ch width */ + assocind->ch_width = stads->vhtSupportedChannelWidthSet ? + eHT_CHANNEL_WIDTH_80MHZ : + stads->htSupportedChannelWidthSet ? + eHT_CHANNEL_WIDTH_40MHZ : eHT_CHANNEL_WIDTH_20MHZ; + + /* mode */ + assocind->mode = SIR_SME_PHY_MODE_VHT; + assocind->rx_mcs_map = assocreq->VHTCaps.rxMCSMap & 0xff; + assocind->tx_mcs_map = assocreq->VHTCaps.txMCSMap & 0xff; + } +} + /** * lim_send_mlm_assoc_ind() - Sends assoc indication to SME * @mac_ctx: Global Mac context @@ -2130,6 +2174,7 @@ void lim_send_mlm_assoc_ind(tpAniSirGlobal mac_ctx, uint32_t phy_mode; uint8_t sub_type; uint8_t *wpsie = NULL; + uint8_t maxidx, i; uint32_t tmp; /* Get a copy of the already parsed Assoc Request */ @@ -2295,6 +2340,57 @@ void lim_send_mlm_assoc_ind(tpAniSirGlobal mac_ctx, assoc_ind->chan_info.nss = sta_ds->nss; assoc_ind->chan_info.rate_flags = lim_get_max_rate_flags(mac_ctx, sta_ds); + assoc_ind->ampdu = false; + assoc_ind->sgi_enable = false; + assoc_ind->tx_stbc = false; + assoc_ind->rx_stbc = false; + assoc_ind->ch_width = eHT_CHANNEL_WIDTH_20MHZ; + assoc_ind->mode = SIR_SME_PHY_MODE_LEGACY; + assoc_ind->max_supp_idx = 0xff; + assoc_ind->max_ext_idx = 0xff; + assoc_ind->max_mcs_idx = 0xff; + assoc_ind->rx_mcs_map = 0xff; + assoc_ind->tx_mcs_map = 0xff; + + if (assoc_req->supportedRates.numRates) + assoc_ind->max_supp_idx = + lim_get_max_rate_idx( + &assoc_req->supportedRates); + if (assoc_req->extendedRates.numRates) + assoc_ind->max_ext_idx = + lim_get_max_rate_idx( + &assoc_req->extendedRates); + + if (sta_ds->mlmStaContext.htCapability) { + /* ampdu */ + assoc_ind->ampdu = true; + + /* sgi */ + if (sta_ds->htShortGI20Mhz || sta_ds->htShortGI40Mhz) + assoc_ind->sgi_enable = true; + + /* stbc */ + assoc_ind->tx_stbc = assoc_req->HTCaps.txSTBC; + assoc_ind->rx_stbc = assoc_req->HTCaps.rxSTBC; + + /* ch width */ + assoc_ind->ch_width = + sta_ds->htSupportedChannelWidthSet ? + eHT_CHANNEL_WIDTH_40MHZ : + eHT_CHANNEL_WIDTH_20MHZ; + + /* mode */ + assoc_ind->mode = SIR_SME_PHY_MODE_HT; + maxidx = 0; + for (i = 0; i < 8; i++) { + if (assoc_req->HTCaps.supportedMCSSet[0] & + (1 << i)) + maxidx = i; + } + assoc_ind->max_mcs_idx = maxidx; + } + fill_mlm_assoc_ind_vht(assoc_req, sta_ds, assoc_ind); + /* updates VHT information in assoc indication */ lim_fill_assoc_ind_vht_info(mac_ctx, session_entry, assoc_req, assoc_ind); diff --git a/core/mac/src/pe/lim/lim_process_mlm_rsp_messages.c b/core/mac/src/pe/lim/lim_process_mlm_rsp_messages.c index fda70245cb5e..209e209aa61c 100644 --- a/core/mac/src/pe/lim/lim_process_mlm_rsp_messages.c +++ b/core/mac/src/pe/lim/lim_process_mlm_rsp_messages.c @@ -772,6 +772,17 @@ lim_fill_assoc_ind_params(tpAniSirGlobal mac_ctx, sizeof(tSirSmeChanInfo)); /* Fill in WmmInfo */ sme_assoc_ind->wmmEnabledSta = assoc_ind->WmmStaInfoPresent; + sme_assoc_ind->ampdu = assoc_ind->ampdu; + sme_assoc_ind->sgi_enable = assoc_ind->sgi_enable; + sme_assoc_ind->tx_stbc = assoc_ind->tx_stbc; + sme_assoc_ind->rx_stbc = assoc_ind->rx_stbc; + sme_assoc_ind->ch_width = assoc_ind->ch_width; + sme_assoc_ind->mode = assoc_ind->mode; + sme_assoc_ind->max_supp_idx = assoc_ind->max_supp_idx; + sme_assoc_ind->max_ext_idx = assoc_ind->max_ext_idx; + sme_assoc_ind->max_mcs_idx = assoc_ind->max_mcs_idx; + sme_assoc_ind->rx_mcs_map = assoc_ind->rx_mcs_map; + sme_assoc_ind->tx_mcs_map = assoc_ind->tx_mcs_map; } /** diff --git a/core/mac/src/pe/lim/lim_types.h b/core/mac/src/pe/lim/lim_types.h index 72c86581550c..4cfa3d749e0a 100644 --- a/core/mac/src/pe/lim/lim_types.h +++ b/core/mac/src/pe/lim/lim_types.h @@ -266,6 +266,17 @@ typedef struct sLimMlmAssocInd { uint32_t assocReqLength; uint8_t *assocReqPtr; tSirSmeChanInfo chan_info; + bool ampdu; + bool sgi_enable; + bool tx_stbc; + bool rx_stbc; + tSirMacHTChannelWidth ch_width; + enum sir_sme_phy_mode mode; + uint8_t max_supp_idx; + uint8_t max_ext_idx; + uint8_t max_mcs_idx; + uint8_t rx_mcs_map; + uint8_t tx_mcs_map; } tLimMlmAssocInd, *tpLimMlmAssocInd; typedef struct sLimMlmReassocReq { diff --git a/core/mac/src/sys/legacy/src/utils/src/mac_trace.c b/core/mac/src/sys/legacy/src/utils/src/mac_trace.c index 5744ae9199b4..79cd5ef8841d 100644 --- a/core/mac/src/sys/legacy/src/utils/src/mac_trace.c +++ b/core/mac/src/sys/legacy/src/utils/src/mac_trace.c @@ -414,6 +414,8 @@ uint8_t *mac_trace_get_sme_msg_string(uint16_t sme_msg) CASE_RETURN_STRING(eWNI_SME_DEFAULT_SCAN_IE); CASE_RETURN_STRING(eWNI_SME_ROAM_SCAN_OFFLOAD_REQ); CASE_RETURN_STRING(eWNI_SME_LOST_LINK_INFO_IND); + CASE_RETURN_STRING(eWNI_SME_GET_PEER_INFO_IND); + CASE_RETURN_STRING(eWNI_SME_GET_PEER_INFO_EXT_IND); CASE_RETURN_STRING(eWNI_SME_RSO_CMD_STATUS_IND); CASE_RETURN_STRING(eWNI_SME_MSG_TYPES_END); default: diff --git a/core/sap/inc/sap_api.h b/core/sap/inc/sap_api.h index e6cd4932b965..1412220c239f 100644 --- a/core/sap/inc/sap_api.h +++ b/core/sap/inc/sap_api.h @@ -287,6 +287,17 @@ typedef struct sap_StationAssocReassocCompleteEvent_s { uint8_t *assocRespPtr; uint8_t timingMeasCap; tSirSmeChanInfo chan_info; + bool ampdu; + bool sgi_enable; + bool tx_stbc; + bool rx_stbc; + tSirMacHTChannelWidth ch_width; + enum sir_sme_phy_mode mode; + uint8_t max_supp_idx; + uint8_t max_ext_idx; + uint8_t max_mcs_idx; + uint8_t rx_mcs_map; + uint8_t tx_mcs_map; } tSap_StationAssocReassocCompleteEvent; typedef struct sap_StationDisassocCompleteEvent_s { diff --git a/core/sap/src/sap_fsm.c b/core/sap/src/sap_fsm.c index ae850044c3ad..5cfd69c8f60e 100644 --- a/core/sap/src/sap_fsm.c +++ b/core/sap/src/sap_fsm.c @@ -2451,6 +2451,17 @@ QDF_STATUS sap_signal_hdd_event(ptSapContext sap_ctx, reassoc_complete->wmmEnabled = csr_roaminfo->wmmEnabledSta; reassoc_complete->status = (eSapStatus) context; reassoc_complete->timingMeasCap = csr_roaminfo->timingMeasCap; + reassoc_complete->ampdu = csr_roaminfo->ampdu; + reassoc_complete->sgi_enable = csr_roaminfo->sgi_enable; + reassoc_complete->tx_stbc = csr_roaminfo->tx_stbc; + reassoc_complete->rx_stbc = csr_roaminfo->rx_stbc; + reassoc_complete->ch_width = csr_roaminfo->ch_width; + reassoc_complete->mode = csr_roaminfo->mode; + reassoc_complete->max_supp_idx = csr_roaminfo->max_supp_idx; + reassoc_complete->max_ext_idx = csr_roaminfo->max_ext_idx; + reassoc_complete->max_mcs_idx = csr_roaminfo->max_mcs_idx; + reassoc_complete->rx_mcs_map = csr_roaminfo->rx_mcs_map; + reassoc_complete->tx_mcs_map = csr_roaminfo->tx_mcs_map; break; case eSAP_STA_DISASSOC_EVENT: diff --git a/core/sme/inc/csr_api.h b/core/sme/inc/csr_api.h index 14eb6e80e8a3..cec91f0aa2a9 100644 --- a/core/sme/inc/csr_api.h +++ b/core/sme/inc/csr_api.h @@ -1450,6 +1450,17 @@ typedef struct tagCsrRoamInfo { tDot11fIEVHTOperation vht_operation; tDot11fIEHTInfo ht_operation; bool reassoc; + bool ampdu; + bool sgi_enable; + bool tx_stbc; + bool rx_stbc; + tSirMacHTChannelWidth ch_width; + enum sir_sme_phy_mode mode; + uint8_t max_supp_idx; + uint8_t max_ext_idx; + uint8_t max_mcs_idx; + uint8_t rx_mcs_map; + uint8_t tx_mcs_map; } tCsrRoamInfo; typedef struct tagCsrFreqScanInfo { @@ -1477,6 +1488,17 @@ typedef struct sSirSmeAssocIndToUpperLayerCnf { uint8_t timingMeasCap; tSirSmeChanInfo chan_info; uint8_t target_channel; + bool ampdu; + bool sgi_enable; + bool tx_stbc; + tSirMacHTChannelWidth ch_width; + enum sir_sme_phy_mode mode; + bool rx_stbc; + uint8_t max_supp_idx; + uint8_t max_ext_idx; + uint8_t max_mcs_idx; + uint8_t rx_mcs_map; + uint8_t tx_mcs_map; } tSirSmeAssocIndToUpperLayerCnf, *tpSirSmeAssocIndToUpperLayerCnf; typedef struct tagCsrSummaryStatsInfo { diff --git a/core/sme/inc/sme_api.h b/core/sme/inc/sme_api.h index 44b971586eba..fece2e13c2af 100644 --- a/core/sme/inc/sme_api.h +++ b/core/sme/inc/sme_api.h @@ -1627,4 +1627,37 @@ int sme_cli_set_command(int vdev_id, int param_id, int sval, int vpdev); QDF_STATUS sme_set_bt_activity_info_cb(tHalHandle hal, void (*cb)(void *, uint32_t profile_info)); +/** + * sme_get_peer_info() - sme api to get peer info + * @hal: hal handle for getting global mac struct + * @req: peer info request struct send to wma + * @context: context of callback function + * @callbackfn: hdd callback function when receive response + * + * This function will send WMA_GET_PEER_INFO to WMA + * + * Return: QDF_STATUS_SUCCESS or non-zero on failure + */ +QDF_STATUS sme_get_peer_info(tHalHandle hal, + struct sir_peer_info_req req, + void *context, + void (*callbackfn)(struct sir_peer_info_resp *param, + void *pcontext)); + +/** + * sme_get_peer_info_ext() - sme api to get peer ext info + * @hal: hal handle for getting global mac struct + * @req: peer ext info request struct send to wma + * @context: context of callback function + * @callbackfn: hdd callback function when receive response + * + * This function will send WMA_GET_PEER_INFO_EXT to WMA + * + * Return: QDF_STATUS_SUCCESS or non-zero on failure + */ +QDF_STATUS sme_get_peer_info_ext(tHalHandle hal, + struct sir_peer_info_ext_req *req, + void *context, + void (*callbackfn)(struct sir_peer_info_ext_resp *param, + void *pcontext)); #endif /* #if !defined( __SME_API_H ) */ diff --git a/core/sme/inc/sme_internal.h b/core/sme/inc/sme_internal.h index 86d8af3f8bf9..585ccedf58ce 100644 --- a/core/sme/inc/sme_internal.h +++ b/core/sme/inc/sme_internal.h @@ -197,6 +197,14 @@ typedef struct tagSmeStruct { void (*pLinkSpeedIndCb)(tSirLinkSpeedInfo *indParam, void *pDevContext); void *pLinkSpeedCbContext; + /* get peer info callback */ + void (*pget_peer_info_ind_cb)(struct sir_peer_info_resp *param, + void *pcontext); + void *pget_peer_info_cb_context; + /* get extended peer info callback */ + void (*pget_peer_info_ext_ind_cb)(struct sir_peer_info_ext_resp *param, + void *pcontext); + void *pget_peer_info_ext_cb_context; #ifdef FEATURE_WLAN_EXTSCAN void (*pExtScanIndCb)(void *, const uint16_t, void *); #endif /* FEATURE_WLAN_EXTSCAN */ diff --git a/core/sme/src/common/sme_api.c b/core/sme/src/common/sme_api.c index 12bd31a6be14..617e8a695350 100644 --- a/core/sme/src/common/sme_api.c +++ b/core/sme/src/common/sme_api.c @@ -2413,6 +2413,18 @@ QDF_STATUS sme_process_msg(tHalHandle hHal, struct scheduler_msg *pMsg) } break; #endif + case eWNI_SME_GET_PEER_INFO_IND: + if (pMac->sme.pget_peer_info_ind_cb) + pMac->sme.pget_peer_info_ind_cb(pMsg->bodyptr, + pMac->sme.pget_peer_info_cb_context); + qdf_mem_free(pMsg->bodyptr); + break; + case eWNI_SME_GET_PEER_INFO_EXT_IND: + if (pMac->sme.pget_peer_info_ext_ind_cb) + pMac->sme.pget_peer_info_ext_ind_cb(pMsg->bodyptr, + pMac->sme.pget_peer_info_ext_cb_context); + qdf_mem_free(pMsg->bodyptr); + break; case eWNI_SME_CSA_OFFLOAD_EVENT: if (pMsg->bodyptr) { csr_scan_flush_bss_entry(pMac, pMsg->bodyptr); @@ -9686,6 +9698,100 @@ QDF_STATUS sme_get_link_speed(tHalHandle hHal, tSirLinkSpeedInfo *lsReq, return status; } +QDF_STATUS sme_get_peer_info(tHalHandle hal, struct sir_peer_info_req req, + void *context, + void (*callbackfn)(struct sir_peer_info_resp *param, + void *pcontext)) +{ + + QDF_STATUS status; + QDF_STATUS qdf_status; + tpAniSirGlobal mac = PMAC_STRUCT(hal); + struct scheduler_msg message; + + status = sme_acquire_global_lock(&mac->sme); + if (QDF_STATUS_SUCCESS == status) { + if (NULL == callbackfn) { + QDF_TRACE(QDF_MODULE_ID_SME, QDF_TRACE_LEVEL_ERROR, + "%s: Indication Call back is NULL", + __func__); + sme_release_global_lock(&mac->sme); + return QDF_STATUS_E_FAILURE; + } + + mac->sme.pget_peer_info_ind_cb = callbackfn; + mac->sme.pget_peer_info_cb_context = context; + + /* serialize the req through MC thread */ + message.bodyptr = qdf_mem_malloc(sizeof(req)); + if (NULL == message.bodyptr) { + QDF_TRACE(QDF_MODULE_ID_SME, QDF_TRACE_LEVEL_ERROR, + "%s: Memory allocation failed.", __func__); + sme_release_global_lock(&mac->sme); + return QDF_STATUS_E_NOMEM; + } + qdf_mem_copy(message.bodyptr, &req, sizeof(req)); + message.type = WMA_GET_PEER_INFO; + qdf_status = scheduler_post_msg(QDF_MODULE_ID_WMA, &message); + if (!QDF_IS_STATUS_SUCCESS(qdf_status)) { + QDF_TRACE(QDF_MODULE_ID_SME, QDF_TRACE_LEVEL_ERROR, + "%s: Post get peer info msg fail", __func__); + qdf_mem_free(message.bodyptr); + status = QDF_STATUS_E_FAILURE; + } + sme_release_global_lock(&mac->sme); + } + return status; +} + +QDF_STATUS sme_get_peer_info_ext(tHalHandle hal, + struct sir_peer_info_ext_req *req, + void *context, + void (*callbackfn)(struct sir_peer_info_ext_resp *param, + void *pcontext)) +{ + QDF_STATUS status; + QDF_STATUS qdf_status; + tpAniSirGlobal mac = PMAC_STRUCT(hal); + struct scheduler_msg message; + + status = sme_acquire_global_lock(&mac->sme); + if (QDF_STATUS_SUCCESS == status) { + if (NULL == callbackfn) { + QDF_TRACE(QDF_MODULE_ID_SME, QDF_TRACE_LEVEL_ERROR, + "%s: Indication Call back is NULL", + __func__); + sme_release_global_lock(&mac->sme); + return QDF_STATUS_E_FAILURE; + } + + mac->sme.pget_peer_info_ext_ind_cb = callbackfn; + mac->sme.pget_peer_info_ext_cb_context = context; + + /* serialize the req through MC thread */ + message.bodyptr = + qdf_mem_malloc(sizeof(struct sir_peer_info_ext_req)); + if (NULL == message.bodyptr) { + QDF_TRACE(QDF_MODULE_ID_SME, QDF_TRACE_LEVEL_ERROR, + "%s: Memory allocation failed.", __func__); + sme_release_global_lock(&mac->sme); + return QDF_STATUS_E_NOMEM; + } + qdf_mem_copy(message.bodyptr, + req, + sizeof(struct sir_peer_info_ext_req)); + message.type = WMA_GET_PEER_INFO_EXT; + qdf_status = scheduler_post_msg(QDF_MODULE_ID_WMA, &message); + if (!QDF_IS_STATUS_SUCCESS(qdf_status)) { + QDF_TRACE(QDF_MODULE_ID_SME, QDF_TRACE_LEVEL_ERROR, + "%s: Post get rssi msg fail", __func__); + qdf_mem_free(message.bodyptr); + status = QDF_STATUS_E_FAILURE; + } + sme_release_global_lock(&mac->sme); + } + return status; +} /* * SME API to enable/disable WLAN driver initiated SSR diff --git a/core/sme/src/csr/csr_api_roam.c b/core/sme/src/csr/csr_api_roam.c index 34e6256b8413..8820dc6342fb 100644 --- a/core/sme/src/csr/csr_api_roam.c +++ b/core/sme/src/csr/csr_api_roam.c @@ -9852,6 +9852,17 @@ void csr_roam_joined_state_msg_processor(tpAniSirGlobal pMac, void *pMsgBuf) qdf_mem_copy(&pRoamInfo->chan_info, &pUpperLayerAssocCnf->chan_info, sizeof(tSirSmeChanInfo)); + pRoamInfo->ampdu = pUpperLayerAssocCnf->ampdu; + pRoamInfo->sgi_enable = pUpperLayerAssocCnf->sgi_enable; + pRoamInfo->tx_stbc = pUpperLayerAssocCnf->tx_stbc; + pRoamInfo->tx_stbc = pUpperLayerAssocCnf->rx_stbc; + pRoamInfo->ch_width = pUpperLayerAssocCnf->ch_width; + pRoamInfo->mode = pUpperLayerAssocCnf->mode; + pRoamInfo->max_supp_idx = pUpperLayerAssocCnf->max_supp_idx; + pRoamInfo->max_ext_idx = pUpperLayerAssocCnf->max_ext_idx; + pRoamInfo->max_mcs_idx = pUpperLayerAssocCnf->max_mcs_idx; + pRoamInfo->rx_mcs_map = pUpperLayerAssocCnf->rx_mcs_map; + pRoamInfo->tx_mcs_map = pUpperLayerAssocCnf->tx_mcs_map; if (CSR_IS_INFRA_AP(pRoamInfo->u.pConnectedProfile)) { pMac->roam.roamSession[sessionId].connectState = eCSR_ASSOC_STATE_TYPE_INFRA_CONNECTED; @@ -15171,54 +15182,90 @@ QDF_STATUS csr_send_assoc_ind_to_upper_layer_cnf_msg(tpAniSirGlobal pMac, else statusCode = eSIR_SME_ASSOC_REFUSED; qdf_mem_copy(pBuf, &statusCode, sizeof(tSirResultCodes)); - pBuf += sizeof(tSirResultCodes); /* bssId */ - qdf_mem_copy((tSirMacAddr *) pBuf, pAssocInd->bssId, - sizeof(tSirMacAddr)); - pBuf += sizeof(tSirMacAddr); + pBuf = (uint8_t *)&pMsg->bssId; + qdf_mem_copy((tSirMacAddr *)pBuf, pAssocInd->bssId, + sizeof(tSirMacAddr)); /* peerMacAddr */ - qdf_mem_copy((tSirMacAddr *) pBuf, pAssocInd->peerMacAddr, - sizeof(tSirMacAddr)); - pBuf += sizeof(tSirMacAddr); + pBuf = (uint8_t *)&pMsg->peerMacAddr; + qdf_mem_copy((tSirMacAddr *)pBuf, pAssocInd->peerMacAddr, + sizeof(tSirMacAddr)); /* StaId */ + pBuf = (uint8_t *)&pMsg->aid; wTmp = pAssocInd->staId; qdf_mem_copy(pBuf, &wTmp, sizeof(uint16_t)); - pBuf += sizeof(uint16_t); /* alternateBssId */ - qdf_mem_copy((tSirMacAddr *) pBuf, pAssocInd->bssId, - sizeof(tSirMacAddr)); - pBuf += sizeof(tSirMacAddr); + pBuf = (uint8_t *)&pMsg->alternateBssId; + qdf_mem_copy((tSirMacAddr *)pBuf, pAssocInd->bssId, + sizeof(tSirMacAddr)); /* alternateChannelId */ + pBuf = (uint8_t *)&pMsg->alternateChannelId; *pBuf = 11; - pBuf += sizeof(uint8_t); - /* Instead of copying roam Info, we just copy only WmmEnabled, - * RsnIE information + /* + * Instead of copying roam Info,just copy WmmEnabled, + * RsnIE information. + * Wmm */ - /* Wmm */ + pBuf = (uint8_t *)&pMsg->wmmEnabledSta; *pBuf = pAssocInd->wmmEnabledSta; - pBuf += sizeof(uint8_t); /* RSN IE */ - qdf_mem_copy((tSirRSNie *) pBuf, &pAssocInd->rsnIE, - sizeof(tSirRSNie)); - pBuf += sizeof(tSirRSNie); + pBuf = (uint8_t *)&pMsg->rsnIE; + qdf_mem_copy((tSirRSNie *)pBuf, &pAssocInd->rsnIE, + sizeof(tSirRSNie)); #ifdef FEATURE_WLAN_WAPI /* WAPI IE */ - qdf_mem_copy((tSirWAPIie *) pBuf, &pAssocInd->wapiIE, - sizeof(tSirWAPIie)); - pBuf += sizeof(tSirWAPIie); + pBuf = (uint8_t *)&pMsg->wapiIE; + qdf_mem_copy((tSirWAPIie *)pBuf, &pAssocInd->wapiIE, + sizeof(tSirWAPIie)); #endif /* Additional IE */ - qdf_mem_copy((void *)pBuf, &pAssocInd->addIE, - sizeof(tSirAddie)); - pBuf += sizeof(tSirAddie); + pBuf = (uint8_t *)&pMsg->addIE; + qdf_mem_copy((tSirAddie *)pBuf, &pAssocInd->addIE, + sizeof(tSirAddie)); /* reassocReq */ + pBuf = (uint8_t *)&pMsg->reassocReq; *pBuf = pAssocInd->reassocReq; - pBuf += sizeof(uint8_t); /* timingMeasCap */ + pBuf = (uint8_t *)&pMsg->timingMeasCap; *pBuf = pAssocInd->timingMeasCap; - pBuf += sizeof(uint8_t); + /* chan_info */ + pBuf = (uint8_t *)&pMsg->chan_info; qdf_mem_copy((void *)pBuf, &pAssocInd->chan_info, - sizeof(tSirSmeChanInfo)); + sizeof(tSirSmeChanInfo)); + /* ampdu */ + pBuf = (uint8_t *)&pMsg->ampdu; + *((bool *)pBuf) = pAssocInd->ampdu; + /* sgi_enable */ + pBuf = (uint8_t *)&pMsg->sgi_enable; + *((bool *)pBuf) = pAssocInd->sgi_enable; + /* tx stbc */ + pBuf = (uint8_t *)&pMsg->tx_stbc; + *((bool *)pBuf) = pAssocInd->tx_stbc; + /* ch_width */ + pBuf = (uint8_t *)&pMsg->ch_width; + *((tSirMacHTChannelWidth *)pBuf) = pAssocInd->ch_width; + /* mode */ + pBuf = (uint8_t *)&pMsg->mode; + *((enum sir_sme_phy_mode *)pBuf) = pAssocInd->mode; + /* rx stbc */ + pBuf = (uint8_t *)&pMsg->rx_stbc; + *((bool *)pBuf) = pAssocInd->rx_stbc; + /* max supported idx */ + pBuf = (uint8_t *)&pMsg->max_supp_idx; + *pBuf = pAssocInd->max_supp_idx; + /* max extended idx */ + pBuf = (uint8_t *)&pMsg->max_ext_idx; + *pBuf = pAssocInd->max_ext_idx; + /* max ht mcs idx */ + pBuf = (uint8_t *)&pMsg->max_mcs_idx; + *pBuf = pAssocInd->max_mcs_idx; + /* vht rx mcs map */ + pBuf = (uint8_t *)&pMsg->rx_mcs_map; + *pBuf = pAssocInd->rx_mcs_map; + /* vht tx mcs map */ + pBuf = (uint8_t *)&pMsg->tx_mcs_map; + *pBuf = pAssocInd->tx_mcs_map; + msgQ.type = eWNI_SME_UPPER_LAYER_ASSOC_CNF; msgQ.bodyptr = pMsg; msgQ.bodyval = 0; From 697888b35af1fba31fbc6e4df4f8f3b0f2203e7a Mon Sep 17 00:00:00 2001 From: snandini Date: Tue, 18 Jul 2017 05:54:26 -0700 Subject: [PATCH 29/34] Release 5.2.0.35G Release 5.2.0.35G Change-Id: If59b328a5c5510b1dc6847db2a6e8aed174d2e59 CRs-Fixed: 774533 --- core/mac/inc/qwlan_version.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/core/mac/inc/qwlan_version.h b/core/mac/inc/qwlan_version.h index 308d5ed6473a..069846842de1 100644 --- a/core/mac/inc/qwlan_version.h +++ b/core/mac/inc/qwlan_version.h @@ -41,9 +41,9 @@ #define QWLAN_VERSION_MAJOR 5 #define QWLAN_VERSION_MINOR 2 #define QWLAN_VERSION_PATCH 0 -#define QWLAN_VERSION_EXTRA "F" +#define QWLAN_VERSION_EXTRA "G" #define QWLAN_VERSION_BUILD 35 -#define QWLAN_VERSIONSTR "5.2.0.35F" +#define QWLAN_VERSIONSTR "5.2.0.35G" #endif /* QWLAN_VERSION_H */ From 08719b0c38cc8852f04968fa81c3911dab9179cf Mon Sep 17 00:00:00 2001 From: Jiachao Wu Date: Wed, 5 Jul 2017 13:05:34 +0800 Subject: [PATCH 30/34] qcacld-3.0: iwpriv set_txchainmask 0 shouldn't change mode If user set invalid txchainmask, driver shouldn't change the value. Change-Id: Ifd600e439e967845bfa874220a3e1508bc26a3ba CRs-Fixed: 2070620 --- core/wma/inc/wma_internal.h | 9 ++++++++- core/wma/src/wma_data.c | 26 ++++++++++---------------- core/wma/src/wma_main.c | 9 +++++++-- 3 files changed, 25 insertions(+), 19 deletions(-) diff --git a/core/wma/inc/wma_internal.h b/core/wma/inc/wma_internal.h index 24e3cddd2840..f31ff216dfbd 100644 --- a/core/wma/inc/wma_internal.h +++ b/core/wma/inc/wma_internal.h @@ -721,7 +721,14 @@ void wma_set_bss_rate_flags(struct wma_txrx_node *iface, int32_t wmi_unified_send_txbf(tp_wma_handle wma, tpAddStaParams params); -void wma_update_txrx_chainmask(int num_rf_chains, int *cmd_value); +/** + * wma_check_txrx_chainmask() - check txrx chainmask + * @num_rf_chains: number of rf chains + * @cmd_value: command value + * + * Return: QDF_STATUS_SUCCESS for success or error code + */ +QDF_STATUS wma_check_txrx_chainmask(int num_rf_chains, int cmd_value); int wma_peer_state_change_event_handler(void *handle, uint8_t *event_buff, diff --git a/core/wma/src/wma_data.c b/core/wma/src/wma_data.c index 6a0d56752027..d6bb5733a662 100644 --- a/core/wma/src/wma_data.c +++ b/core/wma/src/wma_data.c @@ -913,27 +913,21 @@ free_nbuf: } /** - * wma_update_txrx_chainmask() - update txrx chainmask - * @num_rf_chains: number rf chains + * wma_check_txrx_chainmask() - check txrx chainmask + * @num_rf_chains: number of rf chains * @cmd_value: command value * - * Return: none + * Return: QDF_STATUS_SUCCESS for success or error code */ -void wma_update_txrx_chainmask(int num_rf_chains, int *cmd_value) +QDF_STATUS wma_check_txrx_chainmask(int num_rf_chains, int cmd_value) { - if (*cmd_value > WMA_MAX_RF_CHAINS(num_rf_chains)) { - WMA_LOGE("%s: Chainmask value exceeds the maximum supported range setting it to maximum value.", - __func__); - WMA_LOGE("%s: Requested value %d Updated value %d", - __func__, *cmd_value, WMA_MAX_RF_CHAINS(num_rf_chains)); - *cmd_value = WMA_MAX_RF_CHAINS(num_rf_chains); - } else if (*cmd_value < WMA_MIN_RF_CHAINS) { - WMA_LOGE("%s: Chainmask value is less than the minimum supported range setting it to minimum value.", - __func__); - WMA_LOGE("%s: Requested value %d Updated value %d", - __func__, *cmd_value, WMA_MIN_RF_CHAINS); - *cmd_value = WMA_MIN_RF_CHAINS; + if ((cmd_value > WMA_MAX_RF_CHAINS(num_rf_chains)) || + (cmd_value < WMA_MIN_RF_CHAINS)) { + WMA_LOGE("%s: Requested value %d over the range", + __func__, cmd_value); + return QDF_STATUS_E_INVAL; } + return QDF_STATUS_SUCCESS; } /** diff --git a/core/wma/src/wma_main.c b/core/wma/src/wma_main.c index 8d14620ed810..6a8e431981b8 100644 --- a/core/wma/src/wma_main.c +++ b/core/wma/src/wma_main.c @@ -947,8 +947,13 @@ static void wma_process_cli_set_cmd(tp_wma_handle wma, privcmd->param_value); if ((privcmd->param_id == WMI_PDEV_PARAM_RX_CHAIN_MASK) || (privcmd->param_id == WMI_PDEV_PARAM_TX_CHAIN_MASK)) { - wma_update_txrx_chainmask(wma->num_rf_chains, - &privcmd->param_value); + if (QDF_STATUS_SUCCESS != + wma_check_txrx_chainmask( + wma->num_rf_chains, + privcmd->param_value)) { + WMA_LOGD("Chainmask value is invalid"); + return; + } } pdev_param.param_id = privcmd->param_id; pdev_param.param_value = privcmd->param_value; From 8c76505521107d0a47f6b8c8e29f2cb158b265d2 Mon Sep 17 00:00:00 2001 From: snandini Date: Tue, 18 Jul 2017 07:43:32 -0700 Subject: [PATCH 31/34] Release 5.2.0.35H Release 5.2.0.35H Change-Id: I5177a1bc0b6acd0787e913d8307f9b0fdb5283f9 CRs-Fixed: 774533 --- core/mac/inc/qwlan_version.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/core/mac/inc/qwlan_version.h b/core/mac/inc/qwlan_version.h index 069846842de1..e755283f7637 100644 --- a/core/mac/inc/qwlan_version.h +++ b/core/mac/inc/qwlan_version.h @@ -41,9 +41,9 @@ #define QWLAN_VERSION_MAJOR 5 #define QWLAN_VERSION_MINOR 2 #define QWLAN_VERSION_PATCH 0 -#define QWLAN_VERSION_EXTRA "G" +#define QWLAN_VERSION_EXTRA "H" #define QWLAN_VERSION_BUILD 35 -#define QWLAN_VERSIONSTR "5.2.0.35G" +#define QWLAN_VERSIONSTR "5.2.0.35H" #endif /* QWLAN_VERSION_H */ From 825b0f7ac6a4d41d5a9e4b3b62b2d3d0a6d50f29 Mon Sep 17 00:00:00 2001 From: Tushnim Bhattacharyya Date: Fri, 14 Jul 2017 15:21:04 -0700 Subject: [PATCH 32/34] qcacld-3.0: preferred_rx_streams to reflect correct NSS value preferred_rx_streams to reflect the NSS value with which association to the AP happened in STA mode. Change-Id: Ia2ecfb7ba055c3644410b0ff908812f0f94ba4c7 CRs-Fixed: 2077040 --- core/wma/src/wma_scan_roam.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/wma/src/wma_scan_roam.c b/core/wma/src/wma_scan_roam.c index 65276c1cf9ec..8f54da24d067 100644 --- a/core/wma/src/wma_scan_roam.c +++ b/core/wma/src/wma_scan_roam.c @@ -3003,7 +3003,7 @@ void wma_set_channel(tp_wma_handle wma, tpSwitchChannelParams params) if (!QDF_IS_STATUS_SUCCESS(status)) WMA_LOGE("policy_mgr_get_current_hw_mode failed"); - if ((params->nss == 2) && !hw_mode.dbs_cap) { + if (params->nss == 2) { req.preferred_rx_streams = 2; req.preferred_tx_streams = 2; } else { From fe7aa8780ad7c44d4f7a80de774426e933b61836 Mon Sep 17 00:00:00 2001 From: Dustin Brown Date: Mon, 26 Jun 2017 10:52:08 -0700 Subject: [PATCH 33/34] qcacld-3.0: Add gPreventLinkDown ini item Add a configuration item, gPreventLinkDown, to disable putting the bus link to sleep during suspend/resume. Change-Id: Id52c6319cafaef60e6f4e562010615361eb831cd CRs-Fixed: 2066718 --- core/hdd/inc/wlan_hdd_cfg.h | 24 ++++++++++++++++++++++++ core/hdd/src/wlan_hdd_cfg.c | 7 +++++++ core/hdd/src/wlan_hdd_driver_ops.c | 3 +++ 3 files changed, 34 insertions(+) diff --git a/core/hdd/inc/wlan_hdd_cfg.h b/core/hdd/inc/wlan_hdd_cfg.h index 07f28b07388b..7c512b989a42 100644 --- a/core/hdd/inc/wlan_hdd_cfg.h +++ b/core/hdd/inc/wlan_hdd_cfg.h @@ -5798,6 +5798,29 @@ enum hdd_link_speed_rpt_type { #define CFG_RATE_FOR_TX_MGMT_5G_MAX (WNI_CFG_RATE_FOR_TX_MGMT_5G_STAMAX) #define CFG_RATE_FOR_TX_MGMT_5G_DEFAULT (WNI_CFG_RATE_FOR_TX_MGMT_5G_STADEF) +/* + * + * gPreventLinkDown - Enable to prevent bus link from going down + * @Min: 0 + * @Max: 1 + * @Default: 0 + * + * Enable to prevent bus link from going down. Useful for platforms that do not + * (yet) support link down suspend cases. + * + * Related: N/A + * + * Supported Feature: Suspend/Resume + * + * Usage: Internal + * + * + */ +#define CFG_PREVENT_LINK_DOWN_NAME "gPreventLinkDown" +#define CFG_PREVENT_LINK_DOWN_MIN (0) +#define CFG_PREVENT_LINK_DOWN_MAX (1) +#define CFG_PREVENT_LINK_DOWN_DEFAULT (0) + #ifdef FEATURE_WLAN_TDLS /* * @@ -10848,6 +10871,7 @@ struct hdd_config { uint8_t enable_tx_ldpc; uint8_t enable_rx_ldpc; bool enable5gEBT; + bool prevent_link_down; #ifdef FEATURE_WLAN_TDLS bool fEnableTDLSSupport; bool fEnableTDLSImplicitTrigger; diff --git a/core/hdd/src/wlan_hdd_cfg.c b/core/hdd/src/wlan_hdd_cfg.c index 6e69b7206480..0a29fc058c43 100644 --- a/core/hdd/src/wlan_hdd_cfg.c +++ b/core/hdd/src/wlan_hdd_cfg.c @@ -2197,6 +2197,13 @@ struct reg_table_entry g_registry_table[] = { CFG_PPS_ENABLE_5G_EBT_FEATURE_MIN, CFG_PPS_ENABLE_5G_EBT_FEATURE_MAX), + REG_VARIABLE(CFG_PREVENT_LINK_DOWN_NAME, WLAN_PARAM_Integer, + struct hdd_config, prevent_link_down, + VAR_FLAGS_OPTIONAL | VAR_FLAGS_RANGE_CHECK_ASSUME_DEFAULT, + CFG_PREVENT_LINK_DOWN_DEFAULT, + CFG_PREVENT_LINK_DOWN_MIN, + CFG_PREVENT_LINK_DOWN_MAX), + #ifdef FEATURE_WLAN_TDLS REG_VARIABLE(CFG_TDLS_SUPPORT_ENABLE, WLAN_PARAM_Integer, struct hdd_config, fEnableTDLSSupport, diff --git a/core/hdd/src/wlan_hdd_driver_ops.c b/core/hdd/src/wlan_hdd_driver_ops.c index 0dc6b35b9d3d..8b657b77ac51 100644 --- a/core/hdd/src/wlan_hdd_driver_ops.c +++ b/core/hdd/src/wlan_hdd_driver_ops.c @@ -230,6 +230,9 @@ int hdd_hif_open(struct device *dev, void *bdev, const struct hif_bus_id *bid, goto err_hif_close; } + if (hdd_ctx->config->prevent_link_down) + hif_vote_link_up(hif_ctx); + status = hif_enable(hif_ctx, dev, bdev, bid, bus_type, (reinit == true) ? HIF_ENABLE_TYPE_REINIT : HIF_ENABLE_TYPE_PROBE); From b8849998120ba34e27c79a769e7863a1b19b643d Mon Sep 17 00:00:00 2001 From: snandini Date: Tue, 18 Jul 2017 15:49:39 -0700 Subject: [PATCH 34/34] Release 5.2.0.35I Release 5.2.0.35I Change-Id: Icb85ac525b37c63a82310a292bf7fd936ccae95b CRs-Fixed: 774533 --- core/mac/inc/qwlan_version.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/core/mac/inc/qwlan_version.h b/core/mac/inc/qwlan_version.h index e755283f7637..93f29c1bfae2 100644 --- a/core/mac/inc/qwlan_version.h +++ b/core/mac/inc/qwlan_version.h @@ -41,9 +41,9 @@ #define QWLAN_VERSION_MAJOR 5 #define QWLAN_VERSION_MINOR 2 #define QWLAN_VERSION_PATCH 0 -#define QWLAN_VERSION_EXTRA "H" +#define QWLAN_VERSION_EXTRA "I" #define QWLAN_VERSION_BUILD 35 -#define QWLAN_VERSIONSTR "5.2.0.35H" +#define QWLAN_VERSIONSTR "5.2.0.35I" #endif /* QWLAN_VERSION_H */