qcacld-3.0: Remove usage of sta_id in TSM stats path
Currently driver passes sta_id through out the call for getting the TSM
stats. Although passed, the sta_id is not used anywhere in the call
stack. As part of removing the sta_id usage, this sta_id can also be
removed safely.
Remove the usage of sta_id in get TSM stats path.
Change-Id: I1efbb1bfdc8df84e9b6a71dcd5bd39ea93ced21a
CRs-Fixed: 2484701
diff --git a/core/hdd/src/wlan_hdd_ioctl.c b/core/hdd/src/wlan_hdd_ioctl.c
index 67d770d..4338315 100644
--- a/core/hdd/src/wlan_hdd_ioctl.c
+++ b/core/hdd/src/wlan_hdd_ioctl.c
@@ -175,7 +175,7 @@
};
static void hdd_get_tsm_stats_cb(tAniTrafStrmMetrics tsm_metrics,
- const uint32_t sta_id, void *context)
+ void *context)
{
struct osif_request *request;
struct tsm_priv *priv;
@@ -225,7 +225,6 @@
cookie = osif_request_cookie(request);
status = sme_get_tsm_stats(hdd_ctx->mac_handle, hdd_get_tsm_stats_cb,
- hdd_sta_ctx->conn_info.sta_id[0],
hdd_sta_ctx->conn_info.bssid,
cookie, tid);
if (QDF_STATUS_SUCCESS != status) {
diff --git a/core/mac/inc/sir_api.h b/core/mac/inc/sir_api.h
index b505dbe..129d1bd 100644
--- a/core/mac/inc/sir_api.h
+++ b/core/mac/inc/sir_api.h
@@ -797,7 +797,6 @@
/* Common for all types are requests */
uint16_t msgType; /* message type is same as the request type */
uint16_t msgLen; /* length of the entire request */
- uint8_t staId;
uint8_t tid; /* traffic id */
struct qdf_mac_addr bssId;
void *tsmStatsCallback;
@@ -816,10 +815,6 @@
*/
uint8_t sessionId;
uint32_t rc; /* success/failure */
- uint32_t staId; /*
- * Per STA stats request must
- * contain valid
- */
struct qdf_mac_addr bssid; /* bssid to get the tsm stats for */
tAniTrafStrmMetrics tsmMetrics;
void *tsmStatsReq; /* tsm stats request backup */
diff --git a/core/mac/src/pe/lim/lim_send_sme_rsp_messages.c b/core/mac/src/pe/lim/lim_send_sme_rsp_messages.c
index 6663cc5..0f51915 100644
--- a/core/mac/src/pe/lim/lim_send_sme_rsp_messages.c
+++ b/core/mac/src/pe/lim/lim_send_sme_rsp_messages.c
@@ -1373,8 +1373,8 @@
/* Fill the Session Id */
pPeStats->sessionId = pPeSessionEntry->smeSessionId;
} else {
- pe_err("Session not found for the Sta id: %d",
- pPeStats->staId);
+ pe_err("Session not found for the Sta peer:" QDF_MAC_ADDR_STR,
+ QDF_MAC_ADDR_ARRAY(pPeStats->bssid.bytes));
qdf_mem_free(pPeStats->tsmStatsReq);
qdf_mem_free(pPeStats);
return;
diff --git a/core/sme/inc/csr_api.h b/core/sme/inc/csr_api.h
index 9911ddc..41633a8 100644
--- a/core/sme/inc/csr_api.h
+++ b/core/sme/inc/csr_api.h
@@ -1423,7 +1423,7 @@
#ifdef FEATURE_WLAN_ESE
typedef void (*tCsrTsmStatsCallback)(tAniTrafStrmMetrics tsmMetrics,
- uint32_t staId, void *pContext);
+ void *pContext);
#endif /* FEATURE_WLAN_ESE */
typedef void (*tCsrSnrCallback)(int8_t snr, void *pContext);
diff --git a/core/sme/inc/csr_internal.h b/core/sme/inc/csr_internal.h
index ab393b5..f6aa03d 100644
--- a/core/sme/inc/csr_internal.h
+++ b/core/sme/inc/csr_internal.h
@@ -971,7 +971,6 @@
bool csr_roam_is_ese_ini_feature_enabled(struct mac_context *mac);
QDF_STATUS csr_get_tsm_stats(struct mac_context *mac,
tCsrTsmStatsCallback callback,
- uint8_t staId,
struct qdf_mac_addr bssId,
void *pContext, uint8_t tid);
#endif
diff --git a/core/sme/inc/sme_api.h b/core/sme/inc/sme_api.h
index a7edaf2..ff327c2 100644
--- a/core/sme/inc/sme_api.h
+++ b/core/sme/inc/sme_api.h
@@ -591,7 +591,7 @@
#ifdef FEATURE_WLAN_ESE
QDF_STATUS sme_get_tsm_stats(mac_handle_t mac_handle,
tCsrTsmStatsCallback callback,
- uint8_t staId, struct qdf_mac_addr bssId,
+ struct qdf_mac_addr bssId,
void *pContext, uint8_t tid);
QDF_STATUS sme_set_cckm_ie(mac_handle_t mac_handle,
uint8_t sessionId,
diff --git a/core/sme/src/common/sme_api.c b/core/sme/src/common/sme_api.c
index 7be8304..affe4ed 100644
--- a/core/sme/src/common/sme_api.c
+++ b/core/sme/src/common/sme_api.c
@@ -1701,7 +1701,7 @@
*/
QDF_STATUS sme_get_tsm_stats(mac_handle_t mac_handle,
tCsrTsmStatsCallback callback,
- uint8_t staId, struct qdf_mac_addr bssId,
+ struct qdf_mac_addr bssId,
void *pContext, uint8_t tid)
{
QDF_STATUS status = QDF_STATUS_E_FAILURE;
@@ -1710,7 +1710,7 @@
status = sme_acquire_global_lock(&mac->sme);
if (QDF_IS_STATUS_SUCCESS(status)) {
status = csr_get_tsm_stats(mac, callback,
- staId, bssId, pContext,
+ bssId, pContext,
tid);
sme_release_global_lock(&mac->sme);
}
diff --git a/core/sme/src/csr/csr_api_roam.c b/core/sme/src/csr/csr_api_roam.c
index 4d94c92..f531d6c 100644
--- a/core/sme/src/csr/csr_api_roam.c
+++ b/core/sme/src/csr/csr_api_roam.c
@@ -1811,8 +1811,6 @@
((tCsrTsmStatsCallback)
(reqBkp->tsmStatsCallback))(pTsmStatsRsp->
tsmMetrics,
- pTsmStatsRsp->
- staId,
reqBkp->
pDevContext);
reqBkp->tsmStatsCallback = NULL;
@@ -1889,7 +1887,6 @@
*/
QDF_STATUS csr_get_tsm_stats(struct mac_context *mac,
tCsrTsmStatsCallback callback,
- uint8_t staId,
struct qdf_mac_addr bssId,
void *pContext, uint8_t tid)
{
@@ -1903,7 +1900,6 @@
/* need to initiate a stats request to PE */
pMsg->msgType = eWNI_SME_GET_TSM_STATS_REQ;
pMsg->msgLen = (uint16_t) sizeof(tAniGetTsmStatsReq);
- pMsg->staId = staId;
pMsg->tid = tid;
qdf_copy_macaddr(&pMsg->bssId, &bssId);
pMsg->tsmStatsCallback = callback;
diff --git a/core/wma/src/wma_features.c b/core/wma/src/wma_features.c
index 4e8e3ac..0f9e0ed 100644
--- a/core/wma/src/wma_features.c
+++ b/core/wma/src/wma_features.c
@@ -2889,7 +2889,6 @@
qdf_mem_free(pTsmStatsMsg);
return QDF_STATUS_E_NOMEM;
}
- pTsmRspParams->staId = pStats->staId;
qdf_copy_macaddr(&pTsmRspParams->bssid, &pStats->bssId);
pTsmRspParams->rc = QDF_STATUS_E_FAILURE;
pTsmRspParams->tsmStatsReq = pStats;