qcacld-3.0: Replace hHal in sme_ft_api
Recently all instances of tHalHandle were replaced with mac_handle_t
to align with current usage and the Linux coding standard. To align
with the new naming now replace all instances of hHal with mac_handle
in sme_ft_api.
Change-Id: I5e41d0767b97bf698dbb14834f2080bd82577035
CRs-Fixed: 2349570
diff --git a/core/sme/inc/sme_ft_api.h b/core/sme/inc/sme_ft_api.h
index 84bcef9..c6f63e6 100644
--- a/core/sme/inc/sme_ft_api.h
+++ b/core/sme/inc/sme_ft_api.h
@@ -73,22 +73,24 @@
/*--------------------------------------------------------------------------
Prototype functions
------------------------------------------------------------------------*/
-void sme_ft_open(mac_handle_t hHal, uint32_t sessionId);
-void sme_ft_close(mac_handle_t hHal, uint32_t sessionId);
-void sme_ft_reset(mac_handle_t hHal, uint32_t sessionId);
-void sme_set_ft_ies(mac_handle_t hHal, uint32_t sessionId,
+void sme_ft_open(mac_handle_t mac_handle, uint32_t sessionId);
+void sme_ft_close(mac_handle_t mac_handle, uint32_t sessionId);
+void sme_ft_reset(mac_handle_t mac_handle, uint32_t sessionId);
+void sme_set_ft_ies(mac_handle_t mac_handle, uint32_t sessionId,
const uint8_t *ft_ies, uint16_t ft_ies_length);
-QDF_STATUS sme_ft_update_key(mac_handle_t hHal, uint32_t sessionId,
+QDF_STATUS sme_ft_update_key(mac_handle_t mac_handle, uint32_t sessionId,
tCsrRoamSetKey *pFTKeyInfo);
-void sme_get_ft_pre_auth_response(mac_handle_t hHal, uint32_t sessionId,
+void sme_get_ft_pre_auth_response(mac_handle_t mac_handle, uint32_t sessionId,
uint8_t *ft_ies, uint32_t ft_ies_ip_len,
uint16_t *ft_ies_length);
-void sme_get_rici_es(mac_handle_t hHal, uint32_t sessionId, uint8_t *ric_ies,
+void sme_get_rici_es(mac_handle_t mac_handle, uint32_t sessionId,
+ uint8_t *ric_ies,
uint32_t ric_ies_ip_len, uint32_t *ric_ies_length);
void sme_preauth_reassoc_intvl_timer_callback(void *context);
-void sme_set_ft_pre_auth_state(mac_handle_t hHal, uint32_t sessionId,
+void sme_set_ft_pre_auth_state(mac_handle_t mac_handle, uint32_t sessionId,
bool state);
-bool sme_get_ft_pre_auth_state(mac_handle_t hHal, uint32_t sessionId);
-bool sme_get_ftptk_state(mac_handle_t hHal, uint32_t sessionId);
-void sme_set_ftptk_state(mac_handle_t hHal, uint32_t sessionId, bool state);
+bool sme_get_ft_pre_auth_state(mac_handle_t mac_handle, uint32_t sessionId);
+bool sme_get_ftptk_state(mac_handle_t mac_handle, uint32_t sessionId);
+void sme_set_ftptk_state(mac_handle_t mac_handle, uint32_t sessionId,
+ bool state);
#endif
diff --git a/core/sme/src/common/sme_ft_api.c b/core/sme/src/common/sme_ft_api.c
index 2ce2fcd..98e9c0e 100644
--- a/core/sme/src/common/sme_ft_api.c
+++ b/core/sme/src/common/sme_ft_api.c
@@ -23,9 +23,9 @@
#include <sir_api.h>
/* Initialize the FT context. */
-void sme_ft_open(mac_handle_t hHal, uint32_t sessionId)
+void sme_ft_open(mac_handle_t mac_handle, uint32_t sessionId)
{
- tpAniSirGlobal pMac = PMAC_STRUCT(hHal);
+ tpAniSirGlobal pMac = PMAC_STRUCT(mac_handle);
QDF_STATUS status = QDF_STATUS_SUCCESS;
struct csr_roam_session *pSession = CSR_GET_SESSION(pMac, sessionId);
@@ -58,13 +58,13 @@
}
/* Cleanup the SME FT Global context. */
-void sme_ft_close(mac_handle_t hHal, uint32_t sessionId)
+void sme_ft_close(mac_handle_t mac_handle, uint32_t sessionId)
{
- tpAniSirGlobal pMac = PMAC_STRUCT(hHal);
+ tpAniSirGlobal pMac = PMAC_STRUCT(mac_handle);
struct csr_roam_session *pSession = NULL;
/* Clear the FT Context */
- sme_ft_reset(hHal, sessionId);
+ sme_ft_reset(mac_handle, sessionId);
pSession = CSR_GET_SESSION(pMac, sessionId);
if (NULL != pSession) {
@@ -86,19 +86,19 @@
}
}
-void sme_set_ft_pre_auth_state(mac_handle_t hHal, uint32_t sessionId,
+void sme_set_ft_pre_auth_state(mac_handle_t mac_handle, uint32_t sessionId,
bool state)
{
- tpAniSirGlobal pMac = PMAC_STRUCT(hHal);
+ tpAniSirGlobal pMac = PMAC_STRUCT(mac_handle);
struct csr_roam_session *pSession = CSR_GET_SESSION(pMac, sessionId);
if (pSession)
pSession->ftSmeContext.setFTPreAuthState = state;
}
-bool sme_get_ft_pre_auth_state(mac_handle_t hHal, uint32_t sessionId)
+bool sme_get_ft_pre_auth_state(mac_handle_t mac_handle, uint32_t sessionId)
{
- tpAniSirGlobal pMac = PMAC_STRUCT(hHal);
+ tpAniSirGlobal pMac = PMAC_STRUCT(mac_handle);
struct csr_roam_session *pSession = CSR_GET_SESSION(pMac, sessionId);
if (pSession)
@@ -109,7 +109,7 @@
/**
* sme_set_ft_ies() - to set FT IEs
- * @hal_ptr: pointer to HAL
+ * @mac_handle: opaque handle to the global MAC context
* @session_id: sme session id
* @ft_ies: pointer to FT IEs
* @ft_ies_length: length of FT IEs
@@ -119,10 +119,10 @@
*
* Return: none
*/
-void sme_set_ft_ies(mac_handle_t hal_ptr, uint32_t session_id,
+void sme_set_ft_ies(mac_handle_t mac_handle, uint32_t session_id,
const uint8_t *ft_ies, uint16_t ft_ies_length)
{
- tpAniSirGlobal mac_ctx = PMAC_STRUCT(hal_ptr);
+ tpAniSirGlobal mac_ctx = PMAC_STRUCT(mac_handle);
struct csr_roam_session *session = CSR_GET_SESSION(mac_ctx, session_id);
QDF_STATUS status = QDF_STATUS_E_FAILURE;
@@ -282,9 +282,9 @@
return status;
}
-bool sme_get_ftptk_state(mac_handle_t hHal, uint32_t sessionId)
+bool sme_get_ftptk_state(mac_handle_t mac_handle, uint32_t sessionId)
{
- tpAniSirGlobal pMac = PMAC_STRUCT(hHal);
+ tpAniSirGlobal pMac = PMAC_STRUCT(mac_handle);
struct csr_roam_session *pSession = CSR_GET_SESSION(pMac, sessionId);
if (!pSession) {
@@ -294,9 +294,10 @@
return pSession->ftSmeContext.setFTPTKState;
}
-void sme_set_ftptk_state(mac_handle_t hHal, uint32_t sessionId, bool state)
+void sme_set_ftptk_state(mac_handle_t mac_handle, uint32_t sessionId,
+ bool state)
{
- tpAniSirGlobal pMac = PMAC_STRUCT(hHal);
+ tpAniSirGlobal pMac = PMAC_STRUCT(mac_handle);
struct csr_roam_session *pSession = CSR_GET_SESSION(pMac, sessionId);
if (!pSession) {
@@ -306,10 +307,10 @@
pSession->ftSmeContext.setFTPTKState = state;
}
-QDF_STATUS sme_ft_update_key(mac_handle_t hHal, uint32_t sessionId,
+QDF_STATUS sme_ft_update_key(mac_handle_t mac_handle, uint32_t sessionId,
tCsrRoamSetKey *pFTKeyInfo)
{
- tpAniSirGlobal pMac = PMAC_STRUCT(hHal);
+ tpAniSirGlobal pMac = PMAC_STRUCT(mac_handle);
struct csr_roam_session *pSession = CSR_GET_SESSION(pMac, sessionId);
QDF_STATUS status = QDF_STATUS_E_FAILURE;
@@ -333,7 +334,7 @@
/* Global Station FT State */
switch (pSession->ftSmeContext.FTState) {
case eFT_SET_KEY_WAIT:
- if (sme_get_ft_pre_auth_state(hHal, sessionId) == true) {
+ if (sme_get_ft_pre_auth_state(mac_handle, sessionId) == true) {
status = sme_ft_send_update_key_ind(pMac, sessionId,
pFTKeyInfo);
if (status != 0) {
@@ -345,7 +346,7 @@
status = QDF_STATUS_FT_PREAUTH_KEY_SUCCESS;
sme_debug("Key set success");
}
- sme_set_ft_pre_auth_state(hHal, sessionId, false);
+ sme_set_ft_pre_auth_state(mac_handle, sessionId, false);
}
pSession->ftSmeContext.FTState = eFT_START_READY;
@@ -368,11 +369,11 @@
* supplicant. The supplicant will then proceed to send down the
* Reassoc Req.
*/
-void sme_get_ft_pre_auth_response(mac_handle_t hHal, uint32_t sessionId,
+void sme_get_ft_pre_auth_response(mac_handle_t mac_handle, uint32_t sessionId,
uint8_t *ft_ies, uint32_t ft_ies_ip_len,
uint16_t *ft_ies_length)
{
- tpAniSirGlobal pMac = PMAC_STRUCT(hHal);
+ tpAniSirGlobal pMac = PMAC_STRUCT(mac_handle);
struct csr_roam_session *pSession = CSR_GET_SESSION(pMac, sessionId);
QDF_STATUS status = QDF_STATUS_E_FAILURE;
@@ -418,10 +419,11 @@
* The supplicant will then proceed to send down the
* Reassoc Req.
*/
-void sme_get_rici_es(mac_handle_t hHal, uint32_t sessionId, uint8_t *ric_ies,
+void sme_get_rici_es(mac_handle_t mac_handle, uint32_t sessionId,
+ uint8_t *ric_ies,
uint32_t ric_ies_ip_len, uint32_t *ric_ies_length)
{
- tpAniSirGlobal pMac = PMAC_STRUCT(hHal);
+ tpAniSirGlobal pMac = PMAC_STRUCT(mac_handle);
struct csr_roam_session *pSession = CSR_GET_SESSION(pMac, sessionId);
QDF_STATUS status = QDF_STATUS_E_FAILURE;
@@ -471,9 +473,9 @@
}
/* Reset the FT context. */
-void sme_ft_reset(mac_handle_t hHal, uint32_t sessionId)
+void sme_ft_reset(mac_handle_t mac_handle, uint32_t sessionId)
{
- tpAniSirGlobal pMac = PMAC_STRUCT(hHal);
+ tpAniSirGlobal pMac = PMAC_STRUCT(mac_handle);
struct csr_roam_session *pSession = NULL;
if (pMac == NULL) {