diff --git a/core/mac/src/pe/include/lim_admit_control.h b/core/mac/src/pe/include/lim_admit_control.h index e9de28b902..35204cbdbb 100644 --- a/core/mac/src/pe/include/lim_admit_control.h +++ b/core/mac/src/pe/include/lim_admit_control.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2011-2012, 2014-2017 The Linux Foundation. All rights reserved. + * Copyright (c) 2011-2012, 2014-2018 The Linux Foundation. All rights reserved. * * Permission to use, copy, modify, and/or distribute this software for * any purpose with or without fee is hereby granted, provided that the @@ -34,19 +34,19 @@ #include "ani_global.h" -tSirRetStatus +QDF_STATUS lim_tspec_find_by_assoc_id(tpAniSirGlobal, uint16_t, tSirMacTspecIE *, tpLimTspecInfo, tpLimTspecInfo *); /* Add TSPEC in lim local table */ -tSirRetStatus lim_tspec_add(tpAniSirGlobal pMac, +QDF_STATUS lim_tspec_add(tpAniSirGlobal pMac, uint8_t *pAddr, uint16_t assocId, tSirMacTspecIE *pTspec, uint32_t interval, tpLimTspecInfo *ppInfo); /* admit control interface */ -extern tSirRetStatus lim_admit_control_add_ts(tpAniSirGlobal pMac, +extern QDF_STATUS lim_admit_control_add_ts(tpAniSirGlobal pMac, uint8_t *pAddr, tSirAddtsReqInfo *addts, tSirMacQosCapabilityStaIE *qos, uint16_t assocId, uint8_t alloc, @@ -55,39 +55,39 @@ extern tSirRetStatus lim_admit_control_add_ts(tpAniSirGlobal pMac, uint8_t *pTspecIdx, tpPESession psessionEntry); -static inline tSirRetStatus +static inline QDF_STATUS lim_admit_control_add_sta(tpAniSirGlobal pMac, uint8_t *staAddr, uint8_t alloc) { - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } -extern tSirRetStatus +extern QDF_STATUS lim_admit_control_delete_sta(tpAniSirGlobal pMac, uint16_t assocId); -extern tSirRetStatus +extern QDF_STATUS lim_admit_control_delete_ts(tpAniSirGlobal pMac, uint16_t assocId, tSirMacTSInfo *tsinfo, uint8_t *tsStatus, uint8_t *tspecIdx); -extern tSirRetStatus lim_update_admit_policy(tpAniSirGlobal pMac); +extern QDF_STATUS lim_update_admit_policy(tpAniSirGlobal pMac); -tSirRetStatus lim_admit_control_init(tpAniSirGlobal pMac); +QDF_STATUS lim_admit_control_init(tpAniSirGlobal pMac); #ifdef FEATURE_WLAN_ESE -tSirRetStatus lim_send_hal_msg_add_ts(tpAniSirGlobal pMac, +QDF_STATUS lim_send_hal_msg_add_ts(tpAniSirGlobal pMac, uint16_t staIdx, uint8_t tspecIdx, tSirMacTspecIE tspecIE, uint8_t sessionId, uint16_t tsm_interval); #else -tSirRetStatus lim_send_hal_msg_add_ts(tpAniSirGlobal pMac, +QDF_STATUS lim_send_hal_msg_add_ts(tpAniSirGlobal pMac, uint16_t staIdx, uint8_t tspecIdx, tSirMacTspecIE tspecIE, uint8_t sessionId); #endif -tSirRetStatus lim_send_hal_msg_del_ts(tpAniSirGlobal pMac, +QDF_STATUS lim_send_hal_msg_del_ts(tpAniSirGlobal pMac, uint16_t staIdx, uint8_t tspecIdx, tSirDeltsReqInfo delts, diff --git a/core/mac/src/pe/include/lim_api.h b/core/mac/src/pe/include/lim_api.h index f03aa371a3..73ae654e9e 100644 --- a/core/mac/src/pe/include/lim_api.h +++ b/core/mac/src/pe/include/lim_api.h @@ -108,15 +108,15 @@ typedef enum eMgmtFrmDropReason { * Function to initialize LIM state machines. * This called upon LIM thread creation. */ -extern tSirRetStatus lim_initialize(tpAniSirGlobal); -tSirRetStatus pe_open(tpAniSirGlobal pMac, struct cds_config_info *cds_cfg); -tSirRetStatus pe_close(tpAniSirGlobal pMac); +extern QDF_STATUS lim_initialize(tpAniSirGlobal); +QDF_STATUS pe_open(tpAniSirGlobal pMac, struct cds_config_info *cds_cfg); +QDF_STATUS pe_close(tpAniSirGlobal pMac); void pe_register_tl_handle(tpAniSirGlobal pMac); -tSirRetStatus lim_start(tpAniSirGlobal pMac); -tSirRetStatus pe_start(tpAniSirGlobal pMac); +QDF_STATUS lim_start(tpAniSirGlobal pMac); +QDF_STATUS pe_start(tpAniSirGlobal pMac); void pe_stop(tpAniSirGlobal pMac); -tSirRetStatus pe_post_msg_api(tpAniSirGlobal pMac, struct scheduler_msg *pMsg); -tSirRetStatus peProcessMsg(tpAniSirGlobal pMac, struct scheduler_msg *limMsg); +QDF_STATUS pe_post_msg_api(tpAniSirGlobal pMac, struct scheduler_msg *pMsg); +QDF_STATUS peProcessMsg(tpAniSirGlobal pMac, struct scheduler_msg *limMsg); /** * pe_register_mgmt_rx_frm_callback() - registers callback for receiving @@ -177,7 +177,7 @@ extern uint8_t lim_is_system_in_scan_state(tpAniSirGlobal); * Function to handle IBSS coalescing. * Beacon Processing module to call this. */ -extern tSirRetStatus lim_handle_ibss_coalescing(tpAniSirGlobal, +extern QDF_STATUS lim_handle_ibss_coalescing(tpAniSirGlobal, tpSchBeaconStruct, uint8_t *, tpPESession); /* / Function used by other Sirius modules to read global SME state */ @@ -219,7 +219,7 @@ static inline void lim_set_tdls_flags(roam_offload_synch_ind *roam_sync_ind_ptr, /* / Function that checks for change in AP's capabilties on STA */ extern void lim_detect_change_in_ap_capabilities(tpAniSirGlobal, tpSirProbeRespBeacon, tpPESession); -tSirRetStatus lim_update_short_slot(tpAniSirGlobal pMac, +QDF_STATUS lim_update_short_slot(tpAniSirGlobal pMac, tpSirProbeRespBeacon pBeacon, tpUpdateBeaconParams pBeaconParams, tpPESession); @@ -296,7 +296,7 @@ static inline void lim_get_rf_band_new(tpAniSirGlobal pMac, \return uint32_t - TX_SUCCESS for success. --------------------------------------------------------------------------*/ -tSirRetStatus pe_process_messages(tpAniSirGlobal pMac, +QDF_STATUS pe_process_messages(tpAniSirGlobal pMac, struct scheduler_msg *pMsg); QDF_STATUS pe_mc_process_handler(struct scheduler_msg *msg); diff --git a/core/mac/src/pe/include/lim_ft.h b/core/mac/src/pe/include/lim_ft.h index 045f0bde9b..25abe4e34b 100644 --- a/core/mac/src/pe/include/lim_ft.h +++ b/core/mac/src/pe/include/lim_ft.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2011-2017 The Linux Foundation. All rights reserved. + * Copyright (c) 2011-2018 The Linux Foundation. All rights reserved. * * Permission to use, copy, modify, and/or distribute this software for * any purpose with or without fee is hereby granted, provided that the @@ -45,13 +45,13 @@ void lim_process_mlm_ft_reassoc_req(tpAniSirGlobal pMac, uint32_t *pMsgBuf, tpPESession psessionEntry); void lim_perform_ft_pre_auth(tpAniSirGlobal pMac, QDF_STATUS status, uint32_t *data, tpPESession psessionEntry); -void lim_post_ft_pre_auth_rsp(tpAniSirGlobal pMac, tSirRetStatus status, +void lim_post_ft_pre_auth_rsp(tpAniSirGlobal pMac, QDF_STATUS status, uint8_t *auth_rsp, uint16_t auth_rsp_length, tpPESession psessionEntry); -void lim_handle_ft_pre_auth_rsp(tpAniSirGlobal pMac, tSirRetStatus status, +void lim_handle_ft_pre_auth_rsp(tpAniSirGlobal pMac, QDF_STATUS status, uint8_t *auth_rsp, uint16_t auth_rsp_len, tpPESession psessionEntry); -tSirRetStatus lim_ft_setup_auth_session(tpAniSirGlobal pMac, +QDF_STATUS lim_ft_setup_auth_session(tpAniSirGlobal pMac, tpPESession psessionEntry); void lim_process_mlm_reassoc_cnf(tpAniSirGlobal mac_ctx, uint32_t *msg); void lim_process_sta_mlm_add_bss_rsp_ft(tpAniSirGlobal pMac, @@ -73,7 +73,7 @@ static inline void lim_process_mlm_ft_reassoc_req(tpAniSirGlobal pMac, uint32_t *pMsgBuf, tpPESession psessionEntry) {} static inline void lim_handle_ft_pre_auth_rsp(tpAniSirGlobal pMac, - tSirRetStatus status, uint8_t *auth_rsp, + QDF_STATUS status, uint8_t *auth_rsp, uint16_t auth_rsp_len, tpPESession psessionEntry) {} static inline void lim_process_mlm_reassoc_cnf(tpAniSirGlobal mac_ctx, @@ -119,7 +119,7 @@ static inline void lim_ft_prepare_add_bss_req(tpAniSirGlobal pMac, #endif bool lim_process_ft_update_key(tpAniSirGlobal pMac, uint32_t *pMsgBuf); -tSirRetStatus lim_process_ft_aggr_qos_req(tpAniSirGlobal pMac, +QDF_STATUS lim_process_ft_aggr_qos_req(tpAniSirGlobal pMac, uint32_t *pMsgBuf); void lim_process_ft_aggr_qo_s_rsp(tpAniSirGlobal pMac, struct scheduler_msg *limMsg); diff --git a/core/mac/src/pe/include/lim_ft_defs.h b/core/mac/src/pe/include/lim_ft_defs.h index 4311136d57..909143c9ef 100644 --- a/core/mac/src/pe/include/lim_ft_defs.h +++ b/core/mac/src/pe/include/lim_ft_defs.h @@ -70,7 +70,7 @@ typedef struct sSirFTPreAuthRsp { uint16_t length; uint8_t smeSessionId; tSirMacAddr preAuthbssId; /* BSSID to preauth to */ - tSirRetStatus status; + QDF_STATUS status; uint16_t ft_ies_length; uint8_t ft_ies[MAX_FTIE_SIZE]; uint16_t ric_ies_length; @@ -102,7 +102,7 @@ typedef struct sSirFTPreAuthKeyInfo { ------------------------------------------------------------------------*/ typedef struct sFTPEContext { tpSirFTPreAuthReq pFTPreAuthReq; /* Saved FT Pre Auth Req */ - tSirRetStatus ftPreAuthStatus; + QDF_STATUS ftPreAuthStatus; uint16_t saved_auth_rsp_length; uint8_t saved_auth_rsp[MAX_FTIE_SIZE]; tSirFTPreAuthKeyInfo PreAuthKeyInfo; diff --git a/core/mac/src/pe/lim/lim_admit_control.c b/core/mac/src/pe/lim/lim_admit_control.c index e15f81f735..9b26629521 100644 --- a/core/mac/src/pe/lim/lim_admit_control.c +++ b/core/mac/src/pe/lim/lim_admit_control.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2011-2017 The Linux Foundation. All rights reserved. + * Copyright (c) 2011-2018 The Linux Foundation. All rights reserved. * * Permission to use, copy, modify, and/or distribute this software for * any purpose with or without fee is hereby granted, provided that the @@ -55,26 +55,26 @@ /* ------------------------------------------------------------------------------ */ /* local protos */ -static tSirRetStatus +static QDF_STATUS lim_calculate_svc_int(tpAniSirGlobal, tSirMacTspecIE *, uint32_t *); -static tSirRetStatus +static QDF_STATUS lim_validate_tspec_edca(tpAniSirGlobal, tSirMacTspecIE *, tpPESession); -static tSirRetStatus +static QDF_STATUS lim_validate_tspec(tpAniSirGlobal, tSirMacTspecIE *, tpPESession); static void lim_compute_mean_bw_used(tpAniSirGlobal, uint32_t *, uint32_t, tpLimTspecInfo, tpPESession); static void lim_get_available_bw(tpAniSirGlobal, uint32_t *, uint32_t *, uint32_t, uint32_t); -static tSirRetStatus lim_admit_policy_oversubscription(tpAniSirGlobal, +static QDF_STATUS lim_admit_policy_oversubscription(tpAniSirGlobal, tSirMacTspecIE *, tpLimAdmitPolicyInfo, tpLimTspecInfo, tpPESession); -static tSirRetStatus lim_tspec_find_by_sta_addr(tpAniSirGlobal, uint8_t *, +static QDF_STATUS lim_tspec_find_by_sta_addr(tpAniSirGlobal, uint8_t *, tSirMacTspecIE *, tpLimTspecInfo, tpLimTspecInfo *); -static tSirRetStatus lim_validate_access_policy(tpAniSirGlobal, uint8_t, uint16_t, +static QDF_STATUS lim_validate_access_policy(tpAniSirGlobal, uint8_t, uint16_t, tpPESession); /** ------------------------------------------------------------- @@ -86,7 +86,7 @@ static tSirRetStatus lim_validate_access_policy(tpAniSirGlobal, uint8_t, uint16_ \return eSirRetStatus - status of the comparison -------------------------------------------------------------*/ -static tSirRetStatus +static QDF_STATUS lim_calculate_svc_int(tpAniSirGlobal pMac, tSirMacTspecIE *pTspec, uint32_t *pSvcInt) { @@ -97,7 +97,7 @@ lim_calculate_svc_int(tpAniSirGlobal pMac, if ((pTspec->minSvcInterval != 0) || (pTspec->maxSvcInterval != 0)) { *pSvcInt = (pTspec->maxSvcInterval != 0) ? pTspec->maxSvcInterval : pTspec->minSvcInterval; - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /* Masking off the fixed bits according to definition of MSDU size @@ -110,7 +110,7 @@ lim_calculate_svc_int(tpAniSirGlobal pMac, msduSz = pTspec->maxMsduSz; else { pe_err("MsduSize not specified"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } /* need to calculate a reasonable service interval @@ -124,12 +124,12 @@ lim_calculate_svc_int(tpAniSirGlobal pMac, dataRate = pTspec->minDataRate; else { pe_err("DataRate not specified"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } *pSvcInt = LIM_CONVERT_SIZE_BITS(msduSz) / LIM_CONVERT_RATE_MBPS(dataRate); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } /** @@ -143,13 +143,13 @@ lim_calculate_svc_int(tpAniSirGlobal pMac, * * Return: Status **/ -static tSirRetStatus +static QDF_STATUS lim_validate_tspec_edca(tpAniSirGlobal mac_ctx, tSirMacTspecIE *tspec, tpPESession session_entry) { uint32_t max_phy_rate, min_phy_rate; uint32_t phy_mode; - tSirRetStatus retval = eSIR_SUCCESS; + QDF_STATUS retval = QDF_STATUS_SUCCESS; lim_get_phy_mode(mac_ctx, &phy_mode, session_entry); @@ -164,7 +164,7 @@ lim_validate_tspec_edca(tpAniSirGlobal mac_ctx, pe_warn("Invalid EDCA Tspec: NomMsdu: %d meanDataRate: %d surplusBw: %d min_phy_rate: %d", tspec->nomMsduSz, tspec->meanDataRate, tspec->surplusBw, tspec->minPhyRate); - retval = eSIR_FAILURE; + retval = QDF_STATUS_E_FAILURE; } pe_debug("return status: %d", retval); @@ -179,16 +179,16 @@ lim_validate_tspec_edca(tpAniSirGlobal mac_ctx, \return eSirRetStatus - status -------------------------------------------------------------*/ -static tSirRetStatus +static QDF_STATUS lim_validate_tspec(tpAniSirGlobal pMac, tSirMacTspecIE *pTspec, tpPESession psessionEntry) { - tSirRetStatus retval = eSIR_SUCCESS; + QDF_STATUS retval = QDF_STATUS_SUCCESS; switch (pTspec->tsinfo.traffic.accessPolicy) { case SIR_MAC_ACCESSPOLICY_EDCA: retval = lim_validate_tspec_edca(pMac, pTspec, psessionEntry); - if (retval != eSIR_SUCCESS) + if (retval != QDF_STATUS_SUCCESS) pe_warn("EDCA tspec invalid"); break; @@ -198,7 +198,7 @@ lim_validate_tspec(tpAniSirGlobal pMac, default: pe_warn("AccessType: %d not supported", pTspec->tsinfo.traffic.accessPolicy); - retval = eSIR_FAILURE; + retval = QDF_STATUS_E_FAILURE; break; } return retval; @@ -294,7 +294,7 @@ lim_get_available_bw(tpAniSirGlobal pMac, * * Return: Status **/ -static tSirRetStatus +static QDF_STATUS lim_admit_policy_oversubscription(tpAniSirGlobal mac_ctx, tSirMacTspecIE *tspec, tpLimAdmitPolicyInfo admit_policy, @@ -315,14 +315,14 @@ lim_admit_policy_oversubscription(tpAniSirGlobal mac_ctx, admit_policy->bw_factor); if (usedbw > totalbw) /* this can't possibly happen */ - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; if ((totalbw - usedbw) < tspec->meanDataRate) { pe_warn("Total BW: %d Used: %d Tspec request: %d not possible", totalbw, usedbw, tspec->meanDataRate); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /** ------------------------------------------------------------- @@ -333,16 +333,16 @@ lim_admit_policy_oversubscription(tpAniSirGlobal mac_ctx, \return eSirRetStatus - status -------------------------------------------------------------*/ -static tSirRetStatus lim_admit_policy(tpAniSirGlobal pMac, +static QDF_STATUS lim_admit_policy(tpAniSirGlobal pMac, tSirMacTspecIE *pTspec, tpPESession psessionEntry) { - tSirRetStatus retval = eSIR_FAILURE; + QDF_STATUS retval = QDF_STATUS_E_FAILURE; tpLimAdmitPolicyInfo pAdmitPolicy = &pMac->lim.admitPolicyInfo; switch (pAdmitPolicy->type) { case WNI_CFG_ADMIT_POLICY_ADMIT_ALL: - retval = eSIR_SUCCESS; + retval = QDF_STATUS_SUCCESS; break; case WNI_CFG_ADMIT_POLICY_BW_FACTOR: @@ -351,16 +351,16 @@ static tSirRetStatus lim_admit_policy(tpAniSirGlobal pMac, admitPolicyInfo, &pMac->lim.tspecInfo[0], psessionEntry); - if (retval != eSIR_SUCCESS) + if (retval != QDF_STATUS_SUCCESS) pe_err("rejected by BWFactor policy"); break; case WNI_CFG_ADMIT_POLICY_REJECT_ALL: - retval = eSIR_FAILURE; + retval = QDF_STATUS_E_FAILURE; break; default: - retval = eSIR_SUCCESS; + retval = QDF_STATUS_SUCCESS; pe_warn("Admit Policy: %d unknown, admitting all traffic", pAdmitPolicy->type); break; @@ -401,7 +401,7 @@ static void lim_tspec_delete(tpAniSirGlobal pMac, tpLimTspecInfo pInfo) -------------------------------------------------------------*/ /* find the specified tspec in the list */ -static tSirRetStatus +static QDF_STATUS lim_tspec_find_by_sta_addr(tpAniSirGlobal pMac, uint8_t *pAddr, tSirMacTspecIE *pTspecIE, @@ -421,10 +421,10 @@ lim_tspec_find_by_sta_addr(tpAniSirGlobal pMac, ((uint8_t *) pTspecIE, (uint8_t *) &pTspecList->tspec, sizeof(tSirMacTspecIE)))) { *ppInfo = pTspecList; - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } } - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } /** ------------------------------------------------------------- @@ -438,7 +438,7 @@ lim_tspec_find_by_sta_addr(tpAniSirGlobal pMac, \return eSirRetStatus - status -------------------------------------------------------------*/ -tSirRetStatus +QDF_STATUS lim_tspec_find_by_assoc_id(tpAniSirGlobal pMac, uint16_t assocId, tSirMacTspecIE *pTspecIE, @@ -460,10 +460,10 @@ lim_tspec_find_by_assoc_id(tpAniSirGlobal pMac, ((uint8_t *) pTspecIE, (uint8_t *) &pTspecList->tspec, sizeof(tSirMacTspecIE)))) { *ppInfo = pTspecList; - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } } - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } /** ------------------------------------------------------------- @@ -477,7 +477,7 @@ lim_tspec_find_by_assoc_id(tpAniSirGlobal pMac, \return eSirRetStatus - status of the comparison -------------------------------------------------------------*/ -static tSirRetStatus +static QDF_STATUS lim_find_tspec(tpAniSirGlobal pMac, uint16_t assocId, tSirMacTSInfo *pTsInfo, @@ -498,10 +498,10 @@ lim_find_tspec(tpAniSirGlobal pMac, && (pTsInfo->traffic.tsid == pTspecList->tspec.tsinfo.traffic.tsid)) { *ppInfo = pTspecList; - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } } - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } /** ------------------------------------------------------------- @@ -517,7 +517,7 @@ lim_find_tspec(tpAniSirGlobal pMac, \return eSirRetStatus - status of the comparison -------------------------------------------------------------*/ -tSirRetStatus lim_tspec_add(tpAniSirGlobal pMac, +QDF_STATUS lim_tspec_add(tpAniSirGlobal pMac, uint8_t *pAddr, uint16_t assocId, tSirMacTspecIE *pTspec, @@ -529,13 +529,13 @@ tSirRetStatus lim_tspec_add(tpAniSirGlobal pMac, /* validate the assocId */ if (assocId >= pMac->lim.maxStation) { pe_err("Invalid assocId 0x%x", assocId); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } /* decide whether to add/update */ { *ppInfo = NULL; - if (eSIR_SUCCESS == + if (QDF_STATUS_SUCCESS == lim_find_tspec(pMac, assocId, &pTspec->tsinfo, pTspecList, ppInfo)) { /* update this entry. */ @@ -558,7 +558,7 @@ tSirRetStatus lim_tspec_add(tpAniSirGlobal pMac, } if (ctspec >= LIM_NUM_TSPEC_MAX) - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; /* Record the new index entry */ pTspecList->idx = ctspec; @@ -575,7 +575,7 @@ tSirRetStatus lim_tspec_add(tpAniSirGlobal pMac, pTspecList->inuse = 1; *ppInfo = pTspecList; pe_debug("added entry for EDCA AccessPolicy"); - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /* @@ -590,7 +590,7 @@ tSirRetStatus lim_tspec_add(tpAniSirGlobal pMac, pTspecList->inuse = 1; *ppInfo = pTspecList; pe_debug("added entry for HCCA AccessPolicy"); - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /** ------------------------------------------------------------- @@ -602,24 +602,24 @@ tSirRetStatus lim_tspec_add(tpAniSirGlobal pMac, \return eSirRetStatus - status -------------------------------------------------------------*/ -static tSirRetStatus +static QDF_STATUS lim_validate_access_policy(tpAniSirGlobal pMac, uint8_t accessPolicy, uint16_t assocId, tpPESession psessionEntry) { - tSirRetStatus retval = eSIR_FAILURE; + QDF_STATUS retval = QDF_STATUS_E_FAILURE; tpDphHashNode pSta = dph_get_hash_entry(pMac, assocId, &psessionEntry->dph.dphHashTable); if ((pSta == NULL) || (!pSta->valid)) { pe_err("invalid station address passed"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } switch (accessPolicy) { case SIR_MAC_ACCESSPOLICY_EDCA: if (pSta->wmeEnabled || pSta->lleEnabled) - retval = eSIR_SUCCESS; + retval = QDF_STATUS_SUCCESS; break; case SIR_MAC_ACCESSPOLICY_HCCA: @@ -630,7 +630,7 @@ lim_validate_access_policy(tpAniSirGlobal pMac, break; } - if (retval != eSIR_SUCCESS) + if (retval != QDF_STATUS_SUCCESS) pe_warn("accPol: %d staId: %d lle: %d wme: %d wsm: %d", accessPolicy, pSta->staIndex, pSta->lleEnabled, pSta->wmeEnabled, pSta->wsmEnabled); @@ -655,13 +655,13 @@ lim_validate_access_policy(tpAniSirGlobal pMac, * * Return: status **/ -tSirRetStatus lim_admit_control_add_ts(tpAniSirGlobal pMac, uint8_t *pAddr, +QDF_STATUS lim_admit_control_add_ts(tpAniSirGlobal pMac, uint8_t *pAddr, tSirAddtsReqInfo *pAddts, tSirMacQosCapabilityStaIE *pQos, uint16_t assocId, uint8_t alloc, tSirMacScheduleIE *pSch, uint8_t *pTspecIdx, tpPESession psessionEntry) { tpLimTspecInfo pTspecInfo; - tSirRetStatus retval; + QDF_STATUS retval; uint32_t svcInterval; (void)pQos; @@ -683,26 +683,26 @@ tSirRetStatus lim_admit_control_add_ts(tpAniSirGlobal pMac, uint8_t *pAddr, : lim_tspec_find_by_sta_addr(pMac, pAddr, &pAddts->tspec, &pMac->lim.tspecInfo[0], &pTspecInfo); - if (retval == eSIR_SUCCESS) { + if (retval == QDF_STATUS_SUCCESS) { pe_err("duplicate tspec index: %d", pTspecInfo->idx); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } /* check that the tspec's are well formed and acceptable */ if (lim_validate_tspec(pMac, &pAddts->tspec, psessionEntry) != - eSIR_SUCCESS) { + QDF_STATUS_SUCCESS) { pe_warn("tspec validation failed"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } /* determine a service interval for the tspec */ if (lim_calculate_svc_int(pMac, &pAddts->tspec, &svcInterval) != - eSIR_SUCCESS) { + QDF_STATUS_SUCCESS) { pe_warn("SvcInt calculate failed"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } /* determine if the tspec can be admitted or not based on current policy */ - if (lim_admit_policy(pMac, &pAddts->tspec, psessionEntry) != eSIR_SUCCESS) { + if (lim_admit_policy(pMac, &pAddts->tspec, psessionEntry) != QDF_STATUS_SUCCESS) { pe_warn("tspec rejected by admit control policy"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } /* fill in a schedule if requested */ if (pSch != NULL) { @@ -718,27 +718,27 @@ tSirRetStatus lim_admit_control_add_ts(tpAniSirGlobal pMac, uint8_t *pAddr, } /* if no allocation is requested, done */ if (!alloc) - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; /* check that we are in the proper mode to deal with the tspec type */ if (lim_validate_access_policy (pMac, (uint8_t) pAddts->tspec.tsinfo.traffic.accessPolicy, assocId, - psessionEntry) != eSIR_SUCCESS) { + psessionEntry) != QDF_STATUS_SUCCESS) { pe_warn("AccessPolicy: %d is not valid in current mode", pAddts->tspec.tsinfo.traffic.accessPolicy); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } /* add tspec to list */ if (lim_tspec_add (pMac, pAddr, assocId, &pAddts->tspec, svcInterval, &pTspecInfo) - != eSIR_SUCCESS) { + != QDF_STATUS_SUCCESS) { pe_err("no space in tspec list"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } /* passing lim tspec table index to the caller */ *pTspecIdx = pTspecInfo->idx; - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /** ------------------------------------------------------------- @@ -752,7 +752,7 @@ tSirRetStatus lim_admit_control_add_ts(tpAniSirGlobal pMac, uint8_t *pAddr, \return eSirRetStatus - status -------------------------------------------------------------*/ -tSirRetStatus +QDF_STATUS lim_admit_control_delete_ts(tpAniSirGlobal pMac, uint16_t assocId, tSirMacTSInfo *pTsInfo, @@ -765,16 +765,16 @@ lim_admit_control_delete_ts(tpAniSirGlobal pMac, if (lim_find_tspec (pMac, assocId, pTsInfo, &pMac->lim.tspecInfo[0], - &pTspecInfo) == eSIR_SUCCESS) { + &pTspecInfo) == QDF_STATUS_SUCCESS) { if (pTspecInfo != NULL) { pe_debug("Tspec entry: %d found", pTspecInfo->idx); *ptspecIdx = pTspecInfo->idx; lim_tspec_delete(pMac, pTspecInfo); - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } } - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } /** ------------------------------------------------------------- @@ -785,7 +785,7 @@ lim_admit_control_delete_ts(tpAniSirGlobal pMac, \return eSirRetStatus - status -------------------------------------------------------------*/ -tSirRetStatus lim_admit_control_delete_sta(tpAniSirGlobal pMac, uint16_t assocId) +QDF_STATUS lim_admit_control_delete_sta(tpAniSirGlobal pMac, uint16_t assocId) { tpLimTspecInfo pTspecInfo = &pMac->lim.tspecInfo[0]; int ctspec; @@ -799,7 +799,7 @@ tSirRetStatus lim_admit_control_delete_sta(tpAniSirGlobal pMac, uint16_t assocId } pe_debug("assocId: %d done", assocId); - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /** ------------------------------------------------------------- @@ -808,11 +808,11 @@ tSirRetStatus lim_admit_control_delete_sta(tpAniSirGlobal pMac, uint16_t assocId \param tpAniSirGlobal pMac \return eSirRetStatus - status -------------------------------------------------------------*/ -tSirRetStatus lim_admit_control_init(tpAniSirGlobal pMac) +QDF_STATUS lim_admit_control_init(tpAniSirGlobal pMac) { qdf_mem_set(pMac->lim.tspecInfo, LIM_NUM_TSPEC_MAX * sizeof(tLimTspecInfo), 0); - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /** ------------------------------------------------------------- @@ -822,18 +822,18 @@ tSirRetStatus lim_admit_control_init(tpAniSirGlobal pMac) \return eSirRetStatus - status -------------------------------------------------------------*/ -tSirRetStatus lim_update_admit_policy(tpAniSirGlobal pMac) +QDF_STATUS lim_update_admit_policy(tpAniSirGlobal pMac) { uint32_t val; - if (wlan_cfg_get_int(pMac, WNI_CFG_ADMIT_POLICY, &val) != eSIR_SUCCESS) { + if (wlan_cfg_get_int(pMac, WNI_CFG_ADMIT_POLICY, &val) != QDF_STATUS_SUCCESS) { pe_err("Unable to get CFG_ADMIT_POLICY"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } pMac->lim.admitPolicyInfo.type = (uint8_t) val; - if (wlan_cfg_get_int(pMac, WNI_CFG_ADMIT_BWFACTOR, &val) != eSIR_SUCCESS) { + if (wlan_cfg_get_int(pMac, WNI_CFG_ADMIT_BWFACTOR, &val) != QDF_STATUS_SUCCESS) { pe_err("Unable to get CFG_ADMIT_BWFACTOR"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } pMac->lim.admitPolicyInfo.bw_factor = (uint8_t) val; @@ -841,7 +841,7 @@ tSirRetStatus lim_update_admit_policy(tpAniSirGlobal pMac) pMac->lim.admitPolicyInfo.type, pMac->lim.admitPolicyInfo.bw_factor); - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /** ------------------------------------------------------------- @@ -857,14 +857,14 @@ tSirRetStatus lim_update_admit_policy(tpAniSirGlobal pMac) \return eSirRetStatus - status -------------------------------------------------------------*/ #ifdef FEATURE_WLAN_ESE -tSirRetStatus +QDF_STATUS lim_send_hal_msg_add_ts(tpAniSirGlobal pMac, uint16_t staIdx, uint8_t tspecIdx, tSirMacTspecIE tspecIE, uint8_t sessionId, uint16_t tsm_interval) #else -tSirRetStatus +QDF_STATUS lim_send_hal_msg_add_ts(tpAniSirGlobal pMac, uint16_t staIdx, uint8_t tspecIdx, tSirMacTspecIE tspecIE, uint8_t sessionId) @@ -878,13 +878,13 @@ lim_send_hal_msg_add_ts(tpAniSirGlobal pMac, if (psessionEntry == NULL) { pe_err("Unable to get Session for session Id: %d", sessionId); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } pAddTsParam = qdf_mem_malloc(sizeof(tAddTsParams)); if (NULL == pAddTsParam) { pe_err("AllocateMemory() failed"); - return eSIR_MEM_ALLOC_FAILED; + return QDF_STATUS_E_NOMEM; } pAddTsParam->staIdx = staIdx; @@ -912,13 +912,13 @@ lim_send_hal_msg_add_ts(tpAniSirGlobal pMac, SET_LIM_PROCESS_DEFD_MESGS(pMac, false); MTRACE(mac_trace_msg_tx(pMac, sessionId, msg.type)); - if (eSIR_SUCCESS != wma_post_ctrl_msg(pMac, &msg)) { + if (QDF_STATUS_SUCCESS != wma_post_ctrl_msg(pMac, &msg)) { pe_warn("wma_post_ctrl_msg() failed"); SET_LIM_PROCESS_DEFD_MESGS(pMac, true); qdf_mem_free(pAddTsParam); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /** ------------------------------------------------------------- @@ -931,7 +931,7 @@ lim_send_hal_msg_add_ts(tpAniSirGlobal pMac, \return eSirRetStatus - status -------------------------------------------------------------*/ -tSirRetStatus +QDF_STATUS lim_send_hal_msg_del_ts(tpAniSirGlobal pMac, uint16_t staIdx, uint8_t tspecIdx, @@ -944,7 +944,7 @@ lim_send_hal_msg_del_ts(tpAniSirGlobal pMac, pDelTsParam = qdf_mem_malloc(sizeof(tDelTsParams)); if (NULL == pDelTsParam) { pe_err("AllocateMemory() failed"); - return eSIR_MEM_ALLOC_FAILED; + return QDF_STATUS_E_NOMEM; } msg.type = WMA_DEL_TS_REQ; @@ -977,15 +977,15 @@ lim_send_hal_msg_del_ts(tpAniSirGlobal pMac, #endif MTRACE(mac_trace_msg_tx(pMac, sessionId, msg.type)); - if (eSIR_SUCCESS != wma_post_ctrl_msg(pMac, &msg)) { + if (QDF_STATUS_SUCCESS != wma_post_ctrl_msg(pMac, &msg)) { pe_warn("wma_post_ctrl_msg() failed"); goto err; } - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; err: qdf_mem_free(pDelTsParam); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } /** ------------------------------------------------------------- diff --git a/core/mac/src/pe/lim/lim_api.c b/core/mac/src/pe/lim/lim_api.c index e0cea6f1b3..ba9e95c334 100644 --- a/core/mac/src/pe/lim/lim_api.c +++ b/core/mac/src/pe/lim/lim_api.c @@ -260,7 +260,7 @@ static void __lim_init_ht_vars(tpAniSirGlobal pMac) pMac->lim.gHTSTBCBasicMCS = 0; } -static tSirRetStatus __lim_init_config(tpAniSirGlobal pMac) +static QDF_STATUS __lim_init_config(tpAniSirGlobal pMac) { uint32_t val1, val2, val3; uint16_t val16; @@ -275,22 +275,22 @@ static tSirRetStatus __lim_init_config(tpAniSirGlobal pMac) */ if (wlan_cfg_get_int(pMac, WNI_CFG_ASSOC_STA_LIMIT, &val1) - != eSIR_SUCCESS){ + != QDF_STATUS_SUCCESS){ pe_err("cfg get assoc sta limit failed"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } pMac->lim.gLimAssocStaLimit = val1; pMac->lim.gLimIbssStaLimit = val1; - if (wlan_cfg_get_int(pMac, WNI_CFG_HT_CAP_INFO, &val1) != eSIR_SUCCESS) { + if (wlan_cfg_get_int(pMac, WNI_CFG_HT_CAP_INFO, &val1) != QDF_STATUS_SUCCESS) { pe_err("could not retrieve HT Cap CFG"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } if (wlan_cfg_get_int(pMac, WNI_CFG_CHANNEL_BONDING_MODE, &val2) != - eSIR_SUCCESS) { + QDF_STATUS_SUCCESS) { pe_err("could not retrieve Channel Bonding CFG"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } val16 = (uint16_t) val1; pHTCapabilityInfo = (tSirMacHTCapabilityInfo *) &val16; @@ -302,14 +302,14 @@ static tSirRetStatus __lim_init_config(tpAniSirGlobal pMac) WNI_CFG_CHANNEL_BONDING_MODE_DISABLE; if (cfg_set_int (pMac, WNI_CFG_HT_CAP_INFO, *(uint16_t *) pHTCapabilityInfo) - != eSIR_SUCCESS) { + != QDF_STATUS_SUCCESS) { pe_err("could not update HT Cap Info CFG"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } - if (wlan_cfg_get_int(pMac, WNI_CFG_HT_INFO_FIELD1, &val1) != eSIR_SUCCESS) { + if (wlan_cfg_get_int(pMac, WNI_CFG_HT_INFO_FIELD1, &val1) != QDF_STATUS_SUCCESS) { pe_err("could not retrieve HT INFO Field1 CFG"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } val8 = (uint8_t) val1; @@ -317,17 +317,17 @@ static tSirRetStatus __lim_init_config(tpAniSirGlobal pMac) pHTInfoField1->recommendedTxWidthSet = (uint8_t) pHTCapabilityInfo->supportedChannelWidthSet; if (cfg_set_int(pMac, WNI_CFG_HT_INFO_FIELD1, *(uint8_t *) pHTInfoField1) - != eSIR_SUCCESS) { + != QDF_STATUS_SUCCESS) { pe_err("could not update HT Info Field"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } /* WNI_CFG_HEART_BEAT_THRESHOLD */ if (wlan_cfg_get_int(pMac, WNI_CFG_HEART_BEAT_THRESHOLD, &val1) != - eSIR_SUCCESS) { + QDF_STATUS_SUCCESS) { pe_err("could not retrieve WNI_CFG_HEART_BEAT_THRESHOLD CFG"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } if (!val1) { pMac->sys.gSysEnableLinkMonitorMode = 0; @@ -339,19 +339,19 @@ static tSirRetStatus __lim_init_config(tpAniSirGlobal pMac) /* WNI_CFG_MAX_RX_AMPDU_FACTOR */ if (wlan_cfg_get_int(pMac, WNI_CFG_HT_AMPDU_PARAMS, &val1) != - eSIR_SUCCESS) { + QDF_STATUS_SUCCESS) { pe_err("could not retrieve HT AMPDU Param"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } if (wlan_cfg_get_int(pMac, WNI_CFG_MAX_RX_AMPDU_FACTOR, &val2) != - eSIR_SUCCESS) { + QDF_STATUS_SUCCESS) { pe_err("could not retrieve AMPDU Factor CFG"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } if (wlan_cfg_get_int(pMac, WNI_CFG_MPDU_DENSITY, &val3) != - eSIR_SUCCESS) { + QDF_STATUS_SUCCESS) { pe_err("could not retrieve MPDU Density CFG"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } val16 = (uint16_t) val1; @@ -360,16 +360,16 @@ static tSirRetStatus __lim_init_config(tpAniSirGlobal pMac) pAmpduParamInfo->mpduDensity = (uint8_t)val3; if (cfg_set_int (pMac, WNI_CFG_HT_AMPDU_PARAMS, - *(uint8_t *) pAmpduParamInfo) != eSIR_SUCCESS) { + *(uint8_t *) pAmpduParamInfo) != QDF_STATUS_SUCCESS) { pe_err("cfg get short preamble failed"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } /* WNI_CFG_SHORT_PREAMBLE - this one is not updated in lim_handle_cf_gparam_update do we want to update this? */ - if (wlan_cfg_get_int(pMac, WNI_CFG_SHORT_PREAMBLE, &val1) != eSIR_SUCCESS) { + if (wlan_cfg_get_int(pMac, WNI_CFG_SHORT_PREAMBLE, &val1) != QDF_STATUS_SUCCESS) { pe_err("cfg get short preamble failed"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } /* WNI_CFG_PROBE_RSP_BCN_ADDNIE_DATA - not needed */ @@ -377,58 +377,58 @@ static tSirRetStatus __lim_init_config(tpAniSirGlobal pMac) /* This was initially done after resume notification from HAL. Now, DAL is started before PE so this can be done here */ handle_ht_capabilityand_ht_info(pMac, NULL); - if (eSIR_SUCCESS != + if (QDF_STATUS_SUCCESS != wlan_cfg_get_int(pMac, WNI_CFG_DISABLE_LDPC_WITH_TXBF_AP, (uint32_t *) &pMac->lim.disableLDPCWithTxbfAP)) { pe_err("cfg get disableLDPCWithTxbfAP failed"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } #ifdef FEATURE_WLAN_TDLS - if (eSIR_SUCCESS != wlan_cfg_get_int(pMac, WNI_CFG_TDLS_BUF_STA_ENABLED, + if (QDF_STATUS_SUCCESS != wlan_cfg_get_int(pMac, WNI_CFG_TDLS_BUF_STA_ENABLED, (uint32_t *) &pMac->lim. gLimTDLSBufStaEnabled)) { pe_err("cfg get LimTDLSBufStaEnabled failed"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } - if (eSIR_SUCCESS != + if (QDF_STATUS_SUCCESS != wlan_cfg_get_int(pMac, WNI_CFG_TDLS_QOS_WMM_UAPSD_MASK, (uint32_t *) &pMac->lim.gLimTDLSUapsdMask)) { pe_err("cfg get LimTDLSUapsdMask failed"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } - if (eSIR_SUCCESS != + if (QDF_STATUS_SUCCESS != wlan_cfg_get_int(pMac, WNI_CFG_TDLS_OFF_CHANNEL_ENABLED, (uint32_t *) &pMac->lim. gLimTDLSOffChannelEnabled)) { pe_err("cfg get LimTDLSUapsdMask failed"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } - if (eSIR_SUCCESS != wlan_cfg_get_int(pMac, WNI_CFG_TDLS_WMM_MODE_ENABLED, + if (QDF_STATUS_SUCCESS != wlan_cfg_get_int(pMac, WNI_CFG_TDLS_WMM_MODE_ENABLED, (uint32_t *) &pMac->lim. gLimTDLSWmmMode)) { pe_err("cfg get LimTDLSWmmMode failed"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } #endif - if (eSIR_SUCCESS != wlan_cfg_get_int(pMac, + if (QDF_STATUS_SUCCESS != wlan_cfg_get_int(pMac, WNI_CFG_OBSS_DETECTION_OFFLOAD, (uint32_t *)&pMac->lim. global_obss_offload_enabled)) { pe_err("cfg get obss_detection_offloaded failed"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } - if (eSIR_SUCCESS != + if (QDF_STATUS_SUCCESS != wlan_cfg_get_int(pMac, WNI_CFG_OBSS_COLOR_COLLISION_OFFLOAD, (uint32_t *) &pMac->lim. global_obss_color_collision_det_offload)) { pe_err("cfg get obss_color_collision_offload failed"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /* @@ -436,9 +436,9 @@ static tSirRetStatus __lim_init_config(tpAniSirGlobal pMac) This function is to replace the __lim_process_sme_start_req since there is no eWNI_SME_START_REQ post to PE. */ -tSirRetStatus lim_start(tpAniSirGlobal pMac) +QDF_STATUS lim_start(tpAniSirGlobal pMac) { - tSirRetStatus retCode = eSIR_SUCCESS; + QDF_STATUS retCode = QDF_STATUS_SUCCESS; pe_debug("enter"); @@ -450,9 +450,9 @@ tSirRetStatus lim_start(tpAniSirGlobal pMac) pMac->lim.gLimSmeState)); /* Initialize MLM state machine */ - if (eSIR_SUCCESS != lim_init_mlm(pMac)) { + if (QDF_STATUS_SUCCESS != lim_init_mlm(pMac)) { pe_err("Init MLM failed"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } } else { /** @@ -462,7 +462,7 @@ tSirRetStatus lim_start(tpAniSirGlobal pMac) */ pe_warn("Invalid SME state: %X", pMac->lim.gLimSmeState); - retCode = eSIR_FAILURE; + retCode = QDF_STATUS_E_FAILURE; } pMac->lim.req_id = @@ -493,9 +493,9 @@ tSirRetStatus lim_start(tpAniSirGlobal pMac) * @return None */ -tSirRetStatus lim_initialize(tpAniSirGlobal pMac) +QDF_STATUS lim_initialize(tpAniSirGlobal pMac) { - tSirRetStatus status = eSIR_SUCCESS; + QDF_STATUS status = QDF_STATUS_SUCCESS; pMac->lim.mgmtFrameSessionId = NO_SESSION; pMac->lim.tdls_frm_session_id = NO_SESSION; @@ -508,7 +508,7 @@ tSirRetStatus lim_initialize(tpAniSirGlobal pMac) if (QDF_IS_STATUS_ERROR(qdf_mutex_create( &pMac->lim.lkPeGlobalLock))) { pe_err("lim lock init failed!"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } __lim_init_assoc_vars(pMac); @@ -528,7 +528,7 @@ tSirRetStatus lim_initialize(tpAniSirGlobal pMac) &pMac->lim.lim_frame_register_lock))) { pe_err("lim lock init failed!"); qdf_mutex_destroy(&pMac->lim.lkPeGlobalLock); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } qdf_list_create(&pMac->lim.gLimMgmtFrameRegistratinQueue, 0); @@ -856,15 +856,15 @@ static QDF_STATUS lim_unregister_sap_bcn_callback(tpAniSirGlobal mac_ctx) \brief will be called in Open sequence from mac_open \param tpAniSirGlobal pMac \param tHalOpenParameters *pHalOpenParam - \return tSirRetStatus + \return QDF_STATUS -------------------------------------------------------------*/ -tSirRetStatus pe_open(tpAniSirGlobal pMac, struct cds_config_info *cds_cfg) +QDF_STATUS pe_open(tpAniSirGlobal pMac, struct cds_config_info *cds_cfg) { - tSirRetStatus status = eSIR_SUCCESS; + QDF_STATUS status = QDF_STATUS_SUCCESS; if (QDF_DRIVER_TYPE_MFG == cds_cfg->driver_type) - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; pMac->lim.maxBssId = cds_cfg->max_bssid; pMac->lim.maxStation = cds_cfg->max_station; @@ -872,28 +872,28 @@ tSirRetStatus pe_open(tpAniSirGlobal pMac, struct cds_config_info *cds_cfg) if ((pMac->lim.maxBssId == 0) || (pMac->lim.maxStation == 0)) { pe_err("max number of Bssid or Stations cannot be zero!"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } pMac->lim.limTimers.gpLimCnfWaitTimer = qdf_mem_malloc(sizeof(TX_TIMER) * (pMac->lim.maxStation + 1)); if (NULL == pMac->lim.limTimers.gpLimCnfWaitTimer) { pe_err("gpLimCnfWaitTimer memory allocate failed!"); - return eSIR_MEM_ALLOC_FAILED; + return QDF_STATUS_E_NOMEM; } pMac->lim.gpSession = qdf_mem_malloc(sizeof(tPESession) * pMac->lim.maxBssId); if (NULL == pMac->lim.gpSession) { pe_err("gpSession memory allocate failed!"); - status = eSIR_MEM_ALLOC_FAILED; + status = QDF_STATUS_E_NOMEM; goto pe_open_psession_fail; } status = lim_initialize(pMac); - if (eSIR_SUCCESS != status) { + if (QDF_STATUS_SUCCESS != status) { pe_err("lim_initialize failed!"); - status = eSIR_FAILURE; + status = QDF_STATUS_E_FAILURE; goto pe_open_lock_fail; } @@ -915,7 +915,7 @@ tSirRetStatus pe_open(tpAniSirGlobal pMac, struct cds_config_info *cds_cfg) pe_err("%s: Shutdown notifier register failed", __func__); } - return status; /* status here will be eSIR_SUCCESS */ + return status; /* status here will be QDF_STATUS_SUCCESS */ pe_open_lock_fail: qdf_mem_free(pMac->lim.gpSession); @@ -931,15 +931,15 @@ pe_open_psession_fail: \fn pe_close \brief will be called in close sequence from mac_close \param tpAniSirGlobal pMac - \return tSirRetStatus + \return QDF_STATUS -------------------------------------------------------------*/ -tSirRetStatus pe_close(tpAniSirGlobal pMac) +QDF_STATUS pe_close(tpAniSirGlobal pMac) { uint8_t i; if (ANI_DRIVER_TYPE(pMac) == QDF_DRIVER_TYPE_MFG) - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; lim_cleanup(pMac); lim_unregister_sap_bcn_callback(pMac); @@ -961,9 +961,9 @@ tSirRetStatus pe_close(tpAniSirGlobal pMac) pMac->lim.gpSession = NULL; if (!QDF_IS_STATUS_SUCCESS (qdf_mutex_destroy(&pMac->lim.lkPeGlobalLock))) { - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /** ------------------------------------------------------------- @@ -973,20 +973,20 @@ tSirRetStatus pe_close(tpAniSirGlobal pMac) \return none -------------------------------------------------------------*/ -tSirRetStatus pe_start(tpAniSirGlobal pMac) +QDF_STATUS pe_start(tpAniSirGlobal pMac) { - tSirRetStatus status = eSIR_SUCCESS; + QDF_STATUS status = QDF_STATUS_SUCCESS; status = lim_start(pMac); - if (eSIR_SUCCESS != status) { + if (QDF_STATUS_SUCCESS != status) { pe_err("lim_start failed!"); return status; } /* Initialize the configurations needed by PE */ - if (eSIR_FAILURE == __lim_init_config(pMac)) { + if (QDF_STATUS_E_FAILURE == __lim_init_config(pMac)) { pe_err("lim init config failed!"); /* We need to undo everything in lim_start */ lim_cleanup_mlm(pMac); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } /* Initialize the configurations needed by PE */ lim_register_hal_ind_call_back(pMac); @@ -1105,9 +1105,9 @@ uint32_t lim_post_msg_high_priority(tpAniSirGlobal mac, --------------------------------------------------------------------------*/ -tSirRetStatus pe_post_msg_api(tpAniSirGlobal pMac, struct scheduler_msg *pMsg) +QDF_STATUS pe_post_msg_api(tpAniSirGlobal pMac, struct scheduler_msg *pMsg) { - return (tSirRetStatus) lim_post_msg_api(pMac, pMsg); + return (QDF_STATUS) lim_post_msg_api(pMac, pMsg); } /*-------------------------------------------------------------------------- @@ -1123,11 +1123,11 @@ tSirRetStatus pe_post_msg_api(tpAniSirGlobal pMac, struct scheduler_msg *pMsg) --------------------------------------------------------------------------*/ -tSirRetStatus pe_process_messages(tpAniSirGlobal pMac, +QDF_STATUS pe_process_messages(tpAniSirGlobal pMac, struct scheduler_msg *pMsg) { if (ANI_DRIVER_TYPE(pMac) == QDF_DRIVER_TYPE_MFG) { - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /** * If the Message to be handled is for CFG Module call the CFG Msg @@ -1137,19 +1137,19 @@ tSirRetStatus pe_process_messages(tpAniSirGlobal pMac, cfg_process_mb_msg(pMac, (tSirMbMsg *) pMsg->bodyptr); else lim_message_processor(pMac, pMsg); - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } QDF_STATUS pe_mc_process_handler(struct scheduler_msg *msg) { - tSirRetStatus status; + QDF_STATUS status; tpAniSirGlobal mac_ctx = cds_get_context(QDF_MODULE_ID_PE); if (mac_ctx == NULL) return QDF_STATUS_E_FAILURE; status = pe_process_messages(mac_ctx, msg); - if (status == eSIR_SUCCESS) + if (status == QDF_STATUS_SUCCESS) return QDF_STATUS_SUCCESS; return QDF_STATUS_E_FAILURE; @@ -1436,7 +1436,7 @@ static QDF_STATUS pe_handle_mgmt_frame(struct wlan_objmgr_psoc *psoc, msg.bodyptr = pVosPkt; msg.bodyval = 0; - if (eSIR_SUCCESS != sys_bbt_process_message_core(pMac, + if (QDF_STATUS_SUCCESS != sys_bbt_process_message_core(pMac, &msg, mHdr->fc.type, mHdr->fc.subType)) { @@ -1679,13 +1679,13 @@ static bool lim_ibss_enc_type_matched(tpSchBeaconStruct pBeacon, * @return Status whether to process or ignore received Beacon Frame */ -tSirRetStatus +QDF_STATUS lim_handle_ibss_coalescing(tpAniSirGlobal pMac, tpSchBeaconStruct pBeacon, uint8_t *pRxPacketInfo, tpPESession psessionEntry) { tpSirMacMgmtHdr pHdr; - tSirRetStatus retCode; + QDF_STATUS retCode; pHdr = WMA_GET_RX_MAC_HEADER(pRxPacketInfo); @@ -1698,13 +1698,13 @@ lim_handle_ibss_coalescing(tpAniSirGlobal pMac, if ((!pBeacon->capabilityInfo.ibss) || lim_cmp_ssid(&pBeacon->ssId, psessionEntry) || (psessionEntry->currentOperChannel != pBeacon->channelNumber)) - retCode = eSIR_LIM_IGNORE_BEACON; + retCode = QDF_STATUS_E_INVAL; else if (lim_ibss_enc_type_matched(pBeacon, psessionEntry) != true) { pe_debug("peer privacy: %d peer wpa: %d peer rsn: %d self encType: %d", pBeacon->capabilityInfo.privacy, pBeacon->wpaPresent, pBeacon->rsnPresent, psessionEntry->encryptType); - retCode = eSIR_LIM_IGNORE_BEACON; + retCode = QDF_STATUS_E_INVAL; } else { uint32_t ieLen; uint16_t tsfLater; @@ -1831,7 +1831,7 @@ lim_detect_change_in_ap_capabilities(tpAniSirGlobal pMac, uint8_t len; tSirSmeApNewCaps apNewCaps; uint8_t newChannel; - tSirRetStatus status = eSIR_SUCCESS; + QDF_STATUS status = QDF_STATUS_SUCCESS; bool security_caps_matched = true; apNewCaps.capabilityInfo = @@ -1873,7 +1873,7 @@ lim_detect_change_in_ap_capabilities(tpAniSirGlobal pMac, psessionEntry->dot11mode, NULL, NULL); - if (eSIR_SUCCESS != status) { + if (QDF_STATUS_SUCCESS != status) { pe_err("send ProbeReq failed"); psessionEntry->fWaitForProbeRsp = false; } @@ -1952,7 +1952,7 @@ lim_detect_change_in_ap_capabilities(tpAniSirGlobal pMac, * @return None */ -tSirRetStatus lim_update_short_slot(tpAniSirGlobal pMac, +QDF_STATUS lim_update_short_slot(tpAniSirGlobal pMac, tpSirProbeRespBeacon pBeacon, tpUpdateBeaconParams pBeaconParams, tpPESession psessionEntry) @@ -1965,18 +1965,18 @@ tSirRetStatus lim_update_short_slot(tpAniSirGlobal pMac, /* Check Admin mode first. If it is disabled just return */ if (wlan_cfg_get_int(pMac, WNI_CFG_11G_SHORT_SLOT_TIME_ENABLED, &val) - != eSIR_SUCCESS) { + != QDF_STATUS_SUCCESS) { pe_err("cfg get WNI_CFG_11G_SHORT_SLOT_TIME failed"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } if (val == false) - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; /* Check for 11a mode or 11b mode. In both cases return since slot time is constant and cannot/should not change in beacon */ lim_get_phy_mode(pMac, &phyMode, psessionEntry); if ((phyMode == WNI_CFG_PHY_MODE_11A) || (phyMode == WNI_CFG_PHY_MODE_11B)) - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; apNewCaps.capabilityInfo = lim_get_u16((uint8_t *) &pBeacon->capabilityInfo); @@ -2013,7 +2013,7 @@ tSirRetStatus lim_update_short_slot(tpAniSirGlobal pMac, pBeaconParams->paramChangeBitmap |= PARAM_SHORT_SLOT_TIME_CHANGED; } - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } @@ -2030,7 +2030,7 @@ void lim_send_heart_beat_timeout_ind(tpAniSirGlobal pMac, tpPESession psessionEn statusCode = lim_post_msg_api(pMac, &msg); - if (statusCode != eSIR_SUCCESS) { + if (statusCode != QDF_STATUS_SUCCESS) { pe_err("posting message: %X to LIM failed, reason: %d", msg.type, statusCode); } @@ -2169,7 +2169,7 @@ lim_roam_fill_bss_descr(tpAniSirGlobal pMac, &bcn_proberesp_ptr[SIR_MAC_HDR_LEN_3A + SIR_MAC_B_PR_SSID_OFFSET], roam_offload_synch_ind_ptr->beaconProbeRespLength - - SIR_MAC_HDR_LEN_3A) != eSIR_SUCCESS || + SIR_MAC_HDR_LEN_3A) != QDF_STATUS_SUCCESS || !parsed_frm_ptr->ssidPresent) { pe_err("Parse error Beacon, length: %d", roam_offload_synch_ind_ptr->beaconProbeRespLength); @@ -2180,7 +2180,7 @@ lim_roam_fill_bss_descr(tpAniSirGlobal pMac, if (sir_convert_probe_frame2_struct(pMac, &bcn_proberesp_ptr[SIR_MAC_HDR_LEN_3A], roam_offload_synch_ind_ptr->beaconProbeRespLength - - SIR_MAC_HDR_LEN_3A, parsed_frm_ptr) != eSIR_SUCCESS || + SIR_MAC_HDR_LEN_3A, parsed_frm_ptr) != QDF_STATUS_SUCCESS || !parsed_frm_ptr->ssidPresent) { pe_err("Parse error ProbeResponse, length: %d", roam_offload_synch_ind_ptr->beaconProbeRespLength); @@ -2779,11 +2779,11 @@ QDF_STATUS lim_update_ext_cap_ie(tpAniSirGlobal mac_ctx, uint32_t dot11mode; bool vht_enabled = false; tDot11fIEExtCap default_scan_ext_cap = {0}, driver_ext_cap = {0}; - tSirRetStatus status; + QDF_STATUS status; status = lim_strip_extcap_update_struct(mac_ctx, ie_data, local_ie_len, &default_scan_ext_cap); - if (eSIR_SUCCESS != status) { + if (QDF_STATUS_SUCCESS != status) { pe_err("Strip ext cap fails %d", status); return QDF_STATUS_E_FAILURE; } @@ -2804,7 +2804,7 @@ QDF_STATUS lim_update_ext_cap_ie(tpAniSirGlobal mac_ctx, status = populate_dot11f_ext_cap(mac_ctx, vht_enabled, &driver_ext_cap, NULL); - if (eSIR_SUCCESS != status) { + if (QDF_STATUS_SUCCESS != status) { pe_err("Failed %d to create ext cap IE. Use default value instead", status); local_ie_buf[*local_ie_len + 1] = DOT11F_IE_EXTCAP_MAX_LEN; diff --git a/core/mac/src/pe/lim/lim_assoc_utils.c b/core/mac/src/pe/lim/lim_assoc_utils.c index e0cd9435c8..d9003b3b3b 100644 --- a/core/mac/src/pe/lim/lim_assoc_utils.c +++ b/core/mac/src/pe/lim/lim_assoc_utils.c @@ -146,7 +146,7 @@ lim_compare_capabilities(tpAniSirGlobal pMac, (pLocalCapabs->shortSlotTime == 1)) { if (wlan_cfg_get_int (pMac, WNI_CFG_ACCEPT_SHORT_SLOT_ASSOC_ONLY, - &val) != eSIR_SUCCESS) { + &val) != QDF_STATUS_SUCCESS) { pe_err("error getting WNI_CFG_FORCE_SHORT_SLOT_ASSOC_ONLY"); return false; } @@ -274,7 +274,7 @@ uint8_t lim_check_mcs_set(tpAniSirGlobal pMac, uint8_t *supportedMCSSet) cfgLen = WNI_CFG_BASIC_MCS_SET_LEN; if (wlan_cfg_get_str(pMac, WNI_CFG_BASIC_MCS_SET, (uint8_t *) basicMCSSet, - (uint32_t *) &cfgLen) != eSIR_SUCCESS) { + (uint32_t *) &cfgLen) != QDF_STATUS_SUCCESS) { /* / Could not get Basic MCS rateset from CFG. Log error. */ pe_err("could not retrieve Basic MCS rateset"); return false; @@ -341,7 +341,7 @@ static inline bool is_non_rsn_cipher(uint8_t cipher_suite) * frame handling to determine whether received RSN in * Assoc/Reassoc request frames include supported cipher suites or not. * - * Return: eSIR_SUCCESS if ALL BSS basic rates are present in the + * Return: QDF_STATUS_SUCCESS if ALL BSS basic rates are present in the * received rateset else failure status. */ @@ -364,7 +364,7 @@ uint8_t lim_check_rx_rsn_ie_match(tpAniSirGlobal mac_ctx, if (!rx_rsn_ie) { pe_debug("Rx RSN IE is NULL"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } /* Check groupwise cipher suite */ @@ -443,7 +443,7 @@ uint8_t lim_check_rx_rsn_ie_match(tpAniSirGlobal mac_ctx, they_require_pmf, *pmf_connection); #endif - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /** @@ -517,7 +517,7 @@ lim_check_rx_wpa_ie_match(tpAniSirGlobal mac, tDot11fIEWPA rx_wpaie, return eSIR_MAC_CIPHER_SUITE_REJECTED_STATUS; } - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /** @@ -550,11 +550,11 @@ lim_check_rx_wpa_ie_match(tpAniSirGlobal mac, tDot11fIEWPA rx_wpaie, * @return None */ -tSirRetStatus +QDF_STATUS lim_cleanup_rx_path(tpAniSirGlobal pMac, tpDphHashNode pStaDs, tpPESession psessionEntry) { - tSirRetStatus retCode = eSIR_SUCCESS; + QDF_STATUS retCode = QDF_STATUS_SUCCESS; pe_debug("Cleanup Rx Path for AID: %d" "psessionEntry->limSmeState: %d, mlmState: %d", @@ -605,7 +605,7 @@ lim_cleanup_rx_path(tpAniSirGlobal pMac, tpDphHashNode pStaDs, lim_send_sme_tsm_ie_ind(pMac, psessionEntry, 0, 0, 0); /* Any roaming related changes should be above this line */ if (lim_is_roam_synch_in_progress(psessionEntry)) - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; pStaDs->mlmStaContext.mlmState = eLIM_MLM_WT_DEL_STA_RSP_STATE; if (LIM_IS_STA_ROLE(psessionEntry)) { @@ -1222,7 +1222,7 @@ static void lim_decide_short_preamble(tpAniSirGlobal mac_ctx, qdf_mem_set((uint8_t *) &session_entry->gLimNoShortParams, sizeof(tLimNoShortParams), 0); if (lim_enable_short_preamble(mac_ctx, true, - beacon_params, session_entry) != eSIR_SUCCESS) + beacon_params, session_entry) != QDF_STATUS_SUCCESS) pe_err("Cannot enable short preamble"); } } @@ -1336,9 +1336,9 @@ lim_decide_short_slot(tpAniSirGlobal mac_ctx, tpDphHashNode sta_ds, * * Populates vht mcs rate set based on peer and self capabilities * - * Return: eSIR_SUCCESS on success else eSIR_FAILURE + * Return: QDF_STATUS_SUCCESS on success else QDF_STATUS_E_FAILURE */ -tSirRetStatus lim_populate_vht_mcs_set(tpAniSirGlobal mac_ctx, +QDF_STATUS lim_populate_vht_mcs_set(tpAniSirGlobal mac_ctx, tpSirSupportedRates rates, tDot11fIEVHTCaps *peer_vht_caps, tpPESession session_entry, @@ -1352,17 +1352,17 @@ tSirRetStatus lim_populate_vht_mcs_set(tpAniSirGlobal mac_ctx, wlan_cfg_get_int(mac_ctx, WNI_CFG_DOT11_MODE, &self_sta_dot11mode); if (!IS_DOT11_MODE_VHT(self_sta_dot11mode)) - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; if (wlan_cfg_get_int(mac_ctx, WNI_CFG_VHT_RX_MCS_MAP, &val) != - eSIR_SUCCESS) { + QDF_STATUS_SUCCESS) { pe_err("could not retrieve VHT RX MCS MAP"); goto error; } rates->vhtRxMCSMap = (uint16_t) val; if (wlan_cfg_get_int(mac_ctx, WNI_CFG_VHT_TX_MCS_MAP, &val) != - eSIR_SUCCESS) { + QDF_STATUS_SUCCESS) { pe_err("could not retrieve VHT TX MCS MAP"); goto error; } @@ -1370,7 +1370,7 @@ tSirRetStatus lim_populate_vht_mcs_set(tpAniSirGlobal mac_ctx, if (wlan_cfg_get_int(mac_ctx, WNI_CFG_VHT_RX_HIGHEST_SUPPORTED_DATA_RATE, - &val) != eSIR_SUCCESS) { + &val) != QDF_STATUS_SUCCESS) { pe_err("couldn't retrieve VHT RX Supported data rate MAP"); goto error; } @@ -1378,7 +1378,7 @@ tSirRetStatus lim_populate_vht_mcs_set(tpAniSirGlobal mac_ctx, if (wlan_cfg_get_int(mac_ctx, WNI_CFG_VHT_TX_HIGHEST_SUPPORTED_DATA_RATE, - &val) != eSIR_SUCCESS) { + &val) != QDF_STATUS_SUCCESS) { pe_err("couldn't retrieve VHT RX Supported data rate MAP"); goto error; } @@ -1413,7 +1413,7 @@ tSirRetStatus lim_populate_vht_mcs_set(tpAniSirGlobal mac_ctx, } if ((peer_vht_caps == NULL) || (!peer_vht_caps->present)) - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; rates->vhtTxHighestDataRate = QDF_MIN(rates->vhtTxHighestDataRate, @@ -1479,10 +1479,10 @@ tSirRetStatus lim_populate_vht_mcs_set(tpAniSirGlobal mac_ctx, session_entry->supported_nss_1x1); } - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; error: - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } /** @@ -1505,9 +1505,9 @@ error: * ERP bit is set iff the dph PHY mode is 11G and there is at least * an A rate in the supported or extended rate sets * - * Return: eSIR_SUCCESS or eSIR_FAILURE. + * Return: QDF_STATUS_SUCCESS or QDF_STATUS_E_FAILURE. */ -tSirRetStatus +QDF_STATUS lim_populate_own_rate_set(tpAniSirGlobal mac_ctx, tpSirSupportedRates rates, uint8_t *supported_mcs_set, uint8_t basic_only, tpPESession session_entry, @@ -1557,7 +1557,7 @@ lim_populate_own_rate_set(tpAniSirGlobal mac_ctx, if ((temp_rate_set.numRates + temp_rate_set2.numRates) > 12) { pe_err("more than 12 rates in CFG"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } /* copy all rates in temp_rate_set, there are 12 rates max */ for (i = 0; i < temp_rate_set2.numRates; i++) @@ -1602,9 +1602,9 @@ lim_populate_own_rate_set(tpAniSirGlobal mac_ctx, val = SIZE_OF_SUPPORTED_MCS_SET; if (wlan_cfg_get_str(mac_ctx, WNI_CFG_SUPPORTED_MCS_SET, rates->supportedMCSSet, - &val) != eSIR_SUCCESS) { + &val) != QDF_STATUS_SUCCESS) { pe_err("could not retrieve supportedMCSSet"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } if (session_entry->nss == NSS_1x1_MODE) @@ -1630,7 +1630,7 @@ lim_populate_own_rate_set(tpAniSirGlobal mac_ctx, lim_populate_he_mcs_set(mac_ctx, rates, he_caps, session_entry, session_entry->nss); - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } #ifdef WLAN_FEATURE_11AX @@ -1653,7 +1653,7 @@ static void lim_calculate_he_nss(tpSirSupportedRates rates, tpPESession session) } #endif -tSirRetStatus +QDF_STATUS lim_populate_peer_rate_set(tpAniSirGlobal pMac, tpSirSupportedRates pRates, uint8_t *pSupportedMCSSet, uint8_t basicOnly, tpPESession psessionEntry, @@ -1671,7 +1671,7 @@ lim_populate_peer_rate_set(tpAniSirGlobal pMac, tempRateSet.numRates = psessionEntry->rateSet.numRates; } else { pe_err("more than SIR_MAC_RATESET_EID_MAX rates"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } if ((psessionEntry->dot11mode == WNI_CFG_DOT11_MODE_11G) || (psessionEntry->dot11mode == WNI_CFG_DOT11_MODE_11A) || @@ -1687,14 +1687,14 @@ lim_populate_peer_rate_set(tpAniSirGlobal pMac, psessionEntry->extRateSet.numRates; } else { pe_err("psessionEntry->extRateSet.numRates more than SIR_MAC_RATESET_EID_MAX rates"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } } else tempRateSet2.numRates = 0; if ((tempRateSet.numRates + tempRateSet2.numRates) > SIR_MAC_RATESET_EID_MAX) { pe_err("more than 12 rates in CFG"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } /* copy all rates in tempRateSet, there are 12 rates max */ @@ -1757,9 +1757,9 @@ lim_populate_peer_rate_set(tpAniSirGlobal pMac, val = SIZE_OF_SUPPORTED_MCS_SET; if (wlan_cfg_get_str(pMac, WNI_CFG_SUPPORTED_MCS_SET, pRates->supportedMCSSet, - &val) != eSIR_SUCCESS) { + &val) != QDF_STATUS_SUCCESS) { pe_err("could not retrieve supportedMCSSet"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } if (psessionEntry->nss == NSS_1x1_MODE) pRates->supportedMCSSet[1] = 0; @@ -1802,7 +1802,7 @@ lim_populate_peer_rate_set(tpAniSirGlobal pMac, } pe_debug("nss: %d", psessionEntry->nss); - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /*** lim_populate_peer_rate_set() ***/ /** @@ -1833,9 +1833,9 @@ lim_populate_peer_rate_set(tpAniSirGlobal pMac, * The parser has already ensured unicity of the rates in the * association request structure * - * Return: eSIR_SUCCESS on success else eSIR_FAILURE + * Return: QDF_STATUS_SUCCESS on success else QDF_STATUS_E_FAILURE */ -tSirRetStatus lim_populate_matching_rate_set(tpAniSirGlobal mac_ctx, +QDF_STATUS lim_populate_matching_rate_set(tpAniSirGlobal mac_ctx, tpDphHashNode sta_ds, tSirMacRateSet *oper_rate_set, tSirMacRateSet *ext_rate_set, @@ -1880,7 +1880,7 @@ tSirRetStatus lim_populate_matching_rate_set(tpAniSirGlobal mac_ctx, if (((uint16_t)temp_rate_set.numRates + (uint16_t)temp_rate_set2.numRates) > 12) { pe_err("more than 12 rates in CFG"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } /* @@ -2004,9 +2004,9 @@ tSirRetStatus lim_populate_matching_rate_set(tpAniSirGlobal mac_ctx, { val = SIZE_OF_SUPPORTED_MCS_SET; if (wlan_cfg_get_str(mac_ctx, WNI_CFG_SUPPORTED_MCS_SET, - mcs_set, &val) != eSIR_SUCCESS) { + mcs_set, &val) != QDF_STATUS_SUCCESS) { pe_err("could not retrieve supportedMCSet"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } if (session_entry->nss == NSS_1x1_MODE) @@ -2034,7 +2034,7 @@ tSirRetStatus lim_populate_matching_rate_set(tpAniSirGlobal mac_ctx, if ((phy_mode == WNI_CFG_PHY_MODE_11G) && is_arate) sta_ds->erpEnabled = eHAL_SET; - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /** @@ -2125,16 +2125,16 @@ static void lim_update_he_stbc_capable(tpAddStaParams add_sta_params) * This function is called to add an STA context at hardware * whenever a STA is (Re) Associated. * - * Return: eSIR_SUCCESS on success else eSirRetStatus failure codes + * Return: QDF_STATUS_SUCCESS on success else eSirRetStatus failure codes */ -tSirRetStatus +QDF_STATUS lim_add_sta(tpAniSirGlobal mac_ctx, tpDphHashNode sta_ds, uint8_t update_entry, tpPESession session_entry) { tpAddStaParams add_sta_params = NULL; struct scheduler_msg msg_q = {0}; - tSirRetStatus ret_code = eSIR_SUCCESS; + QDF_STATUS ret_code = QDF_STATUS_SUCCESS; tSirMacAddr sta_mac, *sta_Addr; tpSirAssocReq assoc_req; uint8_t i, nw_type_11b = 0; @@ -2150,7 +2150,7 @@ lim_add_sta(tpAniSirGlobal mac_ctx, add_sta_params = qdf_mem_malloc(sizeof(tAddStaParams)); if (NULL == add_sta_params) { pe_err("Unable to allocate memory during ADD_STA"); - return eSIR_MEM_ALLOC_FAILED; + return QDF_STATUS_E_NOMEM; } if (LIM_IS_AP_ROLE(session_entry) || LIM_IS_IBSS_ROLE(session_entry) || @@ -2400,7 +2400,7 @@ lim_add_sta(tpAniSirGlobal mac_ctx, peer_node = lim_ibss_peer_find(mac_ctx, *sta_Addr); if (!peer_node) { pe_err("Can't find IBSS peer node for ADD_STA"); - return eSIR_HAL_STA_DOES_NOT_EXIST; + return QDF_STATUS_E_NOENT; } if (peer_node->atimIePresent) { @@ -2546,7 +2546,7 @@ lim_add_sta(tpAniSirGlobal mac_ctx, msg_q.type)); ret_code = wma_post_ctrl_msg(mac_ctx, &msg_q); - if (eSIR_SUCCESS != ret_code) { + if (QDF_STATUS_SUCCESS != ret_code) { if (add_sta_params->respReqd) SET_LIM_PROCESS_DEFD_MESGS(mac_ctx, true); pe_err("ADD_STA_REQ for aId %d failed (reason %X)", @@ -2580,18 +2580,18 @@ lim_add_sta(tpAniSirGlobal mac_ctx, * @return retCode - Indicates success or failure return code */ -tSirRetStatus +QDF_STATUS lim_del_sta(tpAniSirGlobal pMac, tpDphHashNode pStaDs, bool fRespReqd, tpPESession psessionEntry) { tpDeleteStaParams pDelStaParams = NULL; struct scheduler_msg msgQ = {0}; - tSirRetStatus retCode = eSIR_SUCCESS; + QDF_STATUS retCode = QDF_STATUS_SUCCESS; pDelStaParams = qdf_mem_malloc(sizeof(tDeleteStaParams)); if (NULL == pDelStaParams) { pe_err("Unable to allocate memory during ADD_STA"); - return eSIR_MEM_ALLOC_FAILED; + return QDF_STATUS_E_NOMEM; } /* @@ -2694,7 +2694,7 @@ lim_del_sta(tpAniSirGlobal pMac, MTRACE(mac_trace_msg_tx(pMac, psessionEntry->peSessionId, msgQ.type)); retCode = wma_post_ctrl_msg(pMac, &msgQ); - if (eSIR_SUCCESS != retCode) { + if (QDF_STATUS_SUCCESS != retCode) { if (fRespReqd) SET_LIM_PROCESS_DEFD_MESGS(pMac, true); pe_err("Posting DELETE_STA_REQ to HAL failed, reason=%X", @@ -2727,13 +2727,13 @@ lim_del_sta(tpAniSirGlobal pMac, * @return retCode - Indicates success or failure return code */ -tSirRetStatus +QDF_STATUS lim_add_sta_self(tpAniSirGlobal pMac, uint16_t staIdx, uint8_t updateSta, tpPESession psessionEntry) { tpAddStaParams pAddStaParams = NULL; struct scheduler_msg msgQ = {0}; - tSirRetStatus retCode = eSIR_SUCCESS; + QDF_STATUS retCode = QDF_STATUS_SUCCESS; tSirMacAddr staMac; uint32_t listenInterval = WNI_CFG_LISTEN_INTERVAL_STADEF; uint32_t ampduLenExponent = 0; @@ -2760,7 +2760,7 @@ lim_add_sta_self(tpAniSirGlobal pMac, uint16_t staIdx, uint8_t updateSta, pAddStaParams = qdf_mem_malloc(sizeof(tAddStaParams)); if (NULL == pAddStaParams) { pe_err("Unable to allocate memory during ADD_STA"); - return eSIR_MEM_ALLOC_FAILED; + return QDF_STATUS_E_NOMEM; } /* / Add STA context at MAC HW (BMU, RHP & TFP) */ @@ -2788,7 +2788,7 @@ lim_add_sta_self(tpAniSirGlobal pMac, uint16_t staIdx, uint8_t updateSta, pAddStaParams->updateSta = updateSta; if (wlan_cfg_get_int(pMac, WNI_CFG_SHORT_PREAMBLE, &val) != - eSIR_SUCCESS) { + QDF_STATUS_SUCCESS) { pe_err("Couldn't get SHORT_PREAMBLE, set default"); pAddStaParams->shortPreambleSupported = 1; } else { @@ -2879,7 +2879,7 @@ lim_add_sta_self(tpAniSirGlobal pMac, uint16_t staIdx, uint8_t updateSta, if (IS_DOT11_MODE_VHT(selfStaDot11Mode)) { if (wlan_cfg_get_int (pMac, WNI_CFG_VHT_AMPDU_LEN_EXPONENT, &duLenExponent) - != eSIR_SUCCESS) { + != QDF_STATUS_SUCCESS) { pe_err("Couldn't get WNI_CFG_VHT_AMPDU_LEN_EXPONENT"); } pAddStaParams->maxAmpduSize = (uint8_t) ampduLenExponent; @@ -2901,7 +2901,7 @@ lim_add_sta_self(tpAniSirGlobal pMac, uint16_t staIdx, uint8_t updateSta, ((psessionEntry->txLdpcIniFeatureEnabled >> 1) & 0x01); if (wlan_cfg_get_int(pMac, WNI_CFG_LISTEN_INTERVAL, &listenInterval) != - eSIR_SUCCESS) + QDF_STATUS_SUCCESS) pe_err("Couldn't get LISTEN_INTERVAL"); pAddStaParams->listenInterval = (uint16_t) listenInterval; @@ -2944,7 +2944,7 @@ lim_add_sta_self(tpAniSirGlobal pMac, uint16_t staIdx, uint8_t updateSta, MTRACE(mac_trace_msg_tx(pMac, psessionEntry->peSessionId, msgQ.type)); retCode = wma_post_ctrl_msg(pMac, &msgQ); - if (eSIR_SUCCESS != retCode) { + if (QDF_STATUS_SUCCESS != retCode) { pe_err("Posting WMA_ADD_STA_REQ to HAL failed, reason=%X", retCode); qdf_mem_free(pAddStaParams); @@ -3137,7 +3137,7 @@ lim_delete_dph_hash_entry(tpAniSirGlobal mac_ctx, tSirMacAddr sta_addr, } if (dph_delete_hash_entry(mac_ctx, sta_addr, sta_id, - &session_entry->dph.dphHashTable) != eSIR_SUCCESS) + &session_entry->dph.dphHashTable) != QDF_STATUS_SUCCESS) pe_err("error deleting hash entry"); } @@ -3240,7 +3240,7 @@ lim_check_and_announce_join_success(tpAniSirGlobal mac_ctx, if (wlan_cfg_get_int(mac_ctx, WNI_CFG_AUTHENTICATE_FAILURE_TIMEOUT, &val) == - eSIR_SUCCESS) { + QDF_STATUS_SUCCESS) { session_entry->defaultAuthFailureTimeout = val; cfg_set_int(mac_ctx, WNI_CFG_AUTHENTICATE_FAILURE_TIMEOUT, @@ -3350,9 +3350,9 @@ lim_check_and_announce_join_success(tpAniSirGlobal mac_ctx, * @param ieLen Length of all IEs combined * @param beaconStruct A pointer to tSirProbeRespBeacon that needs to be * populated - * @return status A status reporting eSIR_SUCCESS or eSIR_FAILURE + * @return status A status reporting QDF_STATUS_SUCCESS or QDF_STATUS_E_FAILURE */ -tSirRetStatus lim_extract_ap_capabilities(tpAniSirGlobal pMac, +QDF_STATUS lim_extract_ap_capabilities(tpAniSirGlobal pMac, uint8_t *pIE, uint16_t ieLen, tpSirProbeRespBeacon beaconStruct) @@ -3364,15 +3364,15 @@ tSirRetStatus lim_extract_ap_capabilities(tpAniSirGlobal pMac, pIE, ieLen); /* Parse the Beacon IE's, Don't try to parse if we dont have anything in IE */ if (ieLen > 0) { - if (eSIR_SUCCESS != + if (QDF_STATUS_SUCCESS != sir_parse_beacon_ie(pMac, beaconStruct, pIE, (uint32_t) ieLen)) { pe_err("APCapExtract: Beacon parsing error!"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } } - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /** @@ -3396,18 +3396,18 @@ tSirRetStatus lim_extract_ap_capabilities(tpAniSirGlobal pMac, * @return retCode - Indicates success or failure return code */ -tSirRetStatus +QDF_STATUS lim_del_bss(tpAniSirGlobal pMac, tpDphHashNode pStaDs, uint16_t bssIdx, tpPESession psessionEntry) { tpDeleteBssParams pDelBssParams = NULL; struct scheduler_msg msgQ = {0}; - tSirRetStatus retCode = eSIR_SUCCESS; + QDF_STATUS retCode = QDF_STATUS_SUCCESS; pDelBssParams = qdf_mem_malloc(sizeof(tDeleteBssParams)); if (NULL == pDelBssParams) { pe_err("Unable to allocate memory during ADD_BSS"); - return eSIR_MEM_ALLOC_FAILED; + return QDF_STATUS_E_NOMEM; } pDelBssParams->sessionId = psessionEntry->peSessionId; /* update PE session Id */ @@ -3456,7 +3456,7 @@ lim_del_bss(tpAniSirGlobal pMac, tpDphHashNode pStaDs, uint16_t bssIdx, MTRACE(mac_trace_msg_tx(pMac, psessionEntry->peSessionId, msgQ.type)); retCode = wma_post_ctrl_msg(pMac, &msgQ); - if (eSIR_SUCCESS != retCode) { + if (QDF_STATUS_SUCCESS != retCode) { SET_LIM_PROCESS_DEFD_MESGS(pMac, true); pe_err("Posting DELETE_BSS_REQ to HAL failed, reason=%X", retCode); @@ -3601,7 +3601,7 @@ static inline void lim_set_sta_ctx_twt(tAddStaParams *sta_ctx, * @return None */ -tSirRetStatus lim_sta_send_add_bss(tpAniSirGlobal pMac, tpSirAssocRsp pAssocRsp, +QDF_STATUS lim_sta_send_add_bss(tpAniSirGlobal pMac, tpSirAssocRsp pAssocRsp, tpSchBeaconStruct pBeaconStruct, tpSirBssDescription bssDescription, uint8_t updateEntry, tpPESession psessionEntry) @@ -3622,7 +3622,7 @@ tSirRetStatus lim_sta_send_add_bss(tpAniSirGlobal pMac, tpSirAssocRsp pAssocRsp, pAddBssParams = qdf_mem_malloc(sizeof(tAddBssParams)); if (NULL == pAddBssParams) { pe_err("Unable to allocate memory during ADD_BSS"); - retCode = eSIR_MEM_ALLOC_FAILED; + retCode = QDF_STATUS_E_NOMEM; goto returnFailure; } @@ -3800,7 +3800,7 @@ tSirRetStatus lim_sta_send_add_bss(tpAniSirGlobal pMac, tpSirAssocRsp pAssocRsp, qdf_mem_copy(pAddBssParams->staContext.bssId, bssDescription->bssId, sizeof(tSirMacAddr)); if (wlan_cfg_get_int(pMac, WNI_CFG_LISTEN_INTERVAL, &listen_interval) != - eSIR_SUCCESS) + QDF_STATUS_SUCCESS) pe_err("Couldn't get LISTEN_INTERVAL"); pAddBssParams->staContext.listenInterval = listen_interval; @@ -3813,7 +3813,7 @@ tSirRetStatus lim_sta_send_add_bss(tpAniSirGlobal pMac, tpSirAssocRsp pAssocRsp, MAC_ADDRESS_STR, MAC_ADDR_ARRAY( pAddBssParams->staContext.staMac)); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } pAddBssParams->staContext.uAPSD = @@ -3914,7 +3914,7 @@ tSirRetStatus lim_sta_send_add_bss(tpAniSirGlobal pMac, tpSirAssocRsp pAssocRsp, sta_context->enable_su_tx_bformer); } else { sta_context->ch_width = CH_WIDTH_20MHZ; - if ((IS_SIR_STATUS_SUCCESS( + if ((QDF_IS_STATUS_SUCCESS( wlan_cfg_get_int(pMac, WNI_CFG_VHT_ENABLE_TXBF_20MHZ, &enableTxBF20MHz))) && @@ -4131,7 +4131,7 @@ tSirRetStatus lim_sta_send_add_bss(tpAniSirGlobal pMac, tpSirAssocRsp pAssocRsp, MTRACE(mac_trace_msg_tx(pMac, psessionEntry->peSessionId, msgQ.type)); retCode = wma_post_ctrl_msg(pMac, &msgQ); - if (eSIR_SUCCESS != retCode) { + if (QDF_STATUS_SUCCESS != retCode) { SET_LIM_PROCESS_DEFD_MESGS(pMac, true); qdf_mem_free(pAddBssParams); pe_err("Posting ADD_BSS_REQ to HAL failed, reason=%X", @@ -4146,7 +4146,7 @@ returnFailure: return retCode; } -tSirRetStatus lim_sta_send_add_bss_pre_assoc(tpAniSirGlobal pMac, uint8_t updateEntry, +QDF_STATUS lim_sta_send_add_bss_pre_assoc(tpAniSirGlobal pMac, uint8_t updateEntry, tpPESession psessionEntry) { struct scheduler_msg msgQ = {0}; @@ -4164,14 +4164,14 @@ tSirRetStatus lim_sta_send_add_bss_pre_assoc(tpAniSirGlobal pMac, uint8_t update pBeaconStruct = qdf_mem_malloc(sizeof(tSchBeaconStruct)); if (NULL == pBeaconStruct) { pe_err("Unable to allocate memory during ADD_BSS"); - return eSIR_MEM_ALLOC_FAILED; + return QDF_STATUS_E_NOMEM; } /* Package SIR_HAL_ADD_BSS_REQ message parameters */ pAddBssParams = qdf_mem_malloc(sizeof(tAddBssParams)); if (NULL == pAddBssParams) { pe_err("Unable to allocate memory during ADD_BSS"); - retCode = eSIR_MEM_ALLOC_FAILED; + retCode = QDF_STATUS_E_NOMEM; goto returnFailure; } @@ -4366,7 +4366,7 @@ tSirRetStatus lim_sta_send_add_bss_pre_assoc(tpAniSirGlobal pMac, uint8_t update qdf_mem_copy(pAddBssParams->staContext.bssId, bssDescription->bssId, sizeof(tSirMacAddr)); if (wlan_cfg_get_int(pMac, WNI_CFG_LISTEN_INTERVAL, &listen_interval) != - eSIR_SUCCESS) + QDF_STATUS_SUCCESS) pe_err("Couldn't get LISTEN_INTERVAL"); pAddBssParams->staContext.listenInterval = listen_interval; pAddBssParams->staContext.assocId = 0; @@ -4615,7 +4615,7 @@ tSirRetStatus lim_sta_send_add_bss_pre_assoc(tpAniSirGlobal pMac, uint8_t update MTRACE(mac_trace_msg_tx(pMac, psessionEntry->peSessionId, msgQ.type)); retCode = wma_post_ctrl_msg(pMac, &msgQ); - if (eSIR_SUCCESS != retCode) { + if (QDF_STATUS_SUCCESS != retCode) { SET_LIM_PROCESS_DEFD_MESGS(pMac, true); qdf_mem_free(pAddBssParams); pe_err("Posting ADD_BSS_REQ to HAL failed, reason=%X", @@ -4699,7 +4699,7 @@ void lim_init_pre_auth_timer_table(tpAniSirGlobal pMac, /* Get AUTH_RSP Timers value */ if (wlan_cfg_get_int(pMac, WNI_CFG_AUTHENTICATE_RSP_TIMEOUT, - &cfgValue) != eSIR_SUCCESS) { + &cfgValue) != QDF_STATUS_SUCCESS) { pe_err("could not retrieve AUTH_RSP timeout value"); return; } @@ -4766,7 +4766,7 @@ tLimPreAuthNode *lim_get_pre_auth_node_from_index(tpAniSirGlobal pMac, } /* Util API to check if the channels supported by STA is within range */ -tSirRetStatus lim_is_dot11h_supported_channels_valid(tpAniSirGlobal pMac, +QDF_STATUS lim_is_dot11h_supported_channels_valid(tpAniSirGlobal pMac, tSirAssocReq *assoc) { /* @@ -4776,11 +4776,11 @@ tSirRetStatus lim_is_dot11h_supported_channels_valid(tpAniSirGlobal pMac, * The specification of the algorithm is beyond the scope of this amendment. */ - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /* Util API to check if the txpower supported by STA is within range */ -tSirRetStatus lim_is_dot11h_power_capabilities_in_range(tpAniSirGlobal pMac, +QDF_STATUS lim_is_dot11h_power_capabilities_in_range(tpAniSirGlobal pMac, tSirAssocReq *assoc, tpPESession psessionEntry) { @@ -4793,9 +4793,9 @@ tSirRetStatus lim_is_dot11h_power_capabilities_in_range(tpAniSirGlobal pMac, if (wlan_cfg_get_int (pMac, WNI_CFG_LOCAL_POWER_CONSTRAINT, - &localPwrConstraint) != eSIR_SUCCESS) { + &localPwrConstraint) != QDF_STATUS_SUCCESS) { pe_err("Unable to get Local Power Constraint from cfg"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } localMaxTxPower -= (int8_t) localPwrConstraint; @@ -4806,10 +4806,10 @@ tSirRetStatus lim_is_dot11h_power_capabilities_in_range(tpAniSirGlobal pMac, if (assoc->powerCapability.minTxPower > localMaxTxPower) { pe_warn("minTxPower (STA): %d, localMaxTxPower (AP): %d", assoc->powerCapability.minTxPower, localMaxTxPower); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /** ------------------------------------------------------------- diff --git a/core/mac/src/pe/lim/lim_assoc_utils.h b/core/mac/src/pe/lim/lim_assoc_utils.h index ffde6d9688..6b11583668 100644 --- a/core/mac/src/pe/lim/lim_assoc_utils.h +++ b/core/mac/src/pe/lim/lim_assoc_utils.h @@ -53,12 +53,12 @@ uint8_t lim_check_rx_wpa_ie_match(tpAniSirGlobal, tDot11fIEWPA, tpPESession, uint8_t lim_check_mcs_set(tpAniSirGlobal pMac, uint8_t *supportedMCSSet); void limPostDummyToTmRing(tpAniSirGlobal, tpDphHashNode); void limPostPacketToTdRing(tpAniSirGlobal, tpDphHashNode, uint8_t); -tSirRetStatus lim_cleanup_rx_path(tpAniSirGlobal, tpDphHashNode, tpPESession); +QDF_STATUS lim_cleanup_rx_path(tpAniSirGlobal, tpDphHashNode, tpPESession); void lim_reject_association(tpAniSirGlobal, tSirMacAddr, uint8_t, uint8_t, tAniAuthType, uint16_t, uint8_t, enum eSirMacStatusCodes, tpPESession); -tSirRetStatus lim_populate_peer_rate_set(tpAniSirGlobal pMac, +QDF_STATUS lim_populate_peer_rate_set(tpAniSirGlobal pMac, tpSirSupportedRates pRates, uint8_t *pSupportedMCSSet, uint8_t basicOnly, @@ -66,7 +66,7 @@ tSirRetStatus lim_populate_peer_rate_set(tpAniSirGlobal pMac, tDot11fIEVHTCaps *pVHTCaps, tDot11fIEhe_cap *he_caps); -tSirRetStatus lim_populate_own_rate_set(tpAniSirGlobal pMac, +QDF_STATUS lim_populate_own_rate_set(tpAniSirGlobal pMac, tpSirSupportedRates pRates, uint8_t *pSupportedMCSSet, uint8_t basicOnly, @@ -74,7 +74,7 @@ tSirRetStatus lim_populate_own_rate_set(tpAniSirGlobal pMac, tDot11fIEVHTCaps *pVHTCaps, tDot11fIEhe_cap *he_caps); -tSirRetStatus +QDF_STATUS lim_populate_matching_rate_set(tpAniSirGlobal pMac, tpDphHashNode pStaDs, tSirMacRateSet *pOperRateSet, @@ -84,10 +84,10 @@ lim_populate_matching_rate_set(tpAniSirGlobal pMac, tDot11fIEVHTCaps *pVHTCaps, tDot11fIEhe_cap *he_caps); -tSirRetStatus lim_add_sta(tpAniSirGlobal, tpDphHashNode, uint8_t, tpPESession); -tSirRetStatus lim_del_bss(tpAniSirGlobal, tpDphHashNode, uint16_t, tpPESession); -tSirRetStatus lim_del_sta(tpAniSirGlobal, tpDphHashNode, bool, tpPESession); -tSirRetStatus lim_add_sta_self(tpAniSirGlobal, uint16_t, uint8_t, tpPESession); +QDF_STATUS lim_add_sta(tpAniSirGlobal, tpDphHashNode, uint8_t, tpPESession); +QDF_STATUS lim_del_bss(tpAniSirGlobal, tpDphHashNode, uint16_t, tpPESession); +QDF_STATUS lim_del_sta(tpAniSirGlobal, tpDphHashNode, bool, tpPESession); +QDF_STATUS lim_add_sta_self(tpAniSirGlobal, uint16_t, uint8_t, tpPESession); void lim_teardown_infra_bss(tpAniSirGlobal, tpPESession); #ifdef WLAN_FEATURE_HOST_ROAM @@ -103,7 +103,7 @@ void lim_handle_del_bss_in_re_assoc_context(tpAniSirGlobal pMac, tpDphHashNode pStaDs, tpPESession psessionEntry); void lim_send_retry_reassoc_req_frame(tpAniSirGlobal pMac, tLimMlmReassocReq *pMlmReassocReq, tpPESession psessionEntry); -tSirRetStatus lim_add_ft_sta_self(tpAniSirGlobal pMac, uint16_t assocId, +QDF_STATUS lim_add_ft_sta_self(tpAniSirGlobal pMac, uint16_t assocId, tpPESession psessionEntry); #else static inline void lim_restore_pre_reassoc_state(tpAniSirGlobal mac_ctx, @@ -128,10 +128,10 @@ static inline bool lim_is_reassoc_in_progress(tpAniSirGlobal mac_ctx, { return false; } -static inline tSirRetStatus lim_add_ft_sta_self(tpAniSirGlobal pMac, +static inline QDF_STATUS lim_add_ft_sta_self(tpAniSirGlobal pMac, uint16_t assocId, tpPESession psessionEntry) { - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } #endif @@ -165,16 +165,16 @@ void lim_update_assoc_sta_datas(tpAniSirGlobal pMac, tpDphHashNode pStaDs, tpSirAssocRsp pAssocRsp, tpPESession psessionEntry); -tSirRetStatus lim_sta_send_add_bss(tpAniSirGlobal pMac, tpSirAssocRsp pAssocRsp, +QDF_STATUS lim_sta_send_add_bss(tpAniSirGlobal pMac, tpSirAssocRsp pAssocRsp, tpSchBeaconStruct pBeaconStruct, tpSirBssDescription bssDescription, uint8_t updateEntry, tpPESession psessionEntry); -tSirRetStatus lim_sta_send_add_bss_pre_assoc(tpAniSirGlobal pMac, uint8_t updateEntry, +QDF_STATUS lim_sta_send_add_bss_pre_assoc(tpAniSirGlobal pMac, uint8_t updateEntry, tpPESession psessionEntry); void lim_prepare_and_send_del_sta_cnf(tpAniSirGlobal pMac, tpDphHashNode pStaDs, tSirResultCodes statusCode, tpPESession); -tSirRetStatus lim_extract_ap_capabilities(tpAniSirGlobal pMac, uint8_t *pIE, +QDF_STATUS lim_extract_ap_capabilities(tpAniSirGlobal pMac, uint8_t *pIE, uint16_t ieLen, tpSirProbeRespBeacon beaconStruct); void lim_init_pre_auth_timer_table(tpAniSirGlobal pMac, @@ -187,11 +187,11 @@ tpLimPreAuthNode lim_get_pre_auth_node_from_index(tpAniSirGlobal pMac, uint32_t authNodeIdx); /* Util API to check if the channels supported by STA is within range */ -tSirRetStatus lim_is_dot11h_supported_channels_valid(tpAniSirGlobal pMac, +QDF_STATUS lim_is_dot11h_supported_channels_valid(tpAniSirGlobal pMac, tSirAssocReq *assoc); /* Util API to check if the txpower supported by STA is within range */ -tSirRetStatus lim_is_dot11h_power_capabilities_in_range(tpAniSirGlobal pMac, +QDF_STATUS lim_is_dot11h_power_capabilities_in_range(tpAniSirGlobal pMac, tSirAssocReq *assoc, tpPESession); /* API to fill in RX Highest Supported data Rate */ @@ -215,7 +215,7 @@ static inline void lim_send_sme_tsm_ie_ind(tpAniSirGlobal pMac, {} #endif /* FEATURE_WLAN_ESE */ -tSirRetStatus lim_populate_vht_mcs_set(tpAniSirGlobal pMac, +QDF_STATUS lim_populate_vht_mcs_set(tpAniSirGlobal pMac, tpSirSupportedRates pRates, tDot11fIEVHTCaps *pPeerVHTCaps, tpPESession psessionEntry, diff --git a/core/mac/src/pe/lim/lim_ft.c b/core/mac/src/pe/lim/lim_ft.c index 4daec260cd..062bc117fe 100644 --- a/core/mac/src/pe/lim/lim_ft.c +++ b/core/mac/src/pe/lim/lim_ft.c @@ -807,7 +807,7 @@ bool lim_process_ft_update_key(tpAniSirGlobal pMac, uint32_t *pMsgBuf) qdf_mem_copy((uint8_t *) &pAddBssParams->extSetStaKeyParam.key, (uint8_t *) &pKeyInfo->keyMaterial.key, sizeof(tSirKeys)); - if (eSIR_SUCCESS != + if (QDF_STATUS_SUCCESS != wlan_cfg_get_int(pMac, WNI_CFG_SINGLE_TID_RC, &val)) { pe_warn("Unable to read WNI_CFG_SINGLE_TID_RC"); } @@ -929,7 +929,7 @@ void lim_process_ft_aggr_qo_s_rsp(tpAniSirGlobal pMac, return; } -tSirRetStatus lim_process_ft_aggr_qos_req(tpAniSirGlobal pMac, uint32_t *pMsgBuf) +QDF_STATUS lim_process_ft_aggr_qos_req(tpAniSirGlobal pMac, uint32_t *pMsgBuf) { struct scheduler_msg msg = {0}; tSirAggrQosReq *aggrQosReq = (tSirAggrQosReq *) pMsgBuf; @@ -945,7 +945,7 @@ tSirRetStatus lim_process_ft_aggr_qos_req(tpAniSirGlobal pMac, uint32_t *pMsgBuf pAggrAddTsParam = qdf_mem_malloc(sizeof(tAggrAddTsParams)); if (NULL == pAggrAddTsParam) { pe_err("AllocateMemory() failed"); - return eSIR_MEM_ALLOC_FAILED; + return QDF_STATUS_E_NOMEM; } psessionEntry = pe_find_session_by_bssid(pMac, aggrQosReq->bssid.bytes, @@ -955,14 +955,14 @@ tSirRetStatus lim_process_ft_aggr_qos_req(tpAniSirGlobal pMac, uint32_t *pMsgBuf pe_err("psession Entry Null for sessionId: %d", aggrQosReq->sessionId); qdf_mem_free(pAggrAddTsParam); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } /* Nothing to be done if the session is not in STA mode */ if (!LIM_IS_STA_ROLE(psessionEntry)) { pe_err("psessionEntry is not in STA mode"); qdf_mem_free(pAggrAddTsParam); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } pSta = dph_lookup_hash_entry(pMac, aggrQosReq->bssid.bytes, &aid, @@ -970,7 +970,7 @@ tSirRetStatus lim_process_ft_aggr_qos_req(tpAniSirGlobal pMac, uint32_t *pMsgBuf if (pSta == NULL) { pe_err("Station context not found - ignoring AddTsRsp"); qdf_mem_free(pAggrAddTsParam); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } pAggrAddTsParam->staIdx = psessionEntry->staId; @@ -1043,13 +1043,13 @@ tSirRetStatus lim_process_ft_aggr_qos_req(tpAniSirGlobal pMac, uint32_t *pMsgBuf psessionEntry->gLimEdcaParamsActive, pSta->bssId, false); - if (eSIR_SUCCESS != + if (QDF_STATUS_SUCCESS != lim_tspec_add(pMac, pSta->staAddr, pSta->assocId, pTspec, 0, &tspecInfo)) { pe_err("Adding entry in lim Tspec Table failed"); pMac->lim.gLimAddtsSent = false; qdf_mem_free(pAggrAddTsParam); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } pAggrAddTsParam->tspec[i] = @@ -1073,11 +1073,11 @@ tSirRetStatus lim_process_ft_aggr_qos_req(tpAniSirGlobal pMac, uint32_t *pMsgBuf SET_LIM_PROCESS_DEFD_MESGS(pMac, false); MTRACE(mac_trace_msg_tx(pMac, psessionEntry->peSessionId, msg.type)); - if (eSIR_SUCCESS != wma_post_ctrl_msg(pMac, &msg)) { + if (QDF_STATUS_SUCCESS != wma_post_ctrl_msg(pMac, &msg)) { pe_warn("wma_post_ctrl_msg() failed"); SET_LIM_PROCESS_DEFD_MESGS(pMac, true); qdf_mem_free(pAggrAddTsParam); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } } #ifdef WLAN_FEATURE_ROAM_OFFLOAD @@ -1095,5 +1095,5 @@ tSirRetStatus lim_process_ft_aggr_qos_req(tpAniSirGlobal pMac, uint32_t *pMsgBuf } #endif - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } diff --git a/core/mac/src/pe/lim/lim_ft_preauth.c b/core/mac/src/pe/lim/lim_ft_preauth.c index 1f05434134..50517d82e2 100644 --- a/core/mac/src/pe/lim/lim_ft_preauth.c +++ b/core/mac/src/pe/lim/lim_ft_preauth.c @@ -145,7 +145,7 @@ int lim_process_ft_pre_auth_req(tpAniSirGlobal mac_ctx, MAC_ADDRESS_STR, MAC_ADDR_ARRAY(ft_pre_auth_req->currbssId)); /* Post the FT Pre Auth Response to SME */ - lim_post_ft_pre_auth_rsp(mac_ctx, eSIR_FAILURE, NULL, 0, + lim_post_ft_pre_auth_rsp(mac_ctx, QDF_STATUS_E_FAILURE, NULL, 0, session); buf_consumed = true; return buf_consumed; @@ -159,7 +159,7 @@ int lim_process_ft_pre_auth_req(tpAniSirGlobal mac_ctx, } /* Can set it only after sending auth */ - session->ftPEContext.ftPreAuthStatus = eSIR_FAILURE; + session->ftPEContext.ftPreAuthStatus = QDF_STATUS_E_FAILURE; session->ftPEContext.ftPreAuthSession = true; /* Indicate that this is the session on which preauth is being done */ @@ -290,7 +290,7 @@ void lim_perform_ft_pre_auth(tpAniSirGlobal pMac, QDF_STATUS status, pe_debug("FT Auth Rsp Timer Started"); #ifdef FEATURE_WLAN_DIAG_SUPPORT lim_diag_event_report(pMac, WLAN_PE_DIAG_ROAM_AUTH_START_EVENT, - pMac->lim.pSessionEntry, eSIR_SUCCESS, eSIR_SUCCESS); + pMac->lim.pSessionEntry, QDF_STATUS_SUCCESS, QDF_STATUS_SUCCESS); #endif lim_send_auth_mgmt_frame(pMac, &authFrame, @@ -300,7 +300,7 @@ void lim_perform_ft_pre_auth(tpAniSirGlobal pMac, QDF_STATUS status, return; preauth_fail: - lim_handle_ft_pre_auth_rsp(pMac, eSIR_FAILURE, NULL, 0, psessionEntry); + lim_handle_ft_pre_auth_rsp(pMac, QDF_STATUS_E_FAILURE, NULL, 0, psessionEntry); return; } @@ -313,7 +313,7 @@ preauth_fail: * * Return: Success or Failure Status */ -tSirRetStatus lim_ft_setup_auth_session(tpAniSirGlobal pMac, +QDF_STATUS lim_ft_setup_auth_session(tpAniSirGlobal pMac, tpPESession psessionEntry) { tpPESession pftSessionEntry = NULL; @@ -325,13 +325,13 @@ tSirRetStatus lim_ft_setup_auth_session(tpAniSirGlobal pMac, if (pftSessionEntry == NULL) { pe_err("No session found for bssid"); lim_print_mac_addr(pMac, psessionEntry->limReAssocbssId, LOGE); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } /* Nothing to be done if the session is not in STA mode */ if (!LIM_IS_STA_ROLE(psessionEntry)) { pe_err("psessionEntry is not in STA mode"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } if (psessionEntry->ftPEContext.pFTPreAuthReq && @@ -345,7 +345,7 @@ tSirRetStatus lim_ft_setup_auth_session(tpAniSirGlobal pMac, psessionEntry->ftPEContext.pFTPreAuthReq->pbssDescription); } - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /** @@ -368,7 +368,7 @@ static void lim_ft_process_pre_auth_result(tpAniSirGlobal pMac, return; } - if (psessionEntry->ftPEContext.ftPreAuthStatus == eSIR_SUCCESS) { + if (psessionEntry->ftPEContext.ftPreAuthStatus == QDF_STATUS_SUCCESS) { psessionEntry->ftPEContext.ftPreAuthStatus = lim_ft_setup_auth_session(pMac, psessionEntry); } @@ -396,7 +396,7 @@ static void lim_ft_process_pre_auth_result(tpAniSirGlobal pMac, * * @Return: None */ -void lim_handle_ft_pre_auth_rsp(tpAniSirGlobal pMac, tSirRetStatus status, +void lim_handle_ft_pre_auth_rsp(tpAniSirGlobal pMac, QDF_STATUS status, uint8_t *auth_rsp, uint16_t auth_rsp_length, tpPESession psessionEntry) { @@ -435,7 +435,7 @@ void lim_handle_ft_pre_auth_rsp(tpAniSirGlobal pMac, tSirRetStatus status, } /* Create FT session for the re-association at this point */ - if (psessionEntry->ftPEContext.ftPreAuthStatus == eSIR_SUCCESS) { + if (psessionEntry->ftPEContext.ftPreAuthStatus == QDF_STATUS_SUCCESS) { pbssDescription = psessionEntry->ftPEContext.pFTPreAuthReq->pbssDescription; pftSessionEntry = @@ -444,7 +444,7 @@ void lim_handle_ft_pre_auth_rsp(tpAniSirGlobal pMac, tSirRetStatus status, psessionEntry->bssType); if (pftSessionEntry == NULL) { pe_err("Session not created for pre-auth 11R AP"); - status = eSIR_FAILURE; + status = QDF_STATUS_E_FAILURE; psessionEntry->ftPEContext.ftPreAuthStatus = status; goto send_rsp; } @@ -571,7 +571,7 @@ void lim_process_ft_preauth_rsp_timeout(tpAniSirGlobal mac_ctx) * Attempted at Pre-Auth and failed. If we are off channel. We need * to get back to home channel */ - lim_handle_ft_pre_auth_rsp(mac_ctx, eSIR_FAILURE, NULL, 0, session); + lim_handle_ft_pre_auth_rsp(mac_ctx, QDF_STATUS_E_FAILURE, NULL, 0, session); } /* @@ -588,7 +588,7 @@ void lim_process_ft_preauth_rsp_timeout(tpAniSirGlobal mac_ctx) * Return: void */ void lim_post_ft_pre_auth_rsp(tpAniSirGlobal mac_ctx, - tSirRetStatus status, + QDF_STATUS status, uint8_t *auth_rsp, uint16_t auth_rsp_length, tpPESession session) @@ -632,7 +632,7 @@ void lim_post_ft_pre_auth_rsp(tpAniSirGlobal mac_ctx, ft_pre_auth_rsp->ft_ies_length = auth_rsp_length; } - if (status != eSIR_SUCCESS) { + if (status != QDF_STATUS_SUCCESS) { /* * Ensure that on Pre-Auth failure the cached Pre-Auth Req and * other allocated memory is freed up before returning. @@ -647,7 +647,7 @@ void lim_post_ft_pre_auth_rsp(tpAniSirGlobal mac_ctx, pe_debug("Posted Auth Rsp to SME with status of 0x%x", status); #ifdef FEATURE_WLAN_DIAG_SUPPORT_LIM /* FEATURE_WLAN_DIAG_SUPPORT */ - if (status == eSIR_SUCCESS) + if (status == QDF_STATUS_SUCCESS) lim_diag_event_report(mac_ctx, WLAN_PE_DIAG_PREAUTH_DONE, session, status, 0); #endif @@ -779,7 +779,7 @@ void lim_preauth_scan_event_handler(tpAniSirGlobal mac_ctx, case SIR_SCAN_EVENT_START_FAILED: /* Scan command is rejected by firmware */ pe_err("Failed to start preauth scan"); - lim_post_ft_pre_auth_rsp(mac_ctx, eSIR_FAILURE, NULL, 0, + lim_post_ft_pre_auth_rsp(mac_ctx, QDF_STATUS_E_FAILURE, NULL, 0, session_entry); return; diff --git a/core/mac/src/pe/lim/lim_ibss_peer_mgmt.c b/core/mac/src/pe/lim/lim_ibss_peer_mgmt.c index a61ca6ccc6..6fc4bae0fc 100644 --- a/core/mac/src/pe/lim/lim_ibss_peer_mgmt.c +++ b/core/mac/src/pe/lim/lim_ibss_peer_mgmt.c @@ -86,7 +86,7 @@ static tLimIbssPeerNode *ibss_peer_find(tpAniSirGlobal pMac, * @return None */ -static tSirRetStatus +static QDF_STATUS ibss_peer_add(tpAniSirGlobal pMac, tLimIbssPeerNode *pPeerNode) { #ifdef ANI_SIR_IBSS_PEER_CACHING @@ -117,7 +117,7 @@ ibss_peer_add(tpAniSirGlobal pMac, tLimIbssPeerNode *pPeerNode) pPeerNode->next = pMac->lim.gLimIbssPeerList; pMac->lim.gLimIbssPeerList = pPeerNode; - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /*** end limAddIbssPeerToList() ***/ @@ -396,7 +396,7 @@ ibss_coalesce_save(tpAniSirGlobal pMac, * tries to add a new entry to dph hash node * if necessary, an existing entry is eliminated */ -static tSirRetStatus +static QDF_STATUS ibss_dph_entry_add(tpAniSirGlobal pMac, tSirMacAddr peerAddr, tpDphHashNode *ppSta, tpPESession psessionEntry) @@ -413,7 +413,7 @@ ibss_dph_entry_add(tpAniSirGlobal pMac, /* Trying to add context for already existing STA in IBSS */ pe_err("STA exists already"); lim_print_mac_addr(pMac, peerAddr, LOGE); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } /** @@ -440,11 +440,11 @@ ibss_dph_entry_add(tpAniSirGlobal pMac, pe_err("could not add hash entry at DPH for peerIdx/aid: %d MACaddr:", peerIdx); lim_print_mac_addr(pMac, peerAddr, LOGE); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } *ppSta = pStaDs; - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /* send a status change notification */ @@ -528,7 +528,7 @@ static void ibss_bss_add(tpAniSirGlobal pMac, tpPESession psessionEntry) numExtRates = pBeacon->extendedRates.numRates; if (cfg_set_str(pMac, WNI_CFG_EXTENDED_OPERATIONAL_RATE_SET, (uint8_t *) &pBeacon->extendedRates.rate, - numExtRates) != eSIR_SUCCESS) { + numExtRates) != QDF_STATUS_SUCCESS) { pe_err("could not update ExtendedOperRateset at CFG"); return; } @@ -573,7 +573,7 @@ static void ibss_bss_add(tpAniSirGlobal pMac, tpPESession psessionEntry) return; } /* Update fields in Beacon */ - if (sch_set_fixed_beacon_fields(pMac, psessionEntry) != eSIR_SUCCESS) { + if (sch_set_fixed_beacon_fields(pMac, psessionEntry) != QDF_STATUS_SUCCESS) { pe_err("Unable to set fixed Beacon fields"); return; } @@ -583,7 +583,7 @@ static void ibss_bss_add(tpAniSirGlobal pMac, tpPESession psessionEntry) /* delete the current BSS */ static void ibss_bss_delete(tpAniSirGlobal pMac, tpPESession psessionEntry) { - tSirRetStatus status; + QDF_STATUS status; pe_debug("Initiating IBSS Delete BSS"); if (psessionEntry->limMlmState != eLIM_MLM_BSS_STARTED_STATE) { @@ -592,7 +592,7 @@ static void ibss_bss_delete(tpAniSirGlobal pMac, tpPESession psessionEntry) return; } status = lim_del_bss(pMac, NULL, psessionEntry->bssIdx, psessionEntry); - if (status != eSIR_SUCCESS) + if (status != QDF_STATUS_SUCCESS) pe_err("delBss failed for bss: %d", psessionEntry->bssIdx); } @@ -915,10 +915,10 @@ tLimIbssPeerNode *lim_ibss_peer_find(tpAniSirGlobal pMac, tSirMacAddr macAddr) * @return */ -tSirRetStatus +QDF_STATUS lim_ibss_sta_add(tpAniSirGlobal pMac, void *pBody, tpPESession psessionEntry) { - tSirRetStatus retCode = eSIR_SUCCESS; + QDF_STATUS retCode = QDF_STATUS_SUCCESS; tpDphHashNode pStaDs; tLimIbssPeerNode *pPeerNode; tLimMlmStates prevState; @@ -929,7 +929,7 @@ lim_ibss_sta_add(tpAniSirGlobal pMac, void *pBody, tpPESession psessionEntry) if (pBody == 0) { pe_err("Invalid IBSS AddSta"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } pe_debug("Rx Add-Ibss-Sta for MAC:"); @@ -940,7 +940,7 @@ lim_ibss_sta_add(tpAniSirGlobal pMac, void *pBody, tpPESession psessionEntry) retCode = ibss_dph_entry_add(pMac, *pPeerAddr, &pStaDs, psessionEntry); - if (eSIR_SUCCESS == retCode) { + if (QDF_STATUS_SUCCESS == retCode) { prevState = pStaDs->mlmStaContext.mlmState; pStaDs->erpEnabled = pPeerNode->erpIePresent; @@ -949,7 +949,7 @@ lim_ibss_sta_add(tpAniSirGlobal pMac, void *pBody, tpPESession psessionEntry) pe_debug("initiating ADD STA for the IBSS peer"); retCode = lim_add_sta(pMac, pStaDs, false, psessionEntry); - if (retCode != eSIR_SUCCESS) { + if (retCode != QDF_STATUS_SUCCESS) { pe_err("ibss-sta-add failed (reason %x)", retCode); lim_print_mac_addr(pMac, *pPeerAddr, LOGE); @@ -980,7 +980,7 @@ lim_ibss_sta_add(tpAniSirGlobal pMac, void *pBody, tpPESession psessionEntry) lim_print_mac_addr(pMac, *pPeerAddr, LOGE); } } else { - retCode = eSIR_FAILURE; + retCode = QDF_STATUS_E_FAILURE; } return retCode; @@ -1158,7 +1158,7 @@ skip_event: } /* handle the response from HAL for an ADD STA request */ -tSirRetStatus +QDF_STATUS lim_ibss_add_sta_rsp(tpAniSirGlobal pMac, void *msg, tpPESession psessionEntry) { tpDphHashNode pStaDs; @@ -1168,7 +1168,7 @@ lim_ibss_add_sta_rsp(tpAniSirGlobal pMac, void *msg, tpPESession psessionEntry) SET_LIM_PROCESS_DEFD_MESGS(pMac, true); if (pAddStaParams == NULL) { pe_err("IBSS: ADD_STA_RSP with no body!"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } pStaDs = @@ -1178,7 +1178,7 @@ lim_ibss_add_sta_rsp(tpAniSirGlobal pMac, void *msg, tpPESession psessionEntry) pe_err("IBSS: ADD_STA_RSP for unknown MAC addr: "MAC_ADDRESS_STR, MAC_ADDR_ARRAY(pAddStaParams->staMac)); qdf_mem_free(pAddStaParams); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } if (pAddStaParams->status != QDF_STATUS_SUCCESS) { @@ -1188,7 +1188,7 @@ lim_ibss_add_sta_rsp(tpAniSirGlobal pMac, void *msg, tpPESession psessionEntry) lim_ibss_delete_peer(pMac, psessionEntry, pAddStaParams->staMac); qdf_mem_free(pAddStaParams); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } pStaDs->bssId = pAddStaParams->bssIdx; @@ -1205,7 +1205,7 @@ lim_ibss_add_sta_rsp(tpAniSirGlobal pMac, void *msg, tpPESession psessionEntry) qdf_mem_free(pAddStaParams); - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } void lim_ibss_del_bss_rsp_when_coalescing(tpAniSirGlobal pMac, void *msg, @@ -1316,7 +1316,7 @@ void lim_ibss_del_bss_rsp(tpAniSirGlobal pMac, void *msg, tpPESession psessionEn if (lim_set_link_state(pMac, eSIR_LINK_IDLE_STATE, nullBssid, psessionEntry->selfMacAddr, NULL, - NULL) != eSIR_SUCCESS) { + NULL) != QDF_STATUS_SUCCESS) { pe_err("IBSS: DEL_BSS_RSP setLinkState failed"); rc = eSIR_SME_REFUSED; goto end; @@ -1373,7 +1373,7 @@ end: * @return Status whether to process or ignore received Beacon Frame */ -tSirRetStatus +QDF_STATUS lim_ibss_coalesce(tpAniSirGlobal pMac, tpSirMacMgmtHdr pHdr, tpSchBeaconStruct pBeacon, @@ -1412,12 +1412,12 @@ lim_ibss_coalesce(tpAniSirGlobal pMac, lim_ibss_delete_peer(pMac, psessionEntry, pHdr->sa); pe_warn("Peer attempting to reconnect before HB timeout, deleted"); - return eSIR_LIM_IGNORE_BEACON; + return QDF_STATUS_E_INVAL; } if (!fTsfLater) { /* No Coalescing happened. */ pe_warn("No Coalescing happened"); - return eSIR_LIM_IGNORE_BEACON; + return QDF_STATUS_E_INVAL; } /* * IBSS Coalescing happened. @@ -1429,11 +1429,11 @@ lim_ibss_coalesce(tpAniSirGlobal pMac, pe_debug("IBSS Coalescing happened Delete BSSID :" MAC_ADDRESS_STR, MAC_ADDR_ARRAY(currentBssId)); ibss_bss_delete(pMac, psessionEntry); - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } else { if (qdf_mem_cmp (currentBssId, pHdr->bssId, sizeof(tSirMacAddr))) - return eSIR_LIM_IGNORE_BEACON; + return QDF_STATUS_E_INVAL; } /* STA in IBSS mode and SSID matches with ours */ @@ -1441,7 +1441,7 @@ lim_ibss_coalesce(tpAniSirGlobal pMac, if (pPeerNode == NULL) { /* Peer not in the list - Collect BSS description & add to the list */ uint32_t frameLen; - tSirRetStatus retCode; + QDF_STATUS retCode; /* * Limit the Max number of IBSS Peers allowed as the max @@ -1457,7 +1457,7 @@ lim_ibss_coalesce(tpAniSirGlobal pMac, pe_debug("**** MAX STA LIMIT HAS REACHED ****"); } pMac->lim.ibss_retry_cnt++; - return eSIR_LIM_MAX_STA_REACHED_ERROR; + return QDF_STATUS_E_NOSPC; } pe_debug("IBSS Peer node does not exist, adding it"); frameLen = @@ -1467,7 +1467,7 @@ lim_ibss_coalesce(tpAniSirGlobal pMac, if (NULL == pPeerNode) { pe_err("alloc fail %d bytes storing IBSS peer info", frameLen); - return eSIR_MEM_ALLOC_FAILED; + return QDF_STATUS_E_NOMEM; } pPeerNode->beacon = NULL; @@ -1493,11 +1493,11 @@ lim_ibss_coalesce(tpAniSirGlobal pMac, lim_print_mac_addr(pMac, pPeerNode->peerMacAddr, LOGD); ibss_sta_info_update(pMac, pStaDs, pPeerNode, psessionEntry); - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } retCode = lim_ibss_sta_add(pMac, pPeerNode->peerMacAddr, psessionEntry); - if (retCode != eSIR_SUCCESS) { + if (retCode != QDF_STATUS_SUCCESS) { pe_err("lim-ibss-sta-add failed reason: %x", retCode); lim_print_mac_addr(pMac, pPeerNode->peerMacAddr, LOGE); return retCode; @@ -1521,7 +1521,7 @@ lim_ibss_coalesce(tpAniSirGlobal pMac, ibss_sta_caps_update(pMac, pPeerNode, psessionEntry); if (psessionEntry->limSmeState != eLIM_SME_NORMAL_STATE) - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; /* Received Beacon from same IBSS we're */ /* currently part of. Inform Roaming algorithm */ @@ -1534,7 +1534,7 @@ lim_ibss_coalesce(tpAniSirGlobal pMac, psessionEntry->smeSessionId); } - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /*** end lim_handle_ibs_scoalescing() ***/ /** diff --git a/core/mac/src/pe/lim/lim_ibss_peer_mgmt.h b/core/mac/src/pe/lim/lim_ibss_peer_mgmt.h index 78636ac104..bc2ae06295 100644 --- a/core/mac/src/pe/lim/lim_ibss_peer_mgmt.h +++ b/core/mac/src/pe/lim/lim_ibss_peer_mgmt.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2011-2012, 2014-2017 The Linux Foundation. All rights reserved. + * Copyright (c) 2011-2012, 2014-2018 The Linux Foundation. All rights reserved. * * Permission to use, copy, modify, and/or distribute this software for * any purpose with or without fee is hereby granted, provided that the @@ -32,11 +32,11 @@ void lim_ibss_init(tpAniSirGlobal); void lim_ibss_delete(tpAniSirGlobal, tpPESession psessionEntry); -tSirRetStatus lim_ibss_coalesce(tpAniSirGlobal, tpSirMacMgmtHdr, +QDF_STATUS lim_ibss_coalesce(tpAniSirGlobal, tpSirMacMgmtHdr, tpSchBeaconStruct, uint8_t *, uint32_t, uint16_t, tpPESession); -tSirRetStatus lim_ibss_sta_add(tpAniSirGlobal, void *, tpPESession); -tSirRetStatus lim_ibss_add_sta_rsp(tpAniSirGlobal, void *, tpPESession); +QDF_STATUS lim_ibss_sta_add(tpAniSirGlobal, void *, tpPESession); +QDF_STATUS lim_ibss_add_sta_rsp(tpAniSirGlobal, void *, tpPESession); /** * lim_process_ibss_del_sta_rsp()- Handle ibss delete diff --git a/core/mac/src/pe/lim/lim_process_action_frame.c b/core/mac/src/pe/lim/lim_process_action_frame.c index c75d6b4994..a4c370dc07 100644 --- a/core/mac/src/pe/lim/lim_process_action_frame.c +++ b/core/mac/src/pe/lim/lim_process_action_frame.c @@ -128,7 +128,7 @@ void lim_stop_tx_and_switch_channel(tpAniSirGlobal pMac, uint8_t sessionId) \param psessionEntry \return NONE ------------------------------------------------------------*/ -tSirRetStatus lim_start_channel_switch(tpAniSirGlobal pMac, +QDF_STATUS lim_start_channel_switch(tpAniSirGlobal pMac, tpPESession psessionEntry) { pe_debug("Starting the channel switch"); @@ -140,7 +140,7 @@ tSirRetStatus lim_start_channel_switch(tpAniSirGlobal pMac, eLIM_11H_CHANSW_RUNNING) || psessionEntry->csaOffloadEnable) { pe_warn("Ignoring channel switch on session: %d", psessionEntry->peSessionId); - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /* Deactivate and change reconfigure the timeout value */ @@ -149,16 +149,16 @@ tSirRetStatus lim_start_channel_switch(tpAniSirGlobal pMac, (pMac, TRACE_CODE_TIMER_DEACTIVATE, psessionEntry->peSessionId, eLIM_CHANNEL_SWITCH_TIMER)); if (tx_timer_deactivate(&pMac->lim.limTimers.gLimChannelSwitchTimer) != - eSIR_SUCCESS) { + QDF_STATUS_SUCCESS) { pe_err("tx_timer_deactivate failed!"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } if (tx_timer_change(&pMac->lim.limTimers.gLimChannelSwitchTimer, psessionEntry->gLimChannelSwitch.switchTimeoutValue, 0) != TX_SUCCESS) { pe_err("tx_timer_change failed"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } /* Follow the channel switch, forget about the previous quiet. */ @@ -171,7 +171,7 @@ tSirRetStatus lim_start_channel_switch(tpAniSirGlobal pMac, if (tx_timer_deactivate(&pMac->lim.limTimers.gLimQuietTimer) != TX_SUCCESS) { pe_err("tx_timer_deactivate failed"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } } else if (psessionEntry->gLimSpecMgmt.quietState == eLIM_QUIET_RUNNING) { MTRACE(mac_trace @@ -180,7 +180,7 @@ tSirRetStatus lim_start_channel_switch(tpAniSirGlobal pMac, if (tx_timer_deactivate(&pMac->lim.limTimers.gLimQuietBssTimer) != TX_SUCCESS) { pe_err("tx_timer_deactivate failed"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } } psessionEntry->gLimSpecMgmt.quietState = eLIM_QUIET_INIT; @@ -191,7 +191,7 @@ tSirRetStatus lim_start_channel_switch(tpAniSirGlobal pMac, /** Dont add any more statements here as we posted finish scan request * to HAL, wait till we get the response */ - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /** @@ -322,7 +322,7 @@ static void __lim_process_channel_switch_action_frame(tpAniSirGlobal mac_ctx, session->htSupportedChannelWidthSet; } - if (eSIR_SUCCESS != lim_start_channel_switch(mac_ctx, session)) + if (QDF_STATUS_SUCCESS != lim_start_channel_switch(mac_ctx, session)) pe_err("Could not start channel switch"); qdf_mem_free(chnl_switch_frame); @@ -690,7 +690,7 @@ static void __lim_process_add_ts_rsp(tpAniSirGlobal mac_ctx, uint8_t *rx_pkt_info, tpPESession session) { tSirAddtsRspInfo addts; - tSirRetStatus retval; + QDF_STATUS retval; tpSirMacMgmtHdr mac_hdr; tpDphHashNode sta_ptr; uint16_t aid; @@ -722,7 +722,7 @@ static void __lim_process_add_ts_rsp(tpAniSirGlobal mac_ctx, retval = sir_convert_addts_rsp2_struct(mac_ctx, body_ptr, frameLen, &addts); - if (retval != eSIR_SUCCESS) { + if (retval != QDF_STATUS_SUCCESS) { pe_err("AddTsRsp parsing failed %d", retval); return; } @@ -853,7 +853,7 @@ static void __lim_process_add_ts_rsp(tpAniSirGlobal mac_ctx, /* if schedule is not present then add TSPEC with svcInterval as 0. */ if (!addts.schedulePresent) addts.schedule.svcInterval = 0; - if (eSIR_SUCCESS != + if (QDF_STATUS_SUCCESS != lim_tspec_add(mac_ctx, sta_ptr->staAddr, sta_ptr->assocId, &addts.tspec, addts.schedule.svcInterval, &tspec_info)) { pe_err("Adding entry in lim Tspec Table failed"); @@ -880,7 +880,7 @@ static void __lim_process_add_ts_rsp(tpAniSirGlobal mac_ctx, sta_ptr->staIndex, tspec_info->idx, addts.tspec, session->peSessionId); #endif - if (eSIR_SUCCESS != retval) { + if (QDF_STATUS_SUCCESS != retval) { lim_admit_control_delete_ts(mac_ctx, sta_ptr->assocId, &addts.tspec.tsinfo, NULL, &tspec_info->idx); @@ -930,7 +930,7 @@ static void __lim_process_add_ts_rsp(tpAniSirGlobal mac_ctx, static void __lim_process_del_ts_req(tpAniSirGlobal mac_ctx, uint8_t *rx_pkt_info, tpPESession session) { - tSirRetStatus retval; + QDF_STATUS retval; tSirDeltsReqInfo delts; tpSirMacMgmtHdr mac_hdr; tpDphHashNode sta_ptr; @@ -956,7 +956,7 @@ static void __lim_process_del_ts_req(tpAniSirGlobal mac_ctx, /* parse the delts request */ retval = sir_convert_delts_req2_struct(mac_ctx, body_ptr, frame_len, &delts); - if (retval != eSIR_SUCCESS) { + if (retval != QDF_STATUS_SUCCESS) { pe_err("DelTs parsing failed %d", retval); return; } @@ -991,7 +991,7 @@ static void __lim_process_del_ts_req(tpAniSirGlobal mac_ctx, lim_send_sme_delts_ind(mac_ctx, &delts, aid, session); /* try to delete the TS */ - if (eSIR_SUCCESS != + if (QDF_STATUS_SUCCESS != lim_admit_control_delete_ts(mac_ctx, sta_ptr->assocId, tsinfo, &ts_status, &tspec_idx)) { pe_warn("Unable to Delete TS"); @@ -1000,7 +1000,7 @@ static void __lim_process_del_ts_req(tpAniSirGlobal mac_ctx, || (tsinfo->traffic.accessPolicy == SIR_MAC_ACCESSPOLICY_BOTH))){ /* send message to HAL to delete TS */ - if (eSIR_SUCCESS != lim_send_hal_msg_del_ts(mac_ctx, + if (QDF_STATUS_SUCCESS != lim_send_hal_msg_del_ts(mac_ctx, sta_ptr->staIndex, tspec_idx, delts, session->peSessionId, session->bssId)) { @@ -1078,14 +1078,14 @@ static void __lim_process_qos_map_configure_frame(tpAniSirGlobal mac_ctx, tpSirMacMgmtHdr mac_hdr; uint32_t frame_len; uint8_t *body_ptr; - tSirRetStatus retval; + QDF_STATUS retval; mac_hdr = WMA_GET_RX_MAC_HEADER(rx_pkt_info); body_ptr = WMA_GET_RX_MPDU_DATA(rx_pkt_info); frame_len = WMA_GET_RX_PAYLOAD_LEN(rx_pkt_info); retval = sir_convert_qos_map_configure_frame2_struct(mac_ctx, body_ptr, frame_len, &session->QosMapSet); - if (retval != eSIR_SUCCESS) { + if (retval != QDF_STATUS_SUCCESS) { pe_err("QosMapConfigure frame parsing fail %d", retval); return; } @@ -1104,7 +1104,7 @@ __lim_process_basic_meas_req(tpAniSirGlobal pMac, { if (lim_send_meas_report_frame(pMac, pMeasReqFrame, peerMacAddr, psessionEntry) != - eSIR_SUCCESS) { + QDF_STATUS_SUCCESS) { pe_err("fail to send Basic Meas report"); return; } @@ -1116,7 +1116,7 @@ __lim_process_cca_meas_req(tpAniSirGlobal pMac, { if (lim_send_meas_report_frame(pMac, pMeasReqFrame, peerMacAddr, psessionEntry) != - eSIR_SUCCESS) { + QDF_STATUS_SUCCESS) { pe_err("fail to send CCA Meas report"); return; } @@ -1128,7 +1128,7 @@ __lim_process_rpi_meas_req(tpAniSirGlobal pMac, { if (lim_send_meas_report_frame(pMac, pMeasReqFrame, peerMacAddr, psessionEntry) != - eSIR_SUCCESS) { + QDF_STATUS_SUCCESS) { pe_err("fail to send RPI Meas report"); return; } @@ -1154,7 +1154,7 @@ __lim_process_measurement_request_frame(tpAniSirGlobal pMac, } if (sir_convert_meas_req_frame2_struct(pMac, pBody, pMeasReqFrame, frameLen) - != eSIR_SUCCESS) { + != QDF_STATUS_SUCCESS) { pe_warn("Rcv invalid Measurement Request Action Frame"); return; } @@ -1197,13 +1197,13 @@ __lim_process_tpc_request_frame(tpAniSirGlobal pMac, uint8_t *pRxPacketInfo, return; } if (sir_convert_tpc_req_frame2_struct(pMac, pBody, pTpcReqFrame, frameLen) != - eSIR_SUCCESS) { + QDF_STATUS_SUCCESS) { pe_warn("Rcv invalid TPC Req Action Frame"); return; } if (lim_send_tpc_report_frame(pMac, pTpcReqFrame, - pHdr->sa, psessionEntry) != eSIR_SUCCESS) { + pHdr->sa, psessionEntry) != QDF_STATUS_SUCCESS) { pe_err("fail to send TPC Report Frame"); return; } @@ -1344,7 +1344,7 @@ err: qdf_mem_free(frm); } -static tSirRetStatus +static QDF_STATUS __lim_process_link_measurement_req(tpAniSirGlobal pMac, uint8_t *pRxPacketInfo, tpPESession psessionEntry) { @@ -1358,7 +1358,7 @@ __lim_process_link_measurement_req(tpAniSirGlobal pMac, uint8_t *pRxPacketInfo, frameLen = WMA_GET_RX_PAYLOAD_LEN(pRxPacketInfo); if (psessionEntry == NULL) { - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } /**Unpack the received frame */ @@ -1371,7 +1371,7 @@ __lim_process_link_measurement_req(tpAniSirGlobal pMac, uint8_t *pRxPacketInfo, nStatus, frameLen); QDF_TRACE_HEX_DUMP(QDF_MODULE_ID_PE, QDF_TRACE_LEVEL_ERROR, pBody, frameLen); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } else if (DOT11F_WARNED(nStatus)) { pe_debug("There were warnings while unpacking a Link Measure request (0x%08x, %d bytes):", nStatus, frameLen); @@ -1487,7 +1487,7 @@ static void __lim_process_sa_query_request_action_frame(tpAniSirGlobal pMac, if (lim_send_sa_query_response_frame(pMac, transId, pHdr->sa, - psessionEntry) != eSIR_SUCCESS) { + psessionEntry) != QDF_STATUS_SUCCESS) { pe_err("fail to send SA query response action frame"); return; } @@ -1990,7 +1990,7 @@ void lim_process_action_frame(tpAniSirGlobal mac_ctx, if (__lim_process_link_measurement_req( mac_ctx, (uint8_t *)rx_pkt_info, - session) == eSIR_SUCCESS) + session) == QDF_STATUS_SUCCESS) lim_update_last_processed_frame( &rrm_link_action_frm, rx_pkt_info); 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 03b3b6588e..3686401384 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 @@ -251,7 +251,7 @@ static bool lim_chk_assoc_req_parse_error(tpAniSirGlobal mac_ctx, uint8_t sub_type, uint8_t *frm_body, uint32_t frame_len) { - tSirRetStatus status; + QDF_STATUS status; if (sub_type == LIM_ASSOC) status = sir_convert_assoc_req_frame2_struct(mac_ctx, frm_body, @@ -260,7 +260,7 @@ static bool lim_chk_assoc_req_parse_error(tpAniSirGlobal mac_ctx, status = sir_convert_reassoc_req_frame2_struct(mac_ctx, frm_body, frame_len, assoc_req); - if (status == eSIR_SUCCESS) + if (status == QDF_STATUS_SUCCESS) return true; pe_warn("Assoc Req rejected: frame parsing error. source addr:" @@ -289,7 +289,7 @@ static bool lim_chk_capab(tpAniSirGlobal mac_ctx, tpSirMacMgmtHdr hdr, { uint16_t temp; - if (cfg_get_capability_info(mac_ctx, &temp, session) != eSIR_SUCCESS) { + if (cfg_get_capability_info(mac_ctx, &temp, session) != QDF_STATUS_SUCCESS) { pe_err("could not retrieve Capabilities"); return false; } @@ -558,7 +558,7 @@ static bool lim_check_11ax_basic_mcs(tpAniSirGlobal mac_ctx, rx_mcs = assoc_req->he_cap.rx_he_mcs_map_lt_80; tx_mcs = assoc_req->he_cap.tx_he_mcs_map_lt_80; sta_mcs = HE_INTERSECT_MCS(rx_mcs, tx_mcs); - if (eSIR_SUCCESS != wlan_cfg_get_int(mac_ctx, + if (QDF_STATUS_SUCCESS != wlan_cfg_get_int(mac_ctx, WNI_CFG_HE_OPS_BASIC_MCS_NSS, &val)) val = WNI_CFG_HE_OPS_BASIC_MCS_NSS_DEF; basic_mcs = (uint16_t)val; @@ -610,7 +610,7 @@ lim_process_for_spectrum_mgmt(tpAniSirGlobal mac_ctx, tpSirMacMgmtHdr hdr, uint8_t sub_type, tSirMacCapabilityInfo local_cap) { if (local_cap.spectrumMgt) { - tSirRetStatus status = eSIR_SUCCESS; + QDF_STATUS status = QDF_STATUS_SUCCESS; /* * If station is 11h capable, then it SHOULD send all mandatory * IEs in assoc request frame. Let us verify that @@ -641,7 +641,7 @@ lim_process_for_spectrum_mgmt(tpAniSirGlobal mac_ctx, tpSirMacMgmtHdr hdr, status = lim_is_dot11h_power_capabilities_in_range( mac_ctx, assoc_req, session); - if (eSIR_SUCCESS != status) { + if (QDF_STATUS_SUCCESS != status) { pe_warn("LIM Info: MinTxPower(STA) > MaxTxPower(AP) in %s Req from " MAC_ADDRESS_STR, (LIM_ASSOC == sub_type) ? @@ -650,7 +650,7 @@ lim_process_for_spectrum_mgmt(tpAniSirGlobal mac_ctx, tpSirMacMgmtHdr hdr, } status = lim_is_dot11h_supported_channels_valid( mac_ctx, assoc_req); - if (eSIR_SUCCESS != status) { + if (QDF_STATUS_SUCCESS != status) { pe_warn("LIM Info: wrong supported channels (STA) in %s Req from " MAC_ADDRESS_STR, (LIM_ASSOC == sub_type) ? @@ -737,7 +737,7 @@ static bool lim_chk_is_11b_sta_supported(tpAniSirGlobal mac_ctx, if (phy_mode == WNI_CFG_PHY_MODE_11G) { if (wlan_cfg_get_int(mac_ctx, WNI_CFG_11G_ONLY_POLICY, - &cfg_11g_only) != eSIR_SUCCESS) { + &cfg_11g_only) != QDF_STATUS_SUCCESS) { pe_err("couldn't get 11g-only flag"); return false; } @@ -828,7 +828,7 @@ static bool lim_chk_n_process_wpa_rsn_ie(tpAniSirGlobal mac_ctx, const uint8_t *wps_ie = NULL; tDot11fIEWPA dot11f_ie_wpa = {0}; tDot11fIERSN dot11f_ie_rsn = {0}; - tSirRetStatus status = eSIR_SUCCESS; + QDF_STATUS status = QDF_STATUS_SUCCESS; /* * Clear the buffers so that frame parser knows that there isn't a * previously decoded IE in these buffers @@ -878,7 +878,7 @@ static bool lim_chk_n_process_wpa_rsn_ie(tpAniSirGlobal mac_ctx, session, assoc_req->HTCaps.present, pmf_connection); - if (eSIR_SUCCESS != status) { + if (QDF_STATUS_SUCCESS != status) { pe_warn("Re/Assoc rejected from: " MAC_ADDRESS_STR, MAC_ADDR_ARRAY( hdr->sa)); @@ -948,7 +948,7 @@ static bool lim_chk_n_process_wpa_rsn_ie(tpAniSirGlobal mac_ctx, mac_ctx, dot11f_ie_wpa, session, assoc_req->HTCaps.present); - if (eSIR_SUCCESS != status) { + if (QDF_STATUS_SUCCESS != status) { pe_warn("Re/Assoc rejected from: " MAC_ADDRESS_STR, MAC_ADDR_ARRAY( @@ -1229,7 +1229,7 @@ static bool lim_chk_wmm(tpAniSirGlobal mac_ctx, tpSirMacMgmtHdr hdr, &(assoc_req->addtsReq), &(assoc_req->qosCapability), 0, false, NULL, &tspecIdx, session) != - eSIR_SUCCESS) { + QDF_STATUS_SUCCESS) { pe_warn("AdmitControl: TSPEC rejected"); lim_send_assoc_rsp_mgmt_frame(mac_ctx, eSIR_MAC_QAP_NO_BANDWIDTH_REASON, @@ -1240,7 +1240,7 @@ static bool lim_chk_wmm(tpAniSirGlobal mac_ctx, tpSirMacMgmtHdr hdr, return false; } } else if (lim_admit_control_add_sta(mac_ctx, hdr->sa, false) - != eSIR_SUCCESS) { + != QDF_STATUS_SUCCESS) { pe_warn("AdmitControl: Sta rejected"); lim_send_assoc_rsp_mgmt_frame(mac_ctx, eSIR_MAC_QAP_NO_BANDWIDTH_REASON, 1, @@ -1493,7 +1493,7 @@ static bool lim_update_sta_ds(tpAniSirGlobal mac_ctx, tpSirMacMgmtHdr hdr, &(assoc_req->extendedRates), assoc_req->HTCaps.supportedMCSSet, session, vht_caps, - &assoc_req->he_cap) != eSIR_SUCCESS) { + &assoc_req->he_cap) != QDF_STATUS_SUCCESS) { /* Could not update hash table entry at DPH with rateset */ pe_err("Couldn't update hash entry for aid: %d MacAddr: " MAC_ADDRESS_STR, @@ -1508,7 +1508,7 @@ static bool lim_update_sta_ds(tpAniSirGlobal mac_ctx, tpSirMacMgmtHdr hdr, session); pe_err("Delete dph hash entry"); if (dph_delete_hash_entry(mac_ctx, hdr->sa, sta_ds->assocId, - &session->dph.dphHashTable) != eSIR_SUCCESS) + &session->dph.dphHashTable) != QDF_STATUS_SUCCESS) pe_err("error deleting hash entry"); return false; } @@ -1585,7 +1585,7 @@ static bool lim_update_sta_ds(tpAniSirGlobal mac_ctx, tpSirMacMgmtHdr hdr, timer_id.fields.sessionId = session->peSessionId; timer_id.fields.peerIdx = peer_idx; if (wlan_cfg_get_int(mac_ctx, WNI_CFG_PMF_SA_QUERY_RETRY_INTERVAL, - &retry_interval) != eSIR_SUCCESS) { + &retry_interval) != QDF_STATUS_SUCCESS) { pe_err("Couldn't get PMF SA Query retry interval value"); lim_reject_association(mac_ctx, hdr->sa, sub_type, true, auth_type, peer_idx, false, @@ -1659,7 +1659,7 @@ static bool lim_update_sta_ctx(tpAniSirGlobal mac_ctx, tpPESession session, * BTAMP: Add STA context at HW - issue WMA_ADD_STA_REQ to HAL */ if (lim_add_sta(mac_ctx, sta_ds, false, session) != - eSIR_SUCCESS) { + QDF_STATUS_SUCCESS) { pe_err("could not Add STA with assocId: %d", sta_ds->assocId); lim_reject_association(mac_ctx, sta_ds->staAddr, @@ -1690,7 +1690,7 @@ static bool lim_update_sta_ctx(tpAniSirGlobal mac_ctx, tpPESession session, sta_ds->mlmStaContext.mlmState = eLIM_MLM_WT_ASSOC_DEL_STA_RSP_STATE; if (lim_del_sta(mac_ctx, sta_ds, true, session) - != eSIR_SUCCESS) { + != QDF_STATUS_SUCCESS) { pe_err("Couldn't DEL STA, assocId: %d staId: %d", sta_ds->assocId, sta_ds->staIndex); lim_reject_association(mac_ctx, sta_ds->staAddr, @@ -1713,7 +1713,7 @@ static bool lim_update_sta_ctx(tpAniSirGlobal mac_ctx, tpPESession session, * same AID, already allocated */ if (lim_add_sta(mac_ctx, sta_ds, false, session) - != eSIR_SUCCESS) { + != QDF_STATUS_SUCCESS) { pe_err("UPASD not supported, REASSOC Failed"); lim_reject_association(mac_ctx, sta_ds->staAddr, sta_ds->mlmStaContext.subType, true, @@ -1888,7 +1888,7 @@ void lim_process_assoc_req_frame(tpAniSirGlobal mac_ctx, uint8_t *rx_pkt_info, * STA might have missed the assoc response, so it is * sending assoc request frame again. */ - lim_send_assoc_rsp_mgmt_frame(mac_ctx, eSIR_SUCCESS, + lim_send_assoc_rsp_mgmt_frame(mac_ctx, QDF_STATUS_SUCCESS, sta_ds->assocId, sta_ds->staAddr, sub_type, sta_ds, session); @@ -2452,7 +2452,7 @@ void lim_send_mlm_assoc_ind(tpAniSirGlobal mac_ctx, if (assoc_req->wmeInfoPresent) { if (wlan_cfg_get_int (mac_ctx, (uint16_t) WNI_CFG_WME_ENABLED, &tmp) - != eSIR_SUCCESS) + != QDF_STATUS_SUCCESS) pe_err("wlan_cfg_get_int failed for id: %d", WNI_CFG_WME_ENABLED); diff --git a/core/mac/src/pe/lim/lim_process_assoc_rsp_frame.c b/core/mac/src/pe/lim/lim_process_assoc_rsp_frame.c index 9b2caa1255..3c7d1dfd5a 100644 --- a/core/mac/src/pe/lim/lim_process_assoc_rsp_frame.c +++ b/core/mac/src/pe/lim/lim_process_assoc_rsp_frame.c @@ -44,7 +44,7 @@ #include "lim_send_messages.h" #include "lim_process_fils.h" -extern tSirRetStatus sch_beacon_edca_process(tpAniSirGlobal pMac, +extern QDF_STATUS sch_beacon_edca_process(tpAniSirGlobal pMac, tSirMacEdcaParamSetIE *edca, tpPESession psessionEntry); /** @@ -198,7 +198,7 @@ void lim_update_assoc_sta_datas(tpAniSirGlobal mac_ctx, if (lim_populate_peer_rate_set(mac_ctx, &sta_ds->supportedRates, assoc_rsp->HTCaps.supportedMCSSet, false, session_entry, - vht_caps, he_cap) != eSIR_SUCCESS) { + vht_caps, he_cap) != QDF_STATUS_SUCCESS) { pe_err("could not get rateset and extended rate set"); return; } @@ -218,14 +218,14 @@ void lim_update_assoc_sta_datas(tpAniSirGlobal mac_ctx, /* update TSID to UP mapping */ if (qos_mode) { if (assoc_rsp->edcaPresent) { - tSirRetStatus status; + QDF_STATUS status; status = sch_beacon_edca_process(mac_ctx, &assoc_rsp->edca, session_entry); pe_debug("Edca set update based on AssocRsp: status %d", status); - if (status != eSIR_SUCCESS) { + if (status != QDF_STATUS_SUCCESS) { pe_err("Edca error in AssocResp"); } else { /* update default tidmap based on ACM */ @@ -238,14 +238,14 @@ void lim_update_assoc_sta_datas(tpAniSirGlobal mac_ctx, sta_ds->wmeEnabled = 0; sta_ds->wsmEnabled = 0; if (session_entry->limWmeEnabled && assoc_rsp->wmeEdcaPresent) { - tSirRetStatus status; + QDF_STATUS status; status = sch_beacon_edca_process(mac_ctx, &assoc_rsp->edca, session_entry); pe_debug("WME Edca set update based on AssocRsp: status %d", status); - if (status != eSIR_SUCCESS) + if (status != QDF_STATUS_SUCCESS) pe_err("WME Edca error in AssocResp - ignoring"); else { @@ -623,7 +623,7 @@ lim_process_assoc_rsp_frame(tpAniSirGlobal mac_ctx, body = WMA_GET_RX_MPDU_DATA(rx_pkt_info); /* parse Re/Association Response frame. */ if (sir_convert_assoc_resp_frame2_struct(mac_ctx, session_entry, body, - frame_len, assoc_rsp) == eSIR_FAILURE) { + frame_len, assoc_rsp) == QDF_STATUS_E_FAILURE) { qdf_mem_free(assoc_rsp); pe_err("Parse error Assoc resp subtype: %d" "length: %d", frame_len, subtype); @@ -697,7 +697,7 @@ lim_process_assoc_rsp_frame(tpAniSirGlobal mac_ctx, } if (cfg_get_capability_info(mac_ctx, &caps, session_entry) - != eSIR_SUCCESS) { + != QDF_STATUS_SUCCESS) { qdf_mem_free(assoc_rsp); qdf_mem_free(beacon); pe_err("could not retrieve Capabilities"); @@ -841,7 +841,7 @@ lim_process_assoc_rsp_frame(tpAniSirGlobal mac_ctx, (mac_ctx, eSIR_LINK_POSTASSOC_STATE, session_entry->bssId, session_entry->selfMacAddr, NULL, - NULL) != eSIR_SUCCESS) { + NULL) != QDF_STATUS_SUCCESS) { pe_err("Set link state to POSTASSOC failed"); qdf_mem_free(beacon); qdf_mem_free(assoc_rsp); @@ -860,8 +860,8 @@ lim_process_assoc_rsp_frame(tpAniSirGlobal mac_ctx, &assoc_rsp->obss_scanparams); lim_diag_event_report(mac_ctx, WLAN_PE_DIAG_ROAM_ASSOC_COMP_EVENT, - session_entry, assoc_rsp->statusCode ? eSIR_FAILURE : - eSIR_SUCCESS, assoc_rsp->statusCode); + session_entry, assoc_rsp->statusCode ? QDF_STATUS_E_FAILURE : + QDF_STATUS_SUCCESS, assoc_rsp->statusCode); if (subtype == LIM_REASSOC) { pe_debug("Successfully Reassociated with BSS"); @@ -948,7 +948,7 @@ lim_process_assoc_rsp_frame(tpAniSirGlobal mac_ctx, session_entry->gUapsdPerAcTriggerEnableMask = 0; if (lim_cleanup_rx_path(mac_ctx, sta_ds, session_entry) - != eSIR_SUCCESS) { + != QDF_STATUS_SUCCESS) { pe_err("Could not cleanup the rx path"); goto assocReject; } @@ -1033,11 +1033,11 @@ lim_process_assoc_rsp_frame(tpAniSirGlobal mac_ctx, #ifdef FEATURE_WLAN_DIAG_SUPPORT lim_diag_event_report(mac_ctx, WLAN_PE_DIAG_CONNECTED, session_entry, - eSIR_SUCCESS, eSIR_SUCCESS); + QDF_STATUS_SUCCESS, QDF_STATUS_SUCCESS); #endif lim_update_stads_ext_cap(mac_ctx, session_entry, assoc_rsp, sta_ds); /* Update the BSS Entry, this entry was added during preassoc. */ - if (eSIR_SUCCESS == lim_sta_send_add_bss(mac_ctx, assoc_rsp, + if (QDF_STATUS_SUCCESS == lim_sta_send_add_bss(mac_ctx, assoc_rsp, beacon, &session_entry->pLimJoinReq->bssDescription, true, session_entry)) { diff --git a/core/mac/src/pe/lim/lim_process_auth_frame.c b/core/mac/src/pe/lim/lim_process_auth_frame.c index cd8ab6604b..66603d1e80 100644 --- a/core/mac/src/pe/lim/lim_process_auth_frame.c +++ b/core/mac/src/pe/lim/lim_process_auth_frame.c @@ -108,7 +108,7 @@ static void lim_process_auth_shared_system_algo(tpAniSirGlobal mac_ctx, if (LIM_IS_AP_ROLE(pe_session)) val = pe_session->privacy; else if (wlan_cfg_get_int(mac_ctx, - WNI_CFG_PRIVACY_ENABLED, &val) != eSIR_SUCCESS) + WNI_CFG_PRIVACY_ENABLED, &val) != QDF_STATUS_SUCCESS) pe_warn("couldnt retrieve Privacy option"); cfg_privacy_opt_imp = (uint8_t) val; if (!cfg_privacy_opt_imp) { @@ -457,7 +457,7 @@ static void lim_process_auth_frame_type1(tpAniSirGlobal mac_ctx, } } if (wlan_cfg_get_int(mac_ctx, WNI_CFG_MAX_NUM_PRE_AUTH, - (uint32_t *) &maxnum_preauth) != eSIR_SUCCESS) + (uint32_t *) &maxnum_preauth) != QDF_STATUS_SUCCESS) pe_warn("could not retrieve MaxNumPreAuth"); if (mac_ctx->lim.gLimNumPreAuthContexts == maxnum_preauth && @@ -719,7 +719,7 @@ static void lim_process_auth_frame_type2(tpAniSirGlobal mac_ctx, val = pe_session->privacy; else if (wlan_cfg_get_int(mac_ctx, WNI_CFG_PRIVACY_ENABLED, - &val) != eSIR_SUCCESS) + &val) != QDF_STATUS_SUCCESS) pe_warn("couldnt retrieve Privacy option"); cfg_privacy_opt_imp = (uint8_t) val; if (!cfg_privacy_opt_imp) { @@ -750,7 +750,7 @@ static void lim_process_auth_frame_type2(tpAniSirGlobal mac_ctx, return; } if (wlan_cfg_get_int(mac_ctx, WNI_CFG_WEP_DEFAULT_KEYID, - &val) != eSIR_SUCCESS) + &val) != QDF_STATUS_SUCCESS) pe_warn("could not retrieve Default key_id"); key_id = (uint8_t) val; val = SIR_MAC_KEY_LENGTH; @@ -761,7 +761,7 @@ static void lim_process_auth_frame_type2(tpAniSirGlobal mac_ctx, key_ptr->keyLength); } else if (wlan_cfg_get_str(mac_ctx, (uint16_t)(WNI_CFG_WEP_DEFAULT_KEY_1 + key_id), - defaultkey, &val) != eSIR_SUCCESS) { + defaultkey, &val) != QDF_STATUS_SUCCESS) { /* Couldnt get Default key from CFG. */ pe_warn("cant retrieve Defaultkey"); auth_frame->authAlgoNumber = @@ -1260,7 +1260,7 @@ lim_process_auth_frame(tpAniSirGlobal mac_ctx, uint8_t *rx_pkt_info, if (LIM_IS_AP_ROLE(pe_session)) { val = pe_session->privacy; } else if (wlan_cfg_get_int(mac_ctx, WNI_CFG_PRIVACY_ENABLED, - &val) != eSIR_SUCCESS) { + &val) != QDF_STATUS_SUCCESS) { /* * Accept Authentication frame only if Privacy is * implemented, if Could not get Privacy option @@ -1360,7 +1360,7 @@ lim_process_auth_frame(tpAniSirGlobal mac_ctx, uint8_t *rx_pkt_info, val = key_ptr->keyLength; } else if (wlan_cfg_get_str(mac_ctx, (uint16_t) (WNI_CFG_WEP_DEFAULT_KEY_1 + key_id), - defaultkey, &val) != eSIR_SUCCESS) { + defaultkey, &val) != QDF_STATUS_SUCCESS) { pe_warn("could not retrieve Default key"); /* @@ -1401,7 +1401,7 @@ lim_process_auth_frame(tpAniSirGlobal mac_ctx, uint8_t *rx_pkt_info, goto free; } if ((sir_convert_auth_frame2_struct(mac_ctx, plainbody, - frame_len - 8, rx_auth_frame) != eSIR_SUCCESS) + frame_len - 8, rx_auth_frame) != QDF_STATUS_SUCCESS) || (!is_auth_valid(mac_ctx, rx_auth_frame, pe_session))) { pe_err("failed to convert Auth Frame to structure or Auth is not valid"); @@ -1413,7 +1413,7 @@ lim_process_auth_frame(tpAniSirGlobal mac_ctx, uint8_t *rx_pkt_info, rx_pkt_info, pe_session); goto free; } else if ((sir_convert_auth_frame2_struct(mac_ctx, body_ptr, - frame_len, rx_auth_frame) != eSIR_SUCCESS) + frame_len, rx_auth_frame) != QDF_STATUS_SUCCESS) || (!is_auth_valid(mac_ctx, rx_auth_frame, pe_session))) { pe_err("failed to convert Auth Frame to structure or Auth is not valid"); @@ -1501,7 +1501,7 @@ free: * is received we will have a session in progress. !!!!! ***---------------------------------------------------------------------- */ -tSirRetStatus lim_process_auth_frame_no_session(tpAniSirGlobal pMac, uint8_t *pBd, +QDF_STATUS lim_process_auth_frame_no_session(tpAniSirGlobal pMac, uint8_t *pBd, void *body) { tpSirMacMgmtHdr pHdr; @@ -1510,7 +1510,7 @@ tSirRetStatus lim_process_auth_frame_no_session(tpAniSirGlobal pMac, uint8_t *pB uint16_t frameLen; tSirMacAuthFrameBody rxAuthFrame; tSirMacAuthFrameBody *pRxAuthFrameBody = NULL; - tSirRetStatus ret_status = eSIR_FAILURE; + QDF_STATUS ret_status = QDF_STATUS_E_FAILURE; int i; pHdr = WMA_GET_RX_MAC_HEADER(pBd); @@ -1538,18 +1538,18 @@ tSirRetStatus lim_process_auth_frame_no_session(tpAniSirGlobal pMac, uint8_t *pB if (psessionEntry == NULL) { pe_debug("cannot find session id in FT pre-auth phase"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } if (psessionEntry->ftPEContext.pFTPreAuthReq == NULL) { pe_err("Error: No FT"); /* No FT in progress. */ - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } if (frameLen == 0) { pe_err("Error: Frame len = 0"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } lim_print_mac_addr(pMac, pHdr->bssId, LOGD); lim_print_mac_addr(pMac, @@ -1567,7 +1567,7 @@ tSirRetStatus lim_process_auth_frame_no_session(tpAniSirGlobal pMac, uint8_t *pB pe_err("Error: Same bssid as preauth BSSID"); /* In this case SME if indeed has triggered a */ /* pre auth it will time out. */ - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } if (true == @@ -1585,14 +1585,14 @@ tSirRetStatus lim_process_auth_frame_no_session(tpAniSirGlobal pMac, uint8_t *pB * dropped without being forwarded to SME! However, it is * very unlikely to receive auth responses from the same * AP with different reason codes. - * NOTE: return eSIR_SUCCESS so that the packet is dropped + * NOTE: return QDF_STATUS_SUCCESS so that the packet is dropped * as this was indeed a response from the BSSID we tried to * pre-auth. */ pe_debug("Auth rsp already posted to SME" " (session %pK, FT session %pK)", psessionEntry, psessionEntry); - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } else { pe_warn("Auth rsp not yet posted to SME" " (session %pK, FT session %pK)", psessionEntry, @@ -1607,11 +1607,11 @@ tSirRetStatus lim_process_auth_frame_no_session(tpAniSirGlobal pMac, uint8_t *pB /* Save off the auth resp. */ if ((sir_convert_auth_frame2_struct(pMac, pBody, frameLen, &rxAuthFrame) != - eSIR_SUCCESS)) { + QDF_STATUS_SUCCESS)) { pe_err("failed to convert Auth frame to struct"); - lim_handle_ft_pre_auth_rsp(pMac, eSIR_FAILURE, NULL, 0, + lim_handle_ft_pre_auth_rsp(pMac, QDF_STATUS_E_FAILURE, NULL, 0, psessionEntry); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } pRxAuthFrameBody = &rxAuthFrame; @@ -1627,9 +1627,9 @@ tSirRetStatus lim_process_auth_frame_no_session(tpAniSirGlobal pMac, uint8_t *pB (uint32_t) pRxAuthFrameBody->authStatusCode); if (eSIR_MAC_MAX_ASSOC_STA_REACHED_STATUS == pRxAuthFrameBody->authStatusCode) - ret_status = eSIR_LIM_MAX_STA_REACHED_ERROR; + ret_status = QDF_STATUS_E_NOSPC; } else { - ret_status = eSIR_SUCCESS; + ret_status = QDF_STATUS_SUCCESS; } break; diff --git a/core/mac/src/pe/lim/lim_process_beacon_frame.c b/core/mac/src/pe/lim/lim_process_beacon_frame.c index 90938bd941..e049275eee 100644 --- a/core/mac/src/pe/lim/lim_process_beacon_frame.c +++ b/core/mac/src/pe/lim/lim_process_beacon_frame.c @@ -81,7 +81,7 @@ lim_process_beacon_frame(tpAniSirGlobal mac_ctx, uint8_t *rx_pkt_info, /* Parse received Beacon */ if (sir_convert_beacon_frame2_struct(mac_ctx, rx_pkt_info, bcn_ptr) != - eSIR_SUCCESS) { + QDF_STATUS_SUCCESS) { /* * Received wrongly formatted/invalid Beacon. * Ignore it and move on. diff --git a/core/mac/src/pe/lim/lim_process_cfg_updates.c b/core/mac/src/pe/lim/lim_process_cfg_updates.c index 43b54a815c..b1a05757a1 100644 --- a/core/mac/src/pe/lim/lim_process_cfg_updates.c +++ b/core/mac/src/pe/lim/lim_process_cfg_updates.c @@ -69,14 +69,14 @@ void lim_set_cfg_protection(tpAniSirGlobal pMac, tpPESession pesessionEntry) } } else { if (wlan_cfg_get_int(pMac, WNI_CFG_FORCE_POLICY_PROTECTION, &val) - != eSIR_SUCCESS) { + != QDF_STATUS_SUCCESS) { pe_err("reading WNI_CFG_FORCE_POLICY_PROTECTION cfg failed"); return; } else pMac->lim.gLimProtectionControl = (uint8_t) val; if (wlan_cfg_get_int(pMac, WNI_CFG_PROTECTION_ENABLED, &val) != - eSIR_SUCCESS) { + QDF_STATUS_SUCCESS) { pe_err("reading protection cfg failed"); return; } @@ -195,12 +195,12 @@ void lim_handle_cf_gparam_update(tpAniSirGlobal pMac, uint32_t cfgId) case WNI_CFG_MPDU_DENSITY: if (wlan_cfg_get_int(pMac, WNI_CFG_HT_AMPDU_PARAMS, &val1) != - eSIR_SUCCESS) { + QDF_STATUS_SUCCESS) { pe_err("could not retrieve HT AMPDU Param CFG"); break; } if (wlan_cfg_get_int(pMac, WNI_CFG_MPDU_DENSITY, &val2) != - eSIR_SUCCESS) { + QDF_STATUS_SUCCESS) { pe_err("could not retrieve MPDU Density CFG"); break; } @@ -209,17 +209,17 @@ void lim_handle_cf_gparam_update(tpAniSirGlobal pMac, uint32_t cfgId) pAmpduParamInfo->mpduDensity = (uint8_t) val2; if (cfg_set_int (pMac, WNI_CFG_HT_AMPDU_PARAMS, - *(uint8_t *) pAmpduParamInfo) != eSIR_SUCCESS) + *(uint8_t *) pAmpduParamInfo) != QDF_STATUS_SUCCESS) pe_err("could not update HT AMPDU Param CFG"); break; case WNI_CFG_MAX_RX_AMPDU_FACTOR: if (wlan_cfg_get_int(pMac, WNI_CFG_HT_AMPDU_PARAMS, &val1) != - eSIR_SUCCESS) { + QDF_STATUS_SUCCESS) { pe_err("could not retrieve HT AMPDU Param CFG"); break; } if (wlan_cfg_get_int(pMac, WNI_CFG_MAX_RX_AMPDU_FACTOR, &val2) != - eSIR_SUCCESS) { + QDF_STATUS_SUCCESS) { pe_err("could not retrieve AMPDU Factor CFG"); break; } @@ -228,13 +228,13 @@ void lim_handle_cf_gparam_update(tpAniSirGlobal pMac, uint32_t cfgId) pAmpduParamInfo->maxRxAMPDUFactor = (uint8_t) val2; if (cfg_set_int (pMac, WNI_CFG_HT_AMPDU_PARAMS, - *(uint8_t *) pAmpduParamInfo) != eSIR_SUCCESS) + *(uint8_t *) pAmpduParamInfo) != QDF_STATUS_SUCCESS) pe_err("could not update HT AMPDU Param CFG"); break; case WNI_CFG_DOT11_MODE: if (wlan_cfg_get_int(pMac, WNI_CFG_DOT11_MODE, &val1) != - eSIR_SUCCESS) { + QDF_STATUS_SUCCESS) { pe_err("could not retrieve Dot11 Mode CFG"); break; } @@ -242,7 +242,7 @@ void lim_handle_cf_gparam_update(tpAniSirGlobal pMac, uint32_t cfgId) case WNI_CFG_ASSOC_STA_LIMIT: if (wlan_cfg_get_int(pMac, WNI_CFG_ASSOC_STA_LIMIT, &val1) != - eSIR_SUCCESS) { + QDF_STATUS_SUCCESS) { pe_err("Unable to get WNI_CFG_ASSOC_STA_LIMIT"); break; } @@ -304,7 +304,7 @@ void lim_apply_configuration(tpAniSirGlobal pMac, tpPESession psessionEntry) } if (wlan_cfg_get_int(pMac, WNI_CFG_SCAN_IN_POWERSAVE, &val) != - eSIR_SUCCESS) { + QDF_STATUS_SUCCESS) { pe_err("could not retrieve WNI_CFG_SCAN_IN_POWERSAVE"); return; } @@ -331,7 +331,7 @@ static void lim_update_config(tpAniSirGlobal pMac, tpPESession psessionEntry) { uint32_t val; - if (wlan_cfg_get_int(pMac, WNI_CFG_SHORT_PREAMBLE, &val) != eSIR_SUCCESS) + if (wlan_cfg_get_int(pMac, WNI_CFG_SHORT_PREAMBLE, &val) != QDF_STATUS_SUCCESS) pe_err("cfg get short preamble failed"); psessionEntry->beaconParams.fShortPreamble = (val) ? 1 : 0; @@ -339,12 +339,12 @@ static void lim_update_config(tpAniSirGlobal pMac, tpPESession psessionEntry) if (LIM_IS_AP_ROLE(psessionEntry) || LIM_IS_IBSS_ROLE(psessionEntry)) { if (wlan_cfg_get_int(pMac, WNI_CFG_WME_ENABLED, &val) != - eSIR_SUCCESS) + QDF_STATUS_SUCCESS) pe_err("cfg get wme enabled failed"); psessionEntry->limWmeEnabled = (val) ? 1 : 0; } - if (wlan_cfg_get_int(pMac, WNI_CFG_WSM_ENABLED, &val) != eSIR_SUCCESS) + if (wlan_cfg_get_int(pMac, WNI_CFG_WSM_ENABLED, &val) != QDF_STATUS_SUCCESS) pe_err("cfg get wsm enabled failed"); psessionEntry->limWsmEnabled = (val) ? 1 : 0; @@ -355,11 +355,11 @@ static void lim_update_config(tpAniSirGlobal pMac, tpPESession psessionEntry) /* In STA , this parameter is filled during the join request */ if (LIM_IS_AP_ROLE(psessionEntry) || LIM_IS_IBSS_ROLE(psessionEntry)) { if (wlan_cfg_get_int(pMac, WNI_CFG_QOS_ENABLED, &val) != - eSIR_SUCCESS) + QDF_STATUS_SUCCESS) pe_err("cfg get qos enabled failed"); psessionEntry->limQosEnabled = (val) ? 1 : 0; } - if (wlan_cfg_get_int(pMac, WNI_CFG_HCF_ENABLED, &val) != eSIR_SUCCESS) + if (wlan_cfg_get_int(pMac, WNI_CFG_HCF_ENABLED, &val) != QDF_STATUS_SUCCESS) pe_err("cfg get hcf enabled failed"); psessionEntry->limHcfEnabled = (val) ? 1 : 0; @@ -368,11 +368,11 @@ static void lim_update_config(tpAniSirGlobal pMac, tpPESession psessionEntry) if (psessionEntry->limWsmEnabled && LIM_IS_AP_ROLE(psessionEntry)) psessionEntry->limHcfEnabled = 1; - if (wlan_cfg_get_int(pMac, WNI_CFG_11D_ENABLED, &val) != eSIR_SUCCESS) + if (wlan_cfg_get_int(pMac, WNI_CFG_11D_ENABLED, &val) != QDF_STATUS_SUCCESS) pe_err("cfg get 11d enabled failed"); psessionEntry->lim11dEnabled = (val) ? 1 : 0; - if (wlan_cfg_get_int(pMac, WNI_CFG_ASSOC_STA_LIMIT, &val) != eSIR_SUCCESS) { + if (wlan_cfg_get_int(pMac, WNI_CFG_ASSOC_STA_LIMIT, &val) != QDF_STATUS_SUCCESS) { pe_err("cfg get assoc sta limit failed"); } pMac->lim.gLimAssocStaLimit = (uint16_t) val; diff --git a/core/mac/src/pe/lim/lim_process_message_queue.c b/core/mac/src/pe/lim/lim_process_message_queue.c index 936a5a4548..7867bf3800 100644 --- a/core/mac/src/pe/lim/lim_process_message_queue.c +++ b/core/mac/src/pe/lim/lim_process_message_queue.c @@ -321,7 +321,7 @@ static void lim_process_set_default_scan_ie_request(tpAniSirGlobal mac_ctx, uint8_t *local_ie_buf; uint16_t local_ie_len; struct scheduler_msg msg_q = {0}; - tSirRetStatus ret_code; + QDF_STATUS ret_code; if (!msg_buf) { pe_err("msg_buf is NULL"); @@ -360,7 +360,7 @@ static void lim_process_set_default_scan_ie_request(tpAniSirGlobal mac_ctx, msg_q.bodyptr = wma_ie_params; msg_q.bodyval = 0; ret_code = wma_post_ctrl_msg(mac_ctx, &msg_q); - if (eSIR_SUCCESS != ret_code) { + if (QDF_STATUS_SUCCESS != ret_code) { pe_err("fail to send WMA_SET_IE_INFO"); qdf_mem_free(wma_ie_params); } @@ -648,7 +648,7 @@ __lim_process_ext_scan_beacon_probe_rsp(tpAniSirGlobal pmac, tSirProbeRespBeacon *frame; uint8_t *body; uint32_t frm_len; - tSirRetStatus status; + QDF_STATUS status; frm_len = WMA_GET_RX_PAYLOAD_LEN(rx_pkt_info); if (frm_len <= SIR_MAC_B_PR_SSID_OFFSET) { @@ -677,7 +677,7 @@ __lim_process_ext_scan_beacon_probe_rsp(tpAniSirGlobal pmac, return; } - if (status != eSIR_SUCCESS) { + if (status != QDF_STATUS_SUCCESS) { pe_err("Frame parsing failed"); qdf_mem_free(frame); return; @@ -813,7 +813,7 @@ static QDF_STATUS lim_allocate_and_get_bcn(tpAniSirGlobal mac_ctx, /* Convert the beacon frame into a structure */ if (sir_convert_beacon_frame2_struct(mac_ctx, (uint8_t *) rx_pkt_info, - bcn) != eSIR_SUCCESS) { + bcn) != QDF_STATUS_SUCCESS) { pe_err_rl("beacon parsing failed"); goto free; } @@ -1216,7 +1216,7 @@ lim_handle80211_frames(tpAniSirGlobal pMac, struct scheduler_msg *limMsg, lim_print_mac_addr(pMac, pHdr->bssId, LOGD); if (lim_process_auth_frame_no_session (pMac, pRxPacketInfo, - limMsg->bodyptr) == eSIR_SUCCESS) { + limMsg->bodyptr) == QDF_STATUS_SUCCESS) { goto end; } } @@ -1382,7 +1382,7 @@ lim_handle80211_frames(tpAniSirGlobal pMac, struct scheduler_msg *limMsg, if (lim_is_mgmt_frame_loggable(fc.type, fc.subType)) lim_diag_mgmt_rx_event_report(pMac, pHdr, psessionEntry, - eSIR_SUCCESS, eSIR_SUCCESS); + QDF_STATUS_SUCCESS, QDF_STATUS_SUCCESS); end: lim_pkt_free(pMac, TXRX_FRM_802_11_MGMT, pRxPacketInfo, (void *)limMsg->bodyptr); @@ -2229,7 +2229,7 @@ handle_ht_capabilityand_ht_info(struct sAniSirGlobal *pMac, uint8_t *ptr; if (wlan_cfg_get_int(pMac, WNI_CFG_HT_CAP_INFO, &cfgValue) != - eSIR_SUCCESS) { + QDF_STATUS_SUCCESS) { pe_err("Fail to retrieve WNI_CFG_HT_CAP_INFO value"); return; } @@ -2249,7 +2249,7 @@ handle_ht_capabilityand_ht_info(struct sAniSirGlobal *pMac, (uint8_t) macHTCapabilityInfo.dsssCckMode40MHz; if (wlan_cfg_get_int(pMac, WNI_CFG_HT_AMPDU_PARAMS, &cfgValue) != - eSIR_SUCCESS) { + QDF_STATUS_SUCCESS) { pe_err("Fail to retrieve WNI_CFG_HT_PARAM_INFO value"); return; } @@ -2261,7 +2261,7 @@ handle_ht_capabilityand_ht_info(struct sAniSirGlobal *pMac, /* Get HT IE Info */ if (wlan_cfg_get_int(pMac, WNI_CFG_HT_INFO_FIELD1, &cfgValue) != - eSIR_SUCCESS) { + QDF_STATUS_SUCCESS) { pe_err("Fail to retrieve WNI_CFG_HT_INFO_FIELD1 value"); return; } @@ -2274,7 +2274,7 @@ handle_ht_capabilityand_ht_info(struct sAniSirGlobal *pMac, pMac->lim.gHTRifsMode = (uint8_t) macHTInfoField1.rifsMode; if (wlan_cfg_get_int(pMac, WNI_CFG_HT_INFO_FIELD2, &cfgValue) != - eSIR_SUCCESS) { + QDF_STATUS_SUCCESS) { pe_err("Fail to retrieve WNI_CFG_HT_INFO_FIELD2 value"); return; } @@ -2283,7 +2283,7 @@ handle_ht_capabilityand_ht_info(struct sAniSirGlobal *pMac, pMac->lim.gHTOperMode = (tSirMacHTOperatingMode) macHTInfoField2.opMode; if (wlan_cfg_get_int(pMac, WNI_CFG_HT_INFO_FIELD3, &cfgValue) != - eSIR_SUCCESS) { + QDF_STATUS_SUCCESS) { pe_err("Fail to retrieve WNI_CFG_HT_INFO_FIELD3 value"); return; } diff --git a/core/mac/src/pe/lim/lim_process_mlm_host_roam.c b/core/mac/src/pe/lim/lim_process_mlm_host_roam.c index 1cec4877d4..586409b765 100644 --- a/core/mac/src/pe/lim/lim_process_mlm_host_roam.c +++ b/core/mac/src/pe/lim/lim_process_mlm_host_roam.c @@ -523,7 +523,7 @@ void lim_process_sta_mlm_add_bss_rsp_ft(tpAniSirGlobal pMac, } if (wlan_cfg_get_int(pMac, WNI_CFG_LISTEN_INTERVAL, &listenInterval) != - eSIR_SUCCESS) + QDF_STATUS_SUCCESS) pe_err("Couldn't get LISTEN_INTERVAL"); pAddStaParams->listenInterval = (uint16_t) listenInterval; @@ -594,7 +594,7 @@ void lim_process_mlm_ft_reassoc_req(tpAniSirGlobal pMac, uint32_t *pMsgBuf, uint16_t caps; uint32_t val; struct scheduler_msg msgQ = {0}; - tSirRetStatus retCode; + QDF_STATUS retCode; uint32_t teleBcnEn = 0; chanNum = psessionEntry->currentOperChannel; @@ -629,7 +629,7 @@ void lim_process_mlm_ft_reassoc_req(tpAniSirGlobal pMac, uint32_t *pMsgBuf, if (wlan_cfg_get_int(pMac, WNI_CFG_REASSOCIATION_FAILURE_TIMEOUT, (uint32_t *) &pMlmReassocReq->reassocFailureTimeout) - != eSIR_SUCCESS) { + != QDF_STATUS_SUCCESS) { /** * Could not get ReassocFailureTimeout value * from CFG. Log error. @@ -640,7 +640,7 @@ void lim_process_mlm_ft_reassoc_req(tpAniSirGlobal pMac, uint32_t *pMsgBuf, } if (cfg_get_capability_info(pMac, &caps, psessionEntry) != - eSIR_SUCCESS) { + QDF_STATUS_SUCCESS) { /** * Could not get Capabilities value * from CFG. Log error. @@ -663,7 +663,7 @@ void lim_process_mlm_ft_reassoc_req(tpAniSirGlobal pMac, uint32_t *pMsgBuf, to WNI_CFG_TELE_BCN_MAX_LI */ if (wlan_cfg_get_int(pMac, WNI_CFG_TELE_BCN_WAKEUP_EN, &teleBcnEn) != - eSIR_SUCCESS) { + QDF_STATUS_SUCCESS) { pe_err("Couldn't get WNI_CFG_TELE_BCN_WAKEUP_EN"); qdf_mem_free(pMlmReassocReq); return; @@ -671,7 +671,7 @@ void lim_process_mlm_ft_reassoc_req(tpAniSirGlobal pMac, uint32_t *pMsgBuf, if (teleBcnEn) { if (wlan_cfg_get_int(pMac, WNI_CFG_TELE_BCN_MAX_LI, &val) != - eSIR_SUCCESS) { + QDF_STATUS_SUCCESS) { /** * Could not get ListenInterval value * from CFG. Log error. @@ -682,7 +682,7 @@ void lim_process_mlm_ft_reassoc_req(tpAniSirGlobal pMac, uint32_t *pMsgBuf, } } else { if (wlan_cfg_get_int(pMac, WNI_CFG_LISTEN_INTERVAL, &val) != - eSIR_SUCCESS) { + QDF_STATUS_SUCCESS) { /** * Could not get ListenInterval value * from CFG. Log error. @@ -694,7 +694,7 @@ void lim_process_mlm_ft_reassoc_req(tpAniSirGlobal pMac, uint32_t *pMsgBuf, } if (lim_set_link_state (pMac, eSIR_LINK_PREASSOC_STATE, psessionEntry->bssId, - psessionEntry->selfMacAddr, NULL, NULL) != eSIR_SUCCESS) { + psessionEntry->selfMacAddr, NULL, NULL) != QDF_STATUS_SUCCESS) { qdf_mem_free(pMlmReassocReq); return; } @@ -713,7 +713,7 @@ void lim_process_mlm_ft_reassoc_req(tpAniSirGlobal pMac, uint32_t *pMsgBuf, pe_debug("Sending SIR_HAL_ADD_BSS_REQ"); MTRACE(mac_trace_msg_tx(pMac, psessionEntry->peSessionId, msgQ.type)); retCode = wma_post_ctrl_msg(pMac, &msgQ); - if (eSIR_SUCCESS != retCode) { + if (QDF_STATUS_SUCCESS != retCode) { qdf_mem_free(psessionEntry->ftPEContext.pAddBssReq); pe_err("Posting ADD_BSS_REQ to HAL failed, reason: %X", retCode); 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 a0e4f6400e..f9897a974e 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 @@ -234,11 +234,11 @@ void lim_covert_channel_scan_type(tpAniSirGlobal mac_ctx, uint8_t chan_num, uint32_t i; uint8_t chan_pair[WNI_CFG_SCAN_CONTROL_LIST_LEN]; uint32_t len = WNI_CFG_SCAN_CONTROL_LIST_LEN; - tSirRetStatus status; + QDF_STATUS status; status = wlan_cfg_get_str(mac_ctx, WNI_CFG_SCAN_CONTROL_LIST, chan_pair, &len); - if (eSIR_SUCCESS != status) { + if (QDF_STATUS_SUCCESS != status) { pe_err("Unable to get scan control list"); return; } @@ -349,12 +349,12 @@ static void mlm_add_sta(tpAniSirGlobal mac_ctx, tpAddStaParams sta_param, /* Configuration related parameters to be changed to support BT-AMP */ - if (eSIR_SUCCESS != wlan_cfg_get_int(mac_ctx, WNI_CFG_LISTEN_INTERVAL, + if (QDF_STATUS_SUCCESS != wlan_cfg_get_int(mac_ctx, WNI_CFG_LISTEN_INTERVAL, &val)) pe_warn("Couldn't get LISTEN_INTERVAL"); sta_param->listenInterval = (uint16_t) val; - if (eSIR_SUCCESS != wlan_cfg_get_int(mac_ctx, WNI_CFG_SHORT_PREAMBLE, + if (QDF_STATUS_SUCCESS != wlan_cfg_get_int(mac_ctx, WNI_CFG_SHORT_PREAMBLE, &val)) pe_warn("Couldn't get SHORT_PREAMBLE"); sta_param->shortPreambleSupported = (uint8_t) val; @@ -427,7 +427,7 @@ static void mlm_add_sta(tpAniSirGlobal mac_ctx, tpAddStaParams sta_param, */ if (IS_DOT11_MODE_VHT(self_dot11mode)) { val = 0; /* Default 8K AMPDU size */ - if (eSIR_SUCCESS != wlan_cfg_get_int(mac_ctx, + if (QDF_STATUS_SUCCESS != wlan_cfg_get_int(mac_ctx, WNI_CFG_VHT_AMPDU_LEN_EXPONENT, &val)) pe_err("Couldn't get WNI_CFG_VHT_AMPDU_LEN_EXPONENT"); sta_param->maxAmpduSize = (uint8_t) val; @@ -638,7 +638,7 @@ lim_mlm_add_bss(tpAniSirGlobal mac_ctx, pe_debug("Sending WMA_ADD_BSS_REQ..."); retcode = wma_post_ctrl_msg(mac_ctx, &msg_buf); - if (eSIR_SUCCESS != retcode) { + if (QDF_STATUS_SUCCESS != retcode) { pe_err("Posting ADD_BSS_REQ to HAL failed, reason=%X", retcode); qdf_mem_free(addbss_param); @@ -824,7 +824,7 @@ lim_process_mlm_post_join_suspend_link(tpAniSirGlobal mac_ctx, session->pLimMlmJoinReq->bssDescription.bssId, session->selfMacAddr, lim_post_join_set_link_state_callback, - session) != eSIR_SUCCESS) { + session) != QDF_STATUS_SUCCESS) { pe_err("SessionId:%d lim_set_link_state to eSIR_LINK_PREASSOC_STATE Failed!!", session->peSessionId); lim_print_mac_addr(mac_ctx, @@ -1171,7 +1171,7 @@ static void lim_process_mlm_auth_req(tpAniSirGlobal mac_ctx, uint32_t *msg) goto end; } else { if (wlan_cfg_get_int(mac_ctx, WNI_CFG_MAX_NUM_PRE_AUTH, - (uint32_t *) &num_preauth_ctx) != eSIR_SUCCESS) + (uint32_t *) &num_preauth_ctx) != QDF_STATUS_SUCCESS) pe_warn("Could not retrieve NumPreAuthLimit from CFG"); if (mac_ctx->lim.gLimNumPreAuthContexts == num_preauth_ctx) { @@ -1200,7 +1200,7 @@ static void lim_process_mlm_auth_req(tpAniSirGlobal mac_ctx, uint32_t *msg) pe_debug("lim_process_mlm_auth_req_sae is successful"); lim_diag_event_report(mac_ctx, WLAN_PE_DIAG_AUTH_ALGO_NUM, - session, eSIR_SUCCESS, + session, QDF_STATUS_SUCCESS, eSIR_AUTH_TYPE_SAE); return; } @@ -1219,14 +1219,14 @@ static void lim_process_mlm_auth_req(tpAniSirGlobal mac_ctx, uint32_t *msg) (uint8_t) mac_ctx->lim.gpLimMlmAuthReq->authType; } lim_diag_event_report(mac_ctx, WLAN_PE_DIAG_AUTH_ALGO_NUM, session, - eSIR_SUCCESS, auth_frame_body.authAlgoNumber); + QDF_STATUS_SUCCESS, auth_frame_body.authAlgoNumber); /* Prepare & send Authentication frame */ auth_frame_body.authTransactionSeqNumber = SIR_MAC_AUTH_FRAME_1; auth_frame_body.authStatusCode = 0; #ifdef FEATURE_WLAN_DIAG_SUPPORT lim_diag_event_report(mac_ctx, WLAN_PE_DIAG_AUTH_START_EVENT, session, - eSIR_SUCCESS, auth_frame_body.authStatusCode); + QDF_STATUS_SUCCESS, auth_frame_body.authStatusCode); #endif mac_ctx->auth_ack_status = LIM_AUTH_ACK_NOT_RCD; lim_send_auth_mgmt_frame(mac_ctx, @@ -1557,7 +1557,7 @@ lim_process_mlm_disassoc_req_ntf(tpAniSirGlobal mac_ctx, /* Disassoc frame is not sent OTA */ send_disassoc_frame = 1; /* Receive path cleanup with dummy packet */ - if (eSIR_SUCCESS != + if (QDF_STATUS_SUCCESS != lim_cleanup_rx_path(mac_ctx, stads, session)) { mlm_disassoccnf.resultCode = eSIR_SME_RESOURCES_UNAVAILABLE; 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 36bbb7876c..7a4c638d48 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 @@ -293,7 +293,7 @@ void lim_process_mlm_join_cnf(tpAniSirGlobal mac_ctx, join_cnf->sessionId); /* Setup hardware upfront */ if (lim_sta_send_add_bss_pre_assoc(mac_ctx, false, - session_entry) == eSIR_SUCCESS) + session_entry) == QDF_STATUS_SUCCESS) return; else result_code = eSIR_SME_REFUSED; @@ -354,13 +354,13 @@ static void lim_send_mlm_assoc_req(tpAniSirGlobal mac_ctx, sir_copy_mac_addr(assoc_req->peerMacAddr, session_entry->bssId); if (wlan_cfg_get_int(mac_ctx, WNI_CFG_ASSOCIATION_FAILURE_TIMEOUT, (uint32_t *) &assoc_req->assocFailureTimeout) - != eSIR_SUCCESS) { + != QDF_STATUS_SUCCESS) { /* Could not get AssocFailureTimeout value from CFG.*/ pe_err("could not retrieve AssocFailureTimeout value"); } if (cfg_get_capability_info(mac_ctx, &caps, session_entry) - != eSIR_SUCCESS) + != QDF_STATUS_SUCCESS) /* Could not get Capabilities value from CFG.*/ pe_err("could not retrieve Capabilities value"); @@ -404,22 +404,22 @@ static void lim_send_mlm_assoc_req(tpAniSirGlobal mac_ctx, * WNI_CFG_TELE_BCN_MAX_LI */ if (wlan_cfg_get_int(mac_ctx, WNI_CFG_TELE_BCN_WAKEUP_EN, &tele_bcn) - != eSIR_SUCCESS) + != QDF_STATUS_SUCCESS) pe_err("Couldn't get WNI_CFG_TELE_BCN_WAKEUP_EN"); val = WNI_CFG_LISTEN_INTERVAL_STADEF; if (tele_bcn) { if (wlan_cfg_get_int(mac_ctx, WNI_CFG_TELE_BCN_MAX_LI, &val) != - eSIR_SUCCESS) + QDF_STATUS_SUCCESS) pe_err("could not retrieve ListenInterval"); } else { if (wlan_cfg_get_int(mac_ctx, WNI_CFG_LISTEN_INTERVAL, - &val) != eSIR_SUCCESS) + &val) != QDF_STATUS_SUCCESS) pe_err("could not retrieve ListenInterval"); } #ifdef FEATURE_WLAN_DIAG_SUPPORT lim_diag_event_report(mac_ctx, WLAN_PE_DIAG_ASSOC_REQ_EVENT, - session_entry, eSIR_SUCCESS, eSIR_SUCCESS); + session_entry, QDF_STATUS_SUCCESS, QDF_STATUS_SUCCESS); #endif assoc_req->listenInterval = (uint16_t) val; /* Update PE session ID */ @@ -523,7 +523,7 @@ void lim_process_mlm_auth_cnf(tpAniSirGlobal mac_ctx, uint32_t *msg) */ if (session_entry->limSmeState == eLIM_SME_WT_AUTH_STATE) { if (wlan_cfg_get_int(mac_ctx, WNI_CFG_AUTHENTICATION_TYPE, - (uint32_t *) &auth_type) != eSIR_SUCCESS) { + (uint32_t *) &auth_type) != QDF_STATUS_SUCCESS) { pe_err("Fail to retrieve AuthType value"); } } else { @@ -562,7 +562,7 @@ void lim_process_mlm_auth_cnf(tpAniSirGlobal mac_ctx, uint32_t *msg) if (wlan_cfg_get_int(mac_ctx, WNI_CFG_AUTHENTICATE_FAILURE_TIMEOUT, (uint32_t *) &auth_req->authFailureTimeout) - != eSIR_SUCCESS) { + != QDF_STATUS_SUCCESS) { pe_err("Fail:retrieve AuthFailureTimeout"); } lim_post_mlm_message(mac_ctx, LIM_MLM_AUTH_REQ, @@ -1378,7 +1378,7 @@ error: if (lim_set_link_state (mac_ctx, eSIR_LINK_DOWN_STATE, session_entry->bssId, session_entry->selfMacAddr, lim_join_result_callback, - param) != eSIR_SUCCESS) { + param) != QDF_STATUS_SUCCESS) { qdf_mem_free(param); pe_err("Failed to set the LinkState"); } @@ -1588,7 +1588,7 @@ void lim_process_mlm_del_bss_rsp(tpAniSirGlobal pMac, #ifdef WLAN_FEATURE_11W if (psessionEntry->limRmfEnabled) { - if (eSIR_SUCCESS != + if (QDF_STATUS_SUCCESS != lim_send_exclude_unencrypt_ind(pMac, true, psessionEntry)) { pe_err("Could not send down Exclude Unencrypted Indication!"); } @@ -1616,7 +1616,7 @@ void lim_process_sta_mlm_del_bss_rsp(tpAniSirGlobal pMac, if (lim_set_link_state (pMac, eSIR_LINK_IDLE_STATE, psessionEntry->bssId, psessionEntry->selfMacAddr, NULL, - NULL) != eSIR_SUCCESS) { + NULL) != QDF_STATUS_SUCCESS) { pe_err("Failure in setting link state to IDLE"); statusCode = eSIR_SME_REFUSED; goto end; @@ -1669,7 +1669,7 @@ void lim_process_ap_mlm_del_bss_rsp(tpAniSirGlobal pMac, tpPESession psessionEntry) { tSirResultCodes rc = eSIR_SME_SUCCESS; - tSirRetStatus status; + QDF_STATUS status; tpDeleteBssParams pDelBss = (tpDeleteBssParams) limMsgQ->bodyptr; tSirMacAddr nullBssid = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00 }; @@ -1706,7 +1706,7 @@ void lim_process_ap_mlm_del_bss_rsp(tpAniSirGlobal pMac, } status = lim_set_link_state(pMac, eSIR_LINK_IDLE_STATE, nullBssid, psessionEntry->selfMacAddr, NULL, NULL); - if (status != eSIR_SUCCESS) { + if (status != QDF_STATUS_SUCCESS) { rc = eSIR_SME_REFUSED; goto end; } @@ -1848,7 +1848,7 @@ void lim_process_ap_mlm_del_sta_rsp(tpAniSirGlobal mac_ctx, qdf_mem_free(del_sta_params); msg->bodyptr = NULL; if (lim_add_sta(mac_ctx, sta_ds, false, session_entry) != - eSIR_SUCCESS) { + QDF_STATUS_SUCCESS) { pe_err("could not Add STA with assocId: %d", sta_ds->assocId); /* @@ -1858,7 +1858,7 @@ void lim_process_ap_mlm_del_sta_rsp(tpAniSirGlobal mac_ctx, if (sta_ds->qos.addtsPresent) { tpLimTspecInfo pTspecInfo; - if (eSIR_SUCCESS == + if (QDF_STATUS_SUCCESS == lim_tspec_find_by_assoc_id(mac_ctx, sta_ds->assocId, &sta_ds->qos.addts.tspec, @@ -2079,7 +2079,7 @@ static void lim_process_ap_mlm_add_bss_rsp(tpAniSirGlobal pMac, if (lim_set_link_state (pMac, eSIR_LINK_AP_STATE, psessionEntry->bssId, psessionEntry->selfMacAddr, NULL, - NULL) != eSIR_SUCCESS) + NULL) != QDF_STATUS_SUCCESS) goto end; /* Set MLME state */ psessionEntry->limMlmState = eLIM_MLM_BSS_STARTED_STATE; @@ -2210,7 +2210,7 @@ lim_process_ibss_mlm_add_bss_rsp(tpAniSirGlobal pMac, if (lim_set_link_state (pMac, eSIR_LINK_IBSS_STATE, psessionEntry->bssId, psessionEntry->selfMacAddr, NULL, - NULL) != eSIR_SUCCESS) + NULL) != QDF_STATUS_SUCCESS) goto end; /* Set MLME state */ psessionEntry->limMlmState = eLIM_MLM_BSS_STARTED_STATE; @@ -2323,7 +2323,7 @@ lim_process_sta_add_bss_rsp_pre_assoc(tpAniSirGlobal mac_ctx, pStaDs->staIndex = pAddBssParams->staContext.staIdx; /* Trigger Authentication with AP */ if (wlan_cfg_get_int(mac_ctx, WNI_CFG_AUTHENTICATION_TYPE, - (uint32_t *) &cfgAuthType) != eSIR_SUCCESS) { + (uint32_t *) &cfgAuthType) != QDF_STATUS_SUCCESS) { pe_warn("could not retrieve AuthType"); } /* Try shared Authentication first */ @@ -2346,7 +2346,7 @@ lim_process_sta_add_bss_rsp_pre_assoc(tpAniSirGlobal mac_ctx, if (wlan_cfg_get_int(mac_ctx, WNI_CFG_AUTHENTICATE_FAILURE_TIMEOUT, (uint32_t *) &pMlmAuthReq->authFailureTimeout) - != eSIR_SUCCESS) { + != QDF_STATUS_SUCCESS) { pe_warn("Fail: retrieve AuthFailureTimeout value"); } session_entry->limMlmState = eLIM_MLM_JOINED_STATE; @@ -2501,7 +2501,7 @@ lim_process_sta_mlm_add_bss_rsp(tpAniSirGlobal mac_ctx, rrm_cache_mgmt_tx_power(mac_ctx, add_bss_params->txMgmtPower, session_entry); if (lim_add_sta_self(mac_ctx, sta_idx, update_sta, - session_entry) != eSIR_SUCCESS) { + session_entry) != QDF_STATUS_SUCCESS) { /* Add STA context at HW */ pe_err("Session:%d could not Add Self" "Entry for the station", @@ -2530,7 +2530,7 @@ lim_process_sta_mlm_add_bss_rsp(tpAniSirGlobal mac_ctx, if (lim_set_link_state(mac_ctx, eSIR_LINK_IDLE_STATE, session_entry->bssId, session_entry->selfMacAddr, - NULL, NULL) != eSIR_SUCCESS) + NULL, NULL) != QDF_STATUS_SUCCESS) pe_err("Failed to set the LinkState"); /* Update PE session Id */ mlm_assoc_cnf.sessionId = session_entry->peSessionId; @@ -2633,7 +2633,7 @@ void lim_process_mlm_add_bss_rsp(tpAniSirGlobal mac_ctx, #ifdef WLAN_FEATURE_11W if (session_entry->limRmfEnabled) { - if (eSIR_SUCCESS != + if (QDF_STATUS_SUCCESS != lim_send_exclude_unencrypt_ind(mac_ctx, false, session_entry)) { pe_err("Failed to send Exclude Unencrypted Ind"); diff --git a/core/mac/src/pe/lim/lim_process_probe_req_frame.c b/core/mac/src/pe/lim/lim_process_probe_req_frame.c index 3ed8f98bb8..952218c886 100644 --- a/core/mac/src/pe/lim/lim_process_probe_req_frame.c +++ b/core/mac/src/pe/lim/lim_process_probe_req_frame.c @@ -378,7 +378,7 @@ lim_process_probe_req_frame(tpAniSirGlobal mac_ctx, uint8_t *rx_pkt_info, /* Parse Probe Request frame */ if (sir_convert_probe_req_frame2_struct(mac_ctx, body_ptr, - frame_len, &probe_req) == eSIR_FAILURE) { + frame_len, &probe_req) == QDF_STATUS_E_FAILURE) { pe_err("Parse error ProbeReq, length: %d, SA is: " MAC_ADDRESS_STR, frame_len, MAC_ADDR_ARRAY(mac_hdr->sa)); @@ -667,7 +667,7 @@ lim_send_sme_probe_req_ind(tpAniSirGlobal pMac, qdf_mem_copy(pSirSmeProbeReqInd->WPSPBCProbeReq.probeReqIE, pProbeReqIE, ProbeReqIELen); - if (lim_sys_process_mmh_msg_api(pMac, &msgQ, ePROT) != eSIR_SUCCESS) + if (lim_sys_process_mmh_msg_api(pMac, &msgQ, ePROT) != QDF_STATUS_SUCCESS) pe_err("couldnt send the probe req to hdd"); } /*** end lim_send_sme_probe_req_ind() ***/ diff --git a/core/mac/src/pe/lim/lim_process_probe_rsp_frame.c b/core/mac/src/pe/lim/lim_process_probe_rsp_frame.c index 4e8cd42985..e48faad10d 100644 --- a/core/mac/src/pe/lim/lim_process_probe_rsp_frame.c +++ b/core/mac/src/pe/lim/lim_process_probe_rsp_frame.c @@ -51,11 +51,11 @@ * * Return: 0 on success, one on failure */ -static tSirRetStatus +static QDF_STATUS lim_validate_ie_information_in_probe_rsp_frame(tpAniSirGlobal mac_ctx, uint8_t *pRxPacketInfo) { - tSirRetStatus status = eSIR_SUCCESS; + QDF_STATUS status = QDF_STATUS_SUCCESS; uint8_t *pframe; uint32_t nframe; uint32_t missing_rsn_bytes; @@ -68,7 +68,7 @@ lim_validate_ie_information_in_probe_rsp_frame(tpAniSirGlobal mac_ctx, if (WMA_GET_RX_PAYLOAD_LEN(pRxPacketInfo) < (SIR_MAC_B_PR_SSID_OFFSET + SIR_MAC_MIN_IE_LEN)) - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; pframe = WMA_GET_RX_MPDU_DATA(pRxPacketInfo); nframe = WMA_GET_RX_PAYLOAD_LEN(pRxPacketInfo); @@ -77,7 +77,7 @@ lim_validate_ie_information_in_probe_rsp_frame(tpAniSirGlobal mac_ctx, status = sir_validate_and_rectify_ies(mac_ctx, pframe, nframe, &missing_rsn_bytes); - if (status == eSIR_SUCCESS) + if (status == QDF_STATUS_SUCCESS) WMA_GET_RX_MPDU_LEN(pRxPacketInfo) += missing_rsn_bytes; return status; @@ -134,7 +134,7 @@ lim_process_probe_rsp_frame(tpAniSirGlobal mac_ctx, uint8_t *rx_Packet_info, /* Validate IE information before processing Probe Response Frame */ if (lim_validate_ie_information_in_probe_rsp_frame(mac_ctx, rx_Packet_info) != - eSIR_SUCCESS) { + QDF_STATUS_SUCCESS) { pe_err("Parse error ProbeResponse, length=%d", frame_len); qdf_mem_free(probe_rsp); return; @@ -150,7 +150,7 @@ lim_process_probe_rsp_frame(tpAniSirGlobal mac_ctx, uint8_t *rx_Packet_info, body = WMA_GET_RX_MPDU_DATA(rx_Packet_info); /* Enforce Mandatory IEs */ if ((sir_convert_probe_frame2_struct(mac_ctx, - body, frame_len, probe_rsp) == eSIR_FAILURE) || + body, frame_len, probe_rsp) == QDF_STATUS_E_FAILURE) || !probe_rsp->ssidPresent) { pe_err("Parse error ProbeResponse, length=%d", frame_len); qdf_mem_free(probe_rsp); @@ -261,7 +261,7 @@ lim_process_probe_rsp_frame(tpAniSirGlobal mac_ctx, uint8_t *rx_Packet_info, session_entry->gLimEdcaParamSetCount)) { if (sch_beacon_edca_process(mac_ctx, &probe_rsp->edcaParams, - session_entry) != eSIR_SUCCESS) { + session_entry) != QDF_STATUS_SUCCESS) { pe_err("EDCA param process error"); } else if (sta_ds != NULL) { /* 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 13a0630d94..0d746d6c23 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 @@ -474,7 +474,7 @@ static bool __lim_process_sme_sys_ready_ind(tpAniSirGlobal pMac, uint32_t *pMsgB pe_debug("sending WMA_SYS_READY_IND msg to HAL"); MTRACE(mac_trace_msg_tx(pMac, NO_SESSION, msg.type)); - if (eSIR_SUCCESS != wma_post_ctrl_msg(pMac, &msg)) { + if (QDF_STATUS_SUCCESS != wma_post_ctrl_msg(pMac, &msg)) { pe_err("wma_post_ctrl_msg failed"); return true; } @@ -566,7 +566,7 @@ __lim_handle_sme_start_bss_request(tpAniSirGlobal mac_ctx, uint32_t *msg_buf) { uint16_t size; uint32_t val = 0; - tSirRetStatus ret_status; + QDF_STATUS ret_status; tSirMacChanNum channel_number; tLimMlmStartReq *mlm_start_req = NULL; tpSirSmeStartBssReq sme_start_bss_req = NULL; @@ -579,7 +579,7 @@ __lim_handle_sme_start_bss_request(tpAniSirGlobal mac_ctx, uint32_t *msg_buf) uint16_t sme_transaction_id = 0xFF; uint32_t chanwidth; struct vdev_type_nss *vdev_type_nss; - tSirRetStatus cfg_get_wmi_dfs_master_param = eSIR_SUCCESS; + QDF_STATUS cfg_get_wmi_dfs_master_param = QDF_STATUS_SUCCESS; /* FEATURE_WLAN_DIAG_SUPPORT */ #ifdef FEATURE_WLAN_DIAG_SUPPORT_LIM @@ -929,7 +929,7 @@ __lim_handle_sme_start_bss_request(tpAniSirGlobal mac_ctx, uint32_t *msg_buf) ret_status = wlan_cfg_get_int(mac_ctx, WNI_CFG_IBSS_AUTO_BSSID, &auto_gen_bssid); - if (ret_status != eSIR_SUCCESS) { + if (ret_status != QDF_STATUS_SUCCESS) { pe_err("Get Auto Gen BSSID fail,Status: %d", ret_status); ret_code = eSIR_LOGE_EXCEPTION; @@ -984,18 +984,18 @@ __lim_handle_sme_start_bss_request(tpAniSirGlobal mac_ctx, uint32_t *msg_buf) } else { if (wlan_cfg_get_int(mac_ctx, - WNI_CFG_DTIM_PERIOD, &val) != eSIR_SUCCESS) + WNI_CFG_DTIM_PERIOD, &val) != QDF_STATUS_SUCCESS) pe_err("could not retrieve DTIM Period"); mlm_start_req->dtimPeriod = (uint8_t) val; } if (wlan_cfg_get_int(mac_ctx, WNI_CFG_CFP_PERIOD, &val) != - eSIR_SUCCESS) + QDF_STATUS_SUCCESS) pe_err("could not retrieve Beacon interval"); mlm_start_req->cfParamSet.cfpPeriod = (uint8_t) val; if (wlan_cfg_get_int(mac_ctx, WNI_CFG_CFP_MAX_DURATION, &val) != - eSIR_SUCCESS) + QDF_STATUS_SUCCESS) pe_err("could not retrieve CFPMaxDuration"); mlm_start_req->cfParamSet.cfpMaxDuration = (uint16_t) val; @@ -1027,7 +1027,7 @@ __lim_handle_sme_start_bss_request(tpAniSirGlobal mac_ctx, uint32_t *msg_buf) (CHAN_HOP_ALL_BANDS_ENABLE || BAND_5G == session->limRFBand)) { if (wlan_cfg_get_int(mac_ctx, - WNI_CFG_11H_ENABLED, &val) != eSIR_SUCCESS) + WNI_CFG_11H_ENABLED, &val) != QDF_STATUS_SUCCESS) pe_err("Fail to get WNI_CFG_11H_ENABLED"); else session->lim11hEnable = val; @@ -1041,7 +1041,7 @@ __lim_handle_sme_start_bss_request(tpAniSirGlobal mac_ctx, uint32_t *msg_buf) &val); session->lim11hEnable = val; } - if (cfg_get_wmi_dfs_master_param != eSIR_SUCCESS) + if (cfg_get_wmi_dfs_master_param != QDF_STATUS_SUCCESS) /* Failed get CFG WNI_CFG_DFS_MASTER_ENABLED */ pe_err("Get Fail, CFG DFS ENABLE"); } @@ -1049,7 +1049,7 @@ __lim_handle_sme_start_bss_request(tpAniSirGlobal mac_ctx, uint32_t *msg_buf) if (!session->lim11hEnable) { if (cfg_set_int(mac_ctx, WNI_CFG_LOCAL_POWER_CONSTRAINT, 0) != - eSIR_SUCCESS) + QDF_STATUS_SUCCESS) /* * Failed to set the CFG param * WNI_CFG_LOCAL_POWER_CONSTRAINT @@ -1567,7 +1567,7 @@ __lim_process_sme_join_req(tpAniSirGlobal mac_ctx, uint32_t *msg_buf) if (wlan_cfg_get_int(mac_ctx, WNI_CFG_JOIN_FAILURE_TIMEOUT, (uint32_t *) &mlm_join_req->joinFailureTimeout) != - eSIR_SUCCESS) { + QDF_STATUS_SUCCESS) { pe_err("couldn't retrieve JoinFailureTimer value" " setting to default value"); mlm_join_req->joinFailureTimeout = @@ -1658,7 +1658,7 @@ __lim_process_sme_join_req(tpAniSirGlobal mac_ctx, uint32_t *msg_buf) /* Initialize 11h Enable Flag */ if (BAND_5G == session->limRFBand) { if (wlan_cfg_get_int(mac_ctx, WNI_CFG_11H_ENABLED, - &val) != eSIR_SUCCESS) { + &val) != QDF_STATUS_SUCCESS) { pe_err("Fail to get WNI_CFG_11H_ENABLED"); session->lim11hEnable = WNI_CFG_11H_ENABLED_STADEF; @@ -1819,7 +1819,7 @@ static void __lim_process_sme_reassoc_req(tpAniSirGlobal mac_ctx, } #ifdef FEATURE_WLAN_DIAG_SUPPORT /* FEATURE_WLAN_DIAG_SUPPORT */ lim_diag_event_report(mac_ctx, WLAN_PE_DIAG_REASSOC_REQ_EVENT, - session_entry, eSIR_SUCCESS, eSIR_SUCCESS); + session_entry, QDF_STATUS_SUCCESS, QDF_STATUS_SUCCESS); #endif /* FEATURE_WLAN_DIAG_SUPPORT */ /* mac_ctx->lim.gpLimReassocReq = reassoc_req;//TO SUPPORT BT-AMP */ @@ -1955,11 +1955,11 @@ static void __lim_process_sme_reassoc_req(tpAniSirGlobal mac_ctx, if (wlan_cfg_get_int(mac_ctx, WNI_CFG_REASSOCIATION_FAILURE_TIMEOUT, (uint32_t *)&mlm_reassoc_req->reassocFailureTimeout) != - eSIR_SUCCESS) + QDF_STATUS_SUCCESS) pe_err("could not retrieve ReassocFailureTimeout value"); if (cfg_get_capability_info(mac_ctx, &caps, session_entry) != - eSIR_SUCCESS) + QDF_STATUS_SUCCESS) pe_err("could not retrieve Capabilities value"); lim_update_caps_info_for_bss(mac_ctx, &caps, @@ -1976,18 +1976,18 @@ static void __lim_process_sme_reassoc_req(tpAniSirGlobal mac_ctx, * WNI_CFG_TELE_BCN_MAX_LI */ if (wlan_cfg_get_int(mac_ctx, WNI_CFG_TELE_BCN_WAKEUP_EN, - &tele_bcn_en) != eSIR_SUCCESS) + &tele_bcn_en) != QDF_STATUS_SUCCESS) pe_err("Couldn't get WNI_CFG_TELE_BCN_WAKEUP_EN"); val = WNI_CFG_LISTEN_INTERVAL_STADEF; if (tele_bcn_en) { if (wlan_cfg_get_int(mac_ctx, WNI_CFG_TELE_BCN_MAX_LI, &val) != - eSIR_SUCCESS) + QDF_STATUS_SUCCESS) pe_err("could not retrieve ListenInterval"); } else { if (wlan_cfg_get_int(mac_ctx, WNI_CFG_LISTEN_INTERVAL, &val) != - eSIR_SUCCESS) + QDF_STATUS_SUCCESS) pe_err("could not retrieve ListenInterval"); } @@ -2903,7 +2903,7 @@ static void __lim_handle_sme_stop_bss_request(tpAniSirGlobal pMac, uint32_t *pMsgBuf) { tSirSmeStopBssReq stopBssReq; - tSirRetStatus status; + QDF_STATUS status; tLimSmeStates prevState; tpPESession psessionEntry; uint8_t smesessionId; @@ -3015,7 +3015,7 @@ __lim_handle_sme_stop_bss_request(tpAniSirGlobal pMac, uint32_t *pMsgBuf) if (NULL == pStaDs) continue; status = lim_del_sta(pMac, pStaDs, false, psessionEntry); - if (eSIR_SUCCESS == status) { + if (QDF_STATUS_SUCCESS == status) { lim_delete_dph_hash_entry(pMac, pStaDs->staAddr, pStaDs->assocId, psessionEntry); lim_release_peer_idx(pMac, pStaDs->assocId, psessionEntry); @@ -3027,7 +3027,7 @@ __lim_handle_sme_stop_bss_request(tpAniSirGlobal pMac, uint32_t *pMsgBuf) /* send a delBss to HAL and wait for a response */ status = lim_del_bss(pMac, NULL, psessionEntry->bssIdx, psessionEntry); - if (status != eSIR_SUCCESS) { + if (status != QDF_STATUS_SUCCESS) { pe_err("delBss failed for bss %d", psessionEntry->bssIdx); psessionEntry->limSmeState = prevState; @@ -3190,7 +3190,7 @@ void __lim_process_sme_assoc_cnf_new(tpAniSirGlobal mac_ctx, uint32_t msg_type, eLIM_MLM_LINK_ESTABLISHED_STATE; pe_debug("sending Assoc Rsp frame to STA (assoc id=%d)", sta_ds->assocId); - lim_send_assoc_rsp_mgmt_frame(mac_ctx, eSIR_SUCCESS, + lim_send_assoc_rsp_mgmt_frame(mac_ctx, QDF_STATUS_SUCCESS, sta_ds->assocId, sta_ds->staAddr, sta_ds->mlmStaContext.subType, sta_ds, session_entry); @@ -3252,7 +3252,7 @@ static void __lim_process_sme_addts_req(tpAniSirGlobal pMac, uint32_t *pMsgBuf) &sessionId); if (psessionEntry == NULL) { pe_err("Session Does not exist for given bssId"); - lim_send_sme_addts_rsp(pMac, pSirAddts->rspReqd, eSIR_FAILURE, + lim_send_sme_addts_rsp(pMac, pSirAddts->rspReqd, QDF_STATUS_E_FAILURE, NULL, pSirAddts->req.tspec, smesessionId, smetransactionId); return; @@ -3340,7 +3340,7 @@ static void __lim_process_sme_addts_req(tpAniSirGlobal pMac, uint32_t *pMsgBuf) if (pSirAddts->timeout) timeout = pSirAddts->timeout; else if (wlan_cfg_get_int(pMac, WNI_CFG_ADDTS_RSP_TIMEOUT, &timeout) != - eSIR_SUCCESS) { + QDF_STATUS_SUCCESS) { pe_debug("Unable to get Cfg param %d (Addts Rsp Timeout)", WNI_CFG_ADDTS_RSP_TIMEOUT); goto send_failure_addts_rsp; @@ -3373,7 +3373,7 @@ static void __lim_process_sme_addts_req(tpAniSirGlobal pMac, uint32_t *pMsgBuf) return; send_failure_addts_rsp: - lim_send_sme_addts_rsp(pMac, pSirAddts->rspReqd, eSIR_FAILURE, + lim_send_sme_addts_rsp(pMac, pSirAddts->rspReqd, QDF_STATUS_E_FAILURE, psessionEntry, pSirAddts->req.tspec, smesessionId, smetransactionId); } @@ -3387,7 +3387,7 @@ static void __lim_process_sme_delts_req(tpAniSirGlobal pMac, uint32_t *pMsgBuf) tpDphHashNode pStaDs = NULL; tpPESession psessionEntry; uint8_t sessionId; - uint32_t status = eSIR_SUCCESS; + uint32_t status = QDF_STATUS_SUCCESS; uint8_t smesessionId; uint16_t smetransactionId; @@ -3399,7 +3399,7 @@ static void __lim_process_sme_delts_req(tpAniSirGlobal pMac, uint32_t *pMsgBuf) &sessionId); if (psessionEntry == NULL) { pe_err("Session Does not exist for given bssId"); - status = eSIR_FAILURE; + status = QDF_STATUS_E_FAILURE; goto end; } #ifdef FEATURE_WLAN_DIAG_SUPPORT_LIM /* FEATURE_WLAN_DIAG_SUPPORT */ @@ -3407,11 +3407,11 @@ static void __lim_process_sme_delts_req(tpAniSirGlobal pMac, uint32_t *pMsgBuf) 0); #endif /* FEATURE_WLAN_DIAG_SUPPORT */ - if (eSIR_SUCCESS != + if (QDF_STATUS_SUCCESS != lim_validate_delts_req(pMac, pDeltsReq, peerMacAddr, psessionEntry)) { pe_err("lim_validate_delts_req failed"); - status = eSIR_FAILURE; - lim_send_sme_delts_rsp(pMac, pDeltsReq, eSIR_FAILURE, psessionEntry, + status = QDF_STATUS_E_FAILURE; + lim_send_sme_delts_rsp(pMac, pDeltsReq, QDF_STATUS_E_FAILURE, psessionEntry, smesessionId, smetransactionId); return; } @@ -3468,10 +3468,10 @@ static void __lim_process_sme_delts_req(tpAniSirGlobal pMac, uint32_t *pMsgBuf) if (pStaDs != NULL) { lim_send_edca_params(pMac, psessionEntry->gLimEdcaParamsActive, pStaDs->bssId, false); - status = eSIR_SUCCESS; + status = QDF_STATUS_SUCCESS; } else { pe_err("Self entry missing in Hash Table"); - status = eSIR_FAILURE; + status = QDF_STATUS_E_FAILURE; } #ifdef FEATURE_WLAN_ESE lim_send_sme_tsm_ie_ind(pMac, psessionEntry, 0, 0, 0); @@ -3479,7 +3479,7 @@ static void __lim_process_sme_delts_req(tpAniSirGlobal pMac, uint32_t *pMsgBuf) /* send an sme response back */ end: - lim_send_sme_delts_rsp(pMac, pDeltsReq, eSIR_SUCCESS, psessionEntry, + lim_send_sme_delts_rsp(pMac, pDeltsReq, QDF_STATUS_SUCCESS, psessionEntry, smesessionId, smetransactionId); } @@ -3551,7 +3551,7 @@ __lim_process_sme_get_statistics_request(tpAniSirGlobal pMac, uint32_t *pMsgBuf) msgQ.bodyval = 0; MTRACE(mac_trace_msg_tx(pMac, NO_SESSION, msgQ.type)); - if (eSIR_SUCCESS != (wma_post_ctrl_msg(pMac, &msgQ))) { + if (QDF_STATUS_SUCCESS != (wma_post_ctrl_msg(pMac, &msgQ))) { qdf_mem_free(pMsgBuf); pMsgBuf = NULL; pe_err("Unable to forward request"); @@ -3585,7 +3585,7 @@ __lim_process_sme_get_tsm_stats_request(tpAniSirGlobal pMac, uint32_t *pMsgBuf) msgQ.bodyval = 0; MTRACE(mac_trace_msg_tx(pMac, NO_SESSION, msgQ.type)); - if (eSIR_SUCCESS != (wma_post_ctrl_msg(pMac, &msgQ))) { + if (QDF_STATUS_SUCCESS != (wma_post_ctrl_msg(pMac, &msgQ))) { qdf_mem_free(pMsgBuf); pMsgBuf = NULL; pe_err("Unable to forward request"); @@ -3684,7 +3684,7 @@ lim_send_vdev_restart(tpAniSirGlobal pMac, { tpHalHiddenSsidVdevRestart pHalHiddenSsidVdevRestart = NULL; struct scheduler_msg msgQ = {0}; - tSirRetStatus retCode = eSIR_SUCCESS; + QDF_STATUS retCode = QDF_STATUS_SUCCESS; if (psessionEntry == NULL) { pe_err("Invalid parameters"); @@ -3707,7 +3707,7 @@ lim_send_vdev_restart(tpAniSirGlobal pMac, msgQ.bodyval = 0; retCode = wma_post_ctrl_msg(pMac, &msgQ); - if (eSIR_SUCCESS != retCode) { + if (QDF_STATUS_SUCCESS != retCode) { pe_err("wma_post_ctrl_msg() failed"); qdf_mem_free(pHalHiddenSsidVdevRestart); } @@ -3725,7 +3725,7 @@ static void __lim_process_roam_scan_offload_req(tpAniSirGlobal mac_ctx, { tpPESession pe_session; struct scheduler_msg wma_msg = {0}; - tSirRetStatus status; + QDF_STATUS status; tSirRoamOffloadScanReq *req_buffer; uint16_t local_ie_len; uint8_t *local_ie_buf; @@ -3762,7 +3762,7 @@ static void __lim_process_roam_scan_offload_req(tpAniSirGlobal mac_ctx, wma_msg.bodyptr = req_buffer; status = wma_post_ctrl_msg(mac_ctx, &wma_msg); - if (eSIR_SUCCESS != status) { + if (QDF_STATUS_SUCCESS != status) { pe_err("Posting WMA_ROAM_SCAN_OFFLOAD_REQ failed"); qdf_mem_free(req_buffer); } @@ -4052,23 +4052,23 @@ static void __lim_process_report_message(tpAniSirGlobal pMac, * @param pSessionEntry session entry. * @return None */ -tSirRetStatus +QDF_STATUS lim_send_set_max_tx_power_req(tpAniSirGlobal pMac, int8_t txPower, tpPESession pSessionEntry) { tpMaxTxPowerParams pMaxTxParams = NULL; - tSirRetStatus retCode = eSIR_SUCCESS; + QDF_STATUS retCode = QDF_STATUS_SUCCESS; struct scheduler_msg msgQ = {0}; if (pSessionEntry == NULL) { pe_err("Invalid parameters"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } pMaxTxParams = qdf_mem_malloc(sizeof(tMaxTxPowerParams)); if (NULL == pMaxTxParams) { pe_err("Unable to allocate memory for pMaxTxParams"); - return eSIR_MEM_ALLOC_FAILED; + return QDF_STATUS_E_NOMEM; } pMaxTxParams->power = txPower; @@ -4084,7 +4084,7 @@ lim_send_set_max_tx_power_req(tpAniSirGlobal pMac, int8_t txPower, pe_debug("Post WMA_SET_MAX_TX_POWER_REQ to WMA"); MTRACE(mac_trace_msg_tx(pMac, pSessionEntry->peSessionId, msgQ.type)); retCode = wma_post_ctrl_msg(pMac, &msgQ); - if (eSIR_SUCCESS != retCode) { + if (QDF_STATUS_SUCCESS != retCode) { pe_err("wma_post_ctrl_msg() failed"); qdf_mem_free(pMaxTxParams); } @@ -4248,7 +4248,7 @@ static void __lim_process_send_disassoc_frame(tpAniSirGlobal mac_ctx, uint32_t *msg_buf) { struct sme_send_disassoc_frm_req sme_send_disassoc_frame_req; - tSirRetStatus status; + QDF_STATUS status; tpPESession session_entry = NULL; uint8_t sme_session_id; uint16_t sme_trans_id; @@ -4265,7 +4265,7 @@ static void __lim_process_send_disassoc_frame(tpAniSirGlobal mac_ctx, &sme_send_disassoc_frame_req, (uint8_t *)msg_buf); - if ((eSIR_FAILURE == status) || + if ((QDF_STATUS_E_FAILURE == status) || (lim_is_group_addr(sme_send_disassoc_frame_req.peer_mac) && !lim_is_addr_bc(sme_send_disassoc_frame_req.peer_mac))) { pe_err("received invalid SME_DISASSOC_REQ message"); @@ -4311,7 +4311,7 @@ static void lim_set_pdev_ht_ie(tpAniSirGlobal mac_ctx, uint8_t pdev_id, { struct set_ie_param *ie_params; struct scheduler_msg msg = {0}; - tSirRetStatus rc = eSIR_SUCCESS; + QDF_STATUS rc = QDF_STATUS_SUCCESS; const uint8_t *p_ie = NULL; tHtCaps *p_ht_cap; int i; @@ -4357,7 +4357,7 @@ static void lim_set_pdev_ht_ie(tpAniSirGlobal mac_ctx, uint8_t pdev_id, msg.bodyval = 0; rc = wma_post_ctrl_msg(mac_ctx, &msg); - if (rc != eSIR_SUCCESS) { + if (rc != QDF_STATUS_SUCCESS) { pe_err("wma_post_ctrl_msg() return failure"); qdf_mem_free(ie_params->ie_ptr); qdf_mem_free(ie_params); @@ -4382,7 +4382,7 @@ static void lim_set_pdev_vht_ie(tpAniSirGlobal mac_ctx, uint8_t pdev_id, { struct set_ie_param *ie_params; struct scheduler_msg msg = {0}; - tSirRetStatus rc = eSIR_SUCCESS; + QDF_STATUS rc = QDF_STATUS_SUCCESS; const uint8_t *p_ie = NULL; tSirMacVHTCapabilityInfo *vht_cap; int i; @@ -4437,7 +4437,7 @@ static void lim_set_pdev_vht_ie(tpAniSirGlobal mac_ctx, uint8_t pdev_id, msg.bodyval = 0; rc = wma_post_ctrl_msg(mac_ctx, &msg); - if (rc != eSIR_SUCCESS) { + if (rc != QDF_STATUS_SUCCESS) { pe_err("wma_post_ctrl_msg failure"); qdf_mem_free(ie_params->ie_ptr); qdf_mem_free(ie_params); @@ -4943,7 +4943,7 @@ static void lim_process_sme_channel_change_request(tpAniSirGlobal mac_ctx, if (CHAN_HOP_ALL_BANDS_ENABLE || BAND_5G == session_entry->limRFBand) { if (wlan_cfg_get_int(mac_ctx, WNI_CFG_11H_ENABLED, &val) != - eSIR_SUCCESS) + QDF_STATUS_SUCCESS) pe_err("Fail to get WNI_CFG_11H_ENABLED"); } @@ -5580,7 +5580,7 @@ static void lim_process_sme_dfs_csa_ie_request(tpAniSirGlobal mac_ctx, skip_vht: /* Send CSA IE request from here */ if (sch_set_fixed_beacon_fields(mac_ctx, session_entry) != - eSIR_SUCCESS) { + QDF_STATUS_SUCCESS) { pe_err("Unable to set CSA IE in beacon"); return; } @@ -5704,7 +5704,7 @@ static void lim_process_nss_update_request(tpAniSirGlobal mac_ctx, /* Send nss update request from here */ if (sch_set_fixed_beacon_fields(mac_ctx, session_entry) != - eSIR_SUCCESS) { + QDF_STATUS_SUCCESS) { pe_err("Unable to set op mode IE in beacon"); return; } @@ -5791,7 +5791,7 @@ static void obss_color_collision_process_color_disable(tpAniSirGlobal mac_ctx, beacon_params.bss_color = session->he_op.bss_color; if (sch_set_fixed_beacon_fields(mac_ctx, session) != - eSIR_SUCCESS) { + QDF_STATUS_SUCCESS) { pe_err("Unable to set op mode IE in beacon"); return; } @@ -5938,7 +5938,7 @@ void lim_process_set_he_bss_color(tpAniSirGlobal mac_ctx, uint32_t *msg_buf) session_entry->bss_color_changing = 1; if (sch_set_fixed_beacon_fields(mac_ctx, session_entry) != - eSIR_SUCCESS) { + QDF_STATUS_SUCCESS) { pe_err("Unable to set op mode IE in beacon"); return; } diff --git a/core/mac/src/pe/lim/lim_process_tdls.c b/core/mac/src/pe/lim/lim_process_tdls.c index cdb9c83091..48ba41675a 100644 --- a/core/mac/src/pe/lim/lim_process_tdls.c +++ b/core/mac/src/pe/lim/lim_process_tdls.c @@ -83,7 +83,7 @@ #define MIN_VENDOR_SPECIFIC_IE_SIZE 5 #endif -static tSirRetStatus lim_tdls_setup_add_sta(tpAniSirGlobal pMac, +static QDF_STATUS lim_tdls_setup_add_sta(tpAniSirGlobal pMac, tSirTdlsAddStaReq * pAddStaReq, tpPESession psessionEntry); /* @@ -222,7 +222,7 @@ static void populate_dot11f_tdls_offchannel_params( uint8_t nss_5g; if (wlan_cfg_get_str(pMac, WNI_CFG_VALID_CHANNEL_LIST, - validChan, &numChans) != eSIR_SUCCESS) { + validChan, &numChans) != QDF_STATUS_SUCCESS) { /** * Could not get Valid channel list from CFG. * Log error. @@ -508,7 +508,7 @@ static QDF_STATUS lim_mgmt_tdls_tx_complete(void *context, * This function can be used for bacst or unicast discovery request * We are not differentiating it here, it will all depnds on peer MAC address, */ -static tSirRetStatus lim_send_tdls_dis_req_frame(tpAniSirGlobal pMac, +static QDF_STATUS lim_send_tdls_dis_req_frame(tpAniSirGlobal pMac, struct qdf_mac_addr peer_mac, uint8_t dialog, tpPESession psessionEntry, @@ -530,7 +530,7 @@ static tSirRetStatus lim_send_tdls_dis_req_frame(tpAniSirGlobal pMac, if (NULL == psessionEntry) { pe_err("psessionEntry is NULL"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } smeSessionId = psessionEntry->smeSessionId; /* @@ -602,7 +602,7 @@ static tSirRetStatus lim_send_tdls_dis_req_frame(tpAniSirGlobal pMac, if (!QDF_IS_STATUS_SUCCESS(qdf_status)) { pe_err("Failed to allocate: %d bytes for a TDLS Discovery Request", nBytes); - return eSIR_MEM_ALLOC_FAILED; + return QDF_STATUS_E_NOMEM; } /* zero out the memory */ @@ -628,7 +628,7 @@ static tSirRetStatus lim_send_tdls_dis_req_frame(tpAniSirGlobal pMac, pe_err("Failed to pack a TDLS discovery req (0x%08x)", status); cds_packet_free((void *)pPacket); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } else if (DOT11F_WARNED(status)) { pe_warn("There were warnings while packing TDLS Discovery Request (0x%08x)", status); @@ -662,8 +662,8 @@ static tSirRetStatus lim_send_tdls_dis_req_frame(tpAniSirGlobal pMac, pMac->lim.tdls_frm_session_id = psessionEntry->smeSessionId; lim_diag_mgmt_tx_event_report(pMac, (tpSirMacMgmtHdr) pFrame, - psessionEntry, eSIR_SUCCESS, - eSIR_SUCCESS); + psessionEntry, QDF_STATUS_SUCCESS, + QDF_STATUS_SUCCESS); qdf_status = wma_tx_frameWithTxComplete(pMac, pPacket, (uint16_t) nBytes, TXRX_FRM_802_11_DATA, @@ -677,10 +677,10 @@ static tSirRetStatus lim_send_tdls_dis_req_frame(tpAniSirGlobal pMac, if (!QDF_IS_STATUS_SUCCESS(qdf_status)) { pMac->lim.tdls_frm_session_id = NO_SESSION; pe_err("could not send TDLS Discovery Request frame"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } @@ -792,7 +792,7 @@ static void populate_dot11f_tdls_ht_vht_cap(tpAniSirGlobal pMac, * Send TDLS discovery response frame on direct link. */ -static tSirRetStatus lim_send_tdls_dis_rsp_frame(tpAniSirGlobal pMac, +static QDF_STATUS lim_send_tdls_dis_rsp_frame(tpAniSirGlobal pMac, struct qdf_mac_addr peer_mac, uint8_t dialog, tpPESession psessionEntry, @@ -817,7 +817,7 @@ static tSirRetStatus lim_send_tdls_dis_rsp_frame(tpAniSirGlobal pMac, if (NULL == psessionEntry) { pe_err("psessionEntry is NULL"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } smeSessionId = psessionEntry->smeSessionId; @@ -840,7 +840,7 @@ static tSirRetStatus lim_send_tdls_dis_rsp_frame(tpAniSirGlobal pMac, peer_mac, TDLS_RESPONDER); if (cfg_get_capability_info(pMac, &caps, psessionEntry) - != eSIR_SUCCESS) { + != QDF_STATUS_SUCCESS) { /* * Could not get Capabilities value * from CFG. Log error. @@ -850,7 +850,7 @@ static tSirRetStatus lim_send_tdls_dis_rsp_frame(tpAniSirGlobal pMac, swap_bit_field16(caps, (uint16_t *) &tdlsDisRsp.Capabilities); /* populate supported rate and ext supported rate IE */ - if (eSIR_FAILURE == populate_dot11f_rates_tdls(pMac, + if (QDF_STATUS_E_FAILURE == populate_dot11f_rates_tdls(pMac, &tdlsDisRsp.SuppRates, &tdlsDisRsp.ExtSuppRates, psessionEntry->currentOperChannel)) @@ -914,7 +914,7 @@ static tSirRetStatus lim_send_tdls_dis_rsp_frame(tpAniSirGlobal pMac, if (!QDF_IS_STATUS_SUCCESS(qdf_status)) { pe_err("Failed to allocate %d bytes for a TDLS Discovery Request", nBytes); - return eSIR_MEM_ALLOC_FAILED; + return QDF_STATUS_E_NOMEM; } /* zero out the memory */ @@ -948,7 +948,7 @@ static tSirRetStatus lim_send_tdls_dis_rsp_frame(tpAniSirGlobal pMac, pe_err("Failed to pack a TDLS discovery response (0x%08x)", status); cds_packet_free((void *)pPacket); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } else if (DOT11F_WARNED(status)) { pe_warn("There were warnings while packing TDLS Discovery Response (0x%08x)", status); @@ -966,8 +966,8 @@ static tSirRetStatus lim_send_tdls_dis_rsp_frame(tpAniSirGlobal pMac, pMac->lim.tdls_frm_session_id = psessionEntry->smeSessionId; lim_diag_mgmt_tx_event_report(pMac, (tpSirMacMgmtHdr) pFrame, - psessionEntry, eSIR_SUCCESS, - eSIR_SUCCESS); + psessionEntry, QDF_STATUS_SUCCESS, + QDF_STATUS_SUCCESS); /* * Transmit Discovery response and watch if this is delivered to * peer STA. @@ -988,10 +988,10 @@ static tSirRetStatus lim_send_tdls_dis_rsp_frame(tpAniSirGlobal pMac, if (!QDF_IS_STATUS_SUCCESS(qdf_status)) { pMac->lim.tdls_frm_session_id = NO_SESSION; pe_err("could not send TDLS Discovery Response frame!"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } @@ -1105,7 +1105,7 @@ void lim_set_tdls_flags(roam_offload_synch_ind *roam_sync_ind_ptr, * TDLS setup Request frame on AP link */ static -tSirRetStatus lim_send_tdls_link_setup_req_frame(tpAniSirGlobal pMac, +QDF_STATUS lim_send_tdls_link_setup_req_frame(tpAniSirGlobal pMac, struct qdf_mac_addr peer_mac, uint8_t dialog, tpPESession psessionEntry, @@ -1146,7 +1146,7 @@ tSirRetStatus lim_send_tdls_link_setup_req_frame(tpAniSirGlobal pMac, &tdlsSetupReq.LinkIdentifier, peer_mac, TDLS_INITIATOR); - if (cfg_get_capability_info(pMac, &caps, psessionEntry) != eSIR_SUCCESS) { + if (cfg_get_capability_info(pMac, &caps, psessionEntry) != QDF_STATUS_SUCCESS) { /* * Could not get Capabilities value * from CFG. Log error. @@ -1156,7 +1156,7 @@ tSirRetStatus lim_send_tdls_link_setup_req_frame(tpAniSirGlobal pMac, swap_bit_field16(caps, (uint16_t *) &tdlsSetupReq.Capabilities); /* populate supported rate and ext supported rate IE */ - if (eSIR_FAILURE == populate_dot11f_rates_tdls(pMac, + if (QDF_STATUS_E_FAILURE == populate_dot11f_rates_tdls(pMac, &tdlsSetupReq.SuppRates, &tdlsSetupReq.ExtSuppRates, psessionEntry->currentOperChannel)) @@ -1183,7 +1183,7 @@ tSirRetStatus lim_send_tdls_link_setup_req_frame(tpAniSirGlobal pMac, ((pMac->lim.gLimTDLSUapsdMask & 0x08) >> 3); if (wlan_cfg_get_int(pMac, WNI_CFG_MAX_SP_LENGTH, &val) != - eSIR_SUCCESS) + QDF_STATUS_SUCCESS) pe_warn("could not retrieve Max SP Length"); tdlsSetupReq.WMMInfoStation.max_sp_length = (uint8_t) val; @@ -1287,7 +1287,7 @@ tSirRetStatus lim_send_tdls_link_setup_req_frame(tpAniSirGlobal pMac, if (!QDF_IS_STATUS_SUCCESS(qdf_status)) { pe_err("Failed to allocate %d bytes for a TDLS Setup Request", nBytes); - return eSIR_MEM_ALLOC_FAILED; + return QDF_STATUS_E_NOMEM; } /* zero out the memory */ @@ -1319,7 +1319,7 @@ tSirRetStatus lim_send_tdls_link_setup_req_frame(tpAniSirGlobal pMac, pe_err("Failed to pack a TDLS Setup request (0x%08x)", status); cds_packet_free((void *)pPacket); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } else if (DOT11F_WARNED(status)) { pe_warn("There were warnings while packing TDLS Setup Request (0x%08x)", status); @@ -1342,8 +1342,8 @@ tSirRetStatus lim_send_tdls_link_setup_req_frame(tpAniSirGlobal pMac, pMac->lim.tdls_frm_session_id = psessionEntry->smeSessionId; lim_diag_mgmt_tx_event_report(pMac, (tpSirMacMgmtHdr) pFrame, - psessionEntry, eSIR_SUCCESS, - eSIR_SUCCESS); + psessionEntry, QDF_STATUS_SUCCESS, + QDF_STATUS_SUCCESS); qdf_status = wma_tx_frame_with_tx_complete_send(pMac, pPacket, (uint16_t) nBytes, @@ -1354,10 +1354,10 @@ tSirRetStatus lim_send_tdls_link_setup_req_frame(tpAniSirGlobal pMac, if (!QDF_IS_STATUS_SUCCESS(qdf_status)) { pMac->lim.tdls_frm_session_id = NO_SESSION; pe_err("could not send TDLS Setup Request frame!"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } @@ -1365,7 +1365,7 @@ tSirRetStatus lim_send_tdls_link_setup_req_frame(tpAniSirGlobal pMac, * Send TDLS Teardown frame on Direct link or AP link, depends on reason code. */ static -tSirRetStatus lim_send_tdls_teardown_frame(tpAniSirGlobal pMac, +QDF_STATUS lim_send_tdls_teardown_frame(tpAniSirGlobal pMac, struct qdf_mac_addr peer_mac, uint16_t reason, uint8_t responder, @@ -1392,7 +1392,7 @@ tSirRetStatus lim_send_tdls_teardown_frame(tpAniSirGlobal pMac, if (NULL == psessionEntry) { pe_err("psessionEntry is NULL"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } smeSessionId = psessionEntry->smeSessionId; /* @@ -1466,7 +1466,7 @@ tSirRetStatus lim_send_tdls_teardown_frame(tpAniSirGlobal pMac, if (!QDF_IS_STATUS_SUCCESS(qdf_status)) { pe_err("Failed to allocate %d bytes for a TDLS Teardown Frame.", nBytes); - return eSIR_MEM_ALLOC_FAILED; + return QDF_STATUS_E_NOMEM; } /* zero out the memory */ @@ -1494,7 +1494,7 @@ tSirRetStatus lim_send_tdls_teardown_frame(tpAniSirGlobal pMac, pe_err("Failed to pack a TDLS Teardown frame (0x%08x)", status); cds_packet_free((void *)pPacket); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } else if (DOT11F_WARNED(status)) { pe_warn("There were warnings while packing TDLS Teardown frame (0x%08x)", status); @@ -1535,8 +1535,8 @@ tSirRetStatus lim_send_tdls_teardown_frame(tpAniSirGlobal pMac, pMac->lim.tdls_frm_session_id = psessionEntry->smeSessionId; lim_diag_mgmt_tx_event_report(pMac, (tpSirMacMgmtHdr) pFrame, - psessionEntry, eSIR_SUCCESS, - eSIR_SUCCESS); + psessionEntry, QDF_STATUS_SUCCESS, + QDF_STATUS_SUCCESS); qdf_status = wma_tx_frame_with_tx_complete_send(pMac, pPacket, (uint16_t) nBytes, @@ -1549,17 +1549,17 @@ tSirRetStatus lim_send_tdls_teardown_frame(tpAniSirGlobal pMac, if (!QDF_IS_STATUS_SUCCESS(qdf_status)) { pMac->lim.tdls_frm_session_id = NO_SESSION; pe_err("could not send TDLS Teardown frame"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /* * Send Setup RSP frame on AP link. */ -static tSirRetStatus lim_send_tdls_setup_rsp_frame(tpAniSirGlobal pMac, +static QDF_STATUS lim_send_tdls_setup_rsp_frame(tpAniSirGlobal pMac, struct qdf_mac_addr peer_mac, uint8_t dialog, tpPESession psessionEntry, @@ -1587,7 +1587,7 @@ static tSirRetStatus lim_send_tdls_setup_rsp_frame(tpAniSirGlobal pMac, if (NULL == psessionEntry) { pe_err("psessionEntry is NULL"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } smeSessionId = psessionEntry->smeSessionId; @@ -1609,7 +1609,7 @@ static tSirRetStatus lim_send_tdls_setup_rsp_frame(tpAniSirGlobal pMac, &tdlsSetupRsp.LinkIdentifier, peer_mac, TDLS_RESPONDER); - if (cfg_get_capability_info(pMac, &caps, psessionEntry) != eSIR_SUCCESS) { + if (cfg_get_capability_info(pMac, &caps, psessionEntry) != QDF_STATUS_SUCCESS) { /* * Could not get Capabilities value * from CFG. Log error. @@ -1619,7 +1619,7 @@ static tSirRetStatus lim_send_tdls_setup_rsp_frame(tpAniSirGlobal pMac, swap_bit_field16(caps, (uint16_t *) &tdlsSetupRsp.Capabilities); /* populate supported rate and ext supported rate IE */ - if (eSIR_FAILURE == populate_dot11f_rates_tdls(pMac, + if (QDF_STATUS_E_FAILURE == populate_dot11f_rates_tdls(pMac, &tdlsSetupRsp.SuppRates, &tdlsSetupRsp.ExtSuppRates, psessionEntry->currentOperChannel)) @@ -1645,7 +1645,7 @@ static tSirRetStatus lim_send_tdls_setup_rsp_frame(tpAniSirGlobal pMac, tdlsSetupRsp.WMMInfoStation.acbe_uapsd = ((pMac->lim.gLimTDLSUapsdMask & 0x08) >> 3); if (wlan_cfg_get_int(pMac, WNI_CFG_MAX_SP_LENGTH, &val) != - eSIR_SUCCESS) + QDF_STATUS_SUCCESS) pe_warn("could not retrieve Max SP Length"); tdlsSetupRsp.WMMInfoStation.max_sp_length = (uint8_t) val; tdlsSetupRsp.WMMInfoStation.present = 1; @@ -1741,7 +1741,7 @@ static tSirRetStatus lim_send_tdls_setup_rsp_frame(tpAniSirGlobal pMac, if (!QDF_IS_STATUS_SUCCESS(qdf_status)) { pe_err("Failed to allocate %d bytes for a TDLS Setup Response", nBytes); - return eSIR_MEM_ALLOC_FAILED; + return QDF_STATUS_E_NOMEM; } /* zero out the memory */ @@ -1773,7 +1773,7 @@ static tSirRetStatus lim_send_tdls_setup_rsp_frame(tpAniSirGlobal pMac, pe_err("Failed to pack a TDLS Setup Response (0x%08x)", status); cds_packet_free((void *)pPacket); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } else if (DOT11F_WARNED(status)) { pe_warn("There were warnings while packing TDLS Setup Response (0x%08x)", status); @@ -1795,8 +1795,8 @@ static tSirRetStatus lim_send_tdls_setup_rsp_frame(tpAniSirGlobal pMac, pMac->lim.tdls_frm_session_id = psessionEntry->smeSessionId; lim_diag_mgmt_tx_event_report(pMac, (tpSirMacMgmtHdr) pFrame, - psessionEntry, eSIR_SUCCESS, - eSIR_SUCCESS); + psessionEntry, QDF_STATUS_SUCCESS, + QDF_STATUS_SUCCESS); qdf_status = wma_tx_frame_with_tx_complete_send(pMac, pPacket, (uint16_t) nBytes, @@ -1807,17 +1807,17 @@ static tSirRetStatus lim_send_tdls_setup_rsp_frame(tpAniSirGlobal pMac, if (!QDF_IS_STATUS_SUCCESS(qdf_status)) { pMac->lim.tdls_frm_session_id = NO_SESSION; pe_err("could not send TDLS Dis Request frame!"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /* * Send TDLS setup CNF frame on AP link */ static -tSirRetStatus lim_send_tdls_link_setup_cnf_frame(tpAniSirGlobal pMac, +QDF_STATUS lim_send_tdls_link_setup_cnf_frame(tpAniSirGlobal pMac, struct qdf_mac_addr peer_mac, uint8_t dialog, uint32_t peerCapability, @@ -1933,7 +1933,7 @@ tSirRetStatus lim_send_tdls_link_setup_cnf_frame(tpAniSirGlobal pMac, if (!QDF_IS_STATUS_SUCCESS(qdf_status)) { pe_err("Failed to allocate %d bytes for a TDLS Setup Confirm", nBytes); - return eSIR_MEM_ALLOC_FAILED; + return QDF_STATUS_E_NOMEM; } /* zero out the memory */ @@ -1959,7 +1959,7 @@ tSirRetStatus lim_send_tdls_link_setup_cnf_frame(tpAniSirGlobal pMac, if (DOT11F_FAILED(status)) { pe_err("Failed to pack a TDLS discovery req (0x%08x)", status); cds_packet_free((void *)pPacket); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } else if (DOT11F_WARNED(status)) { pe_warn("There were warnings while packing TDLS Discovery Request (0x%08x)", status); @@ -2002,8 +2002,8 @@ tSirRetStatus lim_send_tdls_link_setup_cnf_frame(tpAniSirGlobal pMac, pMac->lim.tdls_frm_session_id = psessionEntry->smeSessionId; lim_diag_mgmt_tx_event_report(pMac, (tpSirMacMgmtHdr) pFrame, - psessionEntry, eSIR_SUCCESS, - eSIR_SUCCESS); + psessionEntry, QDF_STATUS_SUCCESS, + QDF_STATUS_SUCCESS); qdf_status = wma_tx_frame_with_tx_complete_send(pMac, pPacket, (uint16_t) nBytes, @@ -2014,17 +2014,17 @@ tSirRetStatus lim_send_tdls_link_setup_cnf_frame(tpAniSirGlobal pMac, if (!QDF_IS_STATUS_SUCCESS(qdf_status)) { pMac->lim.tdls_frm_session_id = NO_SESSION; pe_err("could not send TDLS Setup Confirm frame"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /* This Function is similar to populate_dot11f_ht_caps, except that the HT Capabilities * are considered from the AddStaReq rather from the cfg.dat as in populate_dot11f_ht_caps */ -static tSirRetStatus lim_tdls_populate_dot11f_ht_caps(tpAniSirGlobal pMac, +static QDF_STATUS lim_tdls_populate_dot11f_ht_caps(tpAniSirGlobal pMac, tpPESession psessionEntry, tSirTdlsAddStaReq * pTdlsAddStaReq, @@ -2155,11 +2155,11 @@ static tSirRetStatus lim_tdls_populate_dot11f_ht_caps(tpAniSirGlobal pMac, pDot11f->present = pTdlsAddStaReq->htcap_present; - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } -static tSirRetStatus +static QDF_STATUS lim_tdls_populate_dot11f_vht_caps(tpAniSirGlobal pMac, tSirTdlsAddStaReq *pTdlsAddStaReq, tDot11fIEVHTCaps *pDot11f) @@ -2223,7 +2223,7 @@ lim_tdls_populate_dot11f_vht_caps(tpAniSirGlobal pMac, lim_log_vht_cap(pMac, pDot11f); - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } @@ -2243,9 +2243,9 @@ lim_tdls_populate_dot11f_vht_caps(tpAniSirGlobal pMac, * against the set of received supported rates. After the comparison station * entry's rates is populated with 11A rates and 11B rates. * - * Return: eSIR_SUCCESS on success, eSIR_FAILURE on failure. + * Return: QDF_STATUS_SUCCESS on success, QDF_STATUS_E_FAILURE on failure. */ -static tSirRetStatus +static QDF_STATUS lim_tdls_populate_matching_rate_set(tpAniSirGlobal mac_ctx, tpDphHashNode stads, uint8_t *supp_rate_set, uint8_t supp_rates_len, @@ -2272,7 +2272,7 @@ lim_tdls_populate_matching_rate_set(tpAniSirGlobal mac_ctx, tpDphHashNode stads, val = WNI_CFG_OPERATIONAL_RATE_SET_LEN; if (wlan_cfg_get_str(mac_ctx, WNI_CFG_OPERATIONAL_RATE_SET, (uint8_t *) &temp_rate_set.rate, - &val) != eSIR_SUCCESS) { + &val) != QDF_STATUS_SUCCESS) { /* Could not get rateset from CFG. Log error. */ pe_err("could not retrieve rateset"); val = 0; @@ -2285,13 +2285,13 @@ lim_tdls_populate_matching_rate_set(tpAniSirGlobal mac_ctx, tpDphHashNode stads, if (wlan_cfg_get_str(mac_ctx, WNI_CFG_EXTENDED_OPERATIONAL_RATE_SET, (uint8_t *) &temp_rate_set2.rate, - &val) != eSIR_SUCCESS) + &val) != QDF_STATUS_SUCCESS) temp_rate_set2.numRates = val; } if ((temp_rate_set.numRates + temp_rate_set2.numRates) > 12) { pe_err("more than 12 rates in CFG"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } /** @@ -2356,7 +2356,7 @@ lim_tdls_populate_matching_rate_set(tpAniSirGlobal mac_ctx, tpDphHashNode stads, (a_rateindex > SIR_NUM_11A_RATES)) { pe_warn("Invalid number of rates (11b->%d, 11a->%d)", b_rateindex, a_rateindex); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } if (sirIsArate(temp_rate_set2.rate[i] & 0x7f)) { is_a_rate = 1; @@ -2387,10 +2387,10 @@ lim_tdls_populate_matching_rate_set(tpAniSirGlobal mac_ctx, tpDphHashNode stads, { val = SIZE_OF_SUPPORTED_MCS_SET; if (wlan_cfg_get_str(mac_ctx, WNI_CFG_SUPPORTED_MCS_SET, - mcsSet, &val) != eSIR_SUCCESS) { + mcsSet, &val) != QDF_STATUS_SUCCESS) { /* Could not get rateset from CFG. Log error. */ pe_err("could not retrieve supportedMCSSet"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } if (NSS_1x1_MODE == nss) @@ -2414,7 +2414,7 @@ lim_tdls_populate_matching_rate_set(tpAniSirGlobal mac_ctx, tpDphHashNode stads, if ((phymode == WNI_CFG_PHY_MODE_11G) && is_a_rate) stads->erpEnabled = eHAL_SET; - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /* @@ -2560,12 +2560,12 @@ static void lim_tdls_update_hash_node_info(tpAniSirGlobal pMac, /* * Add STA for TDLS setup procedure */ -static tSirRetStatus lim_tdls_setup_add_sta(tpAniSirGlobal pMac, +static QDF_STATUS lim_tdls_setup_add_sta(tpAniSirGlobal pMac, tSirTdlsAddStaReq *pAddStaReq, tpPESession psessionEntry) { tpDphHashNode pStaDs = NULL; - tSirRetStatus status = eSIR_SUCCESS; + QDF_STATUS status = QDF_STATUS_SUCCESS; uint16_t aid = 0; pStaDs = dph_lookup_hash_entry(pMac, pAddStaReq->peermac.bytes, &aid, @@ -2574,13 +2574,13 @@ static tSirRetStatus lim_tdls_setup_add_sta(tpAniSirGlobal pMac, if (pStaDs && pAddStaReq->tdlsAddOper == TDLS_OPER_ADD) { pe_err("TDLS entry for peer: "MAC_ADDRESS_STR " already exist, cannot add new entry", MAC_ADDR_ARRAY(pAddStaReq->peermac.bytes)); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } if (pStaDs && pStaDs->staType != STA_ENTRY_TDLS_PEER) { pe_err("Non TDLS entry for peer: "MAC_ADDRESS_STR " already exist", MAC_ADDR_ARRAY(pAddStaReq->peermac.bytes)); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } if (NULL == pStaDs) { @@ -2589,7 +2589,7 @@ static tSirRetStatus lim_tdls_setup_add_sta(tpAniSirGlobal pMac, if (!aid) { pe_err("No more free AID for peer: "MAC_ADDRESS_STR, MAC_ADDR_ARRAY(pAddStaReq->peermac.bytes)); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } /* Set the aid in peerAIDBitmap as it has been assigned to TDLS peer */ @@ -2614,7 +2614,7 @@ static tSirRetStatus lim_tdls_setup_add_sta(tpAniSirGlobal pMac, if (NULL == pStaDs) { pe_err("add hash entry failed"); QDF_ASSERT(0); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } } @@ -2627,7 +2627,7 @@ static tSirRetStatus lim_tdls_setup_add_sta(tpAniSirGlobal pMac, (pAddStaReq->tdlsAddOper == TDLS_OPER_UPDATE) ? true : false, psessionEntry); - if (eSIR_SUCCESS != status) { + if (QDF_STATUS_SUCCESS != status) { /* should not fail */ QDF_ASSERT(0); } @@ -2637,12 +2637,12 @@ static tSirRetStatus lim_tdls_setup_add_sta(tpAniSirGlobal pMac, /* * Del STA, after Link is teardown or discovery response sent on direct link */ -static tSirRetStatus lim_tdls_del_sta(tpAniSirGlobal pMac, +static QDF_STATUS lim_tdls_del_sta(tpAniSirGlobal pMac, struct qdf_mac_addr peerMac, tpPESession psessionEntry, bool resp_reqd) { - tSirRetStatus status = eSIR_FAILURE; + QDF_STATUS status = QDF_STATUS_E_FAILURE; uint16_t peerIdx = 0; tpDphHashNode pStaDs; @@ -2717,7 +2717,7 @@ QDF_STATUS lim_process_tdls_add_sta_rsp(tpAniSirGlobal pMac, void *msg, tpPESession psessionEntry) { tAddStaParams *pAddStaParams = (tAddStaParams *) msg; - uint8_t status = eSIR_SUCCESS; + uint8_t status = QDF_STATUS_SUCCESS; tDphHashNode *pStaDs = NULL; uint16_t aid = 0; @@ -2729,7 +2729,7 @@ QDF_STATUS lim_process_tdls_add_sta_rsp(tpAniSirGlobal pMac, void *msg, if (pAddStaParams->status != QDF_STATUS_SUCCESS) { QDF_ASSERT(0); pe_err("Add sta failed "); - status = eSIR_FAILURE; + status = QDF_STATUS_E_FAILURE; goto add_sta_error; } @@ -2737,7 +2737,7 @@ QDF_STATUS lim_process_tdls_add_sta_rsp(tpAniSirGlobal pMac, void *msg, &psessionEntry->dph.dphHashTable); if (NULL == pStaDs) { pe_err("pStaDs is NULL "); - status = eSIR_FAILURE; + status = QDF_STATUS_E_FAILURE; goto add_sta_error; } @@ -2811,9 +2811,9 @@ lim_send_tdls_comp_mgmt_rsp(tpAniSirGlobal mac_ctx, uint16_t msg_type, * * Process Send Mgmt Request from SME and transmit to AP. * - * Return: eSIR_SUCCESS on success, error code otherwise + * Return: QDF_STATUS_SUCCESS on success, error code otherwise */ -tSirRetStatus lim_process_sme_tdls_mgmt_send_req(tpAniSirGlobal mac_ctx, +QDF_STATUS lim_process_sme_tdls_mgmt_send_req(tpAniSirGlobal mac_ctx, uint32_t *msg) { /* get all discovery request parameters */ @@ -2932,7 +2932,7 @@ lim_tdls_send_mgmt_error: result_code, send_req->sessionId, send_req->transactionId); - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /* @@ -2974,7 +2974,7 @@ static QDF_STATUS lim_send_sme_tdls_del_sta_rsp(tpAniSirGlobal pMac, /* * Process Send Mgmt Request from SME and transmit to AP. */ -tSirRetStatus lim_process_sme_tdls_add_sta_req(tpAniSirGlobal pMac, +QDF_STATUS lim_process_sme_tdls_add_sta_req(tpAniSirGlobal pMac, uint32_t *pMsgBuf) { /* get all discovery request parameters */ @@ -3019,32 +3019,32 @@ tSirRetStatus lim_process_sme_tdls_add_sta_req(tpAniSirGlobal pMac, pMac->lim.gLimAddStaTdls = true; /* To start with, send add STA request to HAL */ - if (eSIR_FAILURE == lim_tdls_setup_add_sta(pMac, pAddStaReq, psessionEntry)) { + if (QDF_STATUS_E_FAILURE == lim_tdls_setup_add_sta(pMac, pAddStaReq, psessionEntry)) { pe_err("Add TDLS Station request failed"); goto lim_tdls_add_sta_error; } - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; lim_tdls_add_sta_error: lim_send_sme_tdls_add_sta_rsp(pMac, pAddStaReq->sessionId, pAddStaReq->peermac.bytes, (pAddStaReq->tdlsAddOper == TDLS_OPER_UPDATE), - NULL, eSIR_FAILURE); + NULL, QDF_STATUS_E_FAILURE); - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /* * Process Del Sta Request from SME . */ -tSirRetStatus lim_process_sme_tdls_del_sta_req(tpAniSirGlobal pMac, +QDF_STATUS lim_process_sme_tdls_del_sta_req(tpAniSirGlobal pMac, uint32_t *pMsgBuf) { /* get all discovery request parameters */ tSirTdlsDelStaReq *pDelStaReq = (tSirTdlsDelStaReq *) pMsgBuf; tpPESession psessionEntry; uint8_t sessionId; - tSirRetStatus status = eSIR_FAILURE; + QDF_STATUS status = QDF_STATUS_E_FAILURE; pe_debug("TDLS Delete STA Request Received"); psessionEntry = @@ -3055,8 +3055,8 @@ tSirRetStatus lim_process_sme_tdls_del_sta_req(tpAniSirGlobal pMac, pDelStaReq->sessionId); lim_send_sme_tdls_del_sta_rsp(pMac, pDelStaReq->sessionId, pDelStaReq->peermac, NULL, - eSIR_FAILURE); - return eSIR_FAILURE; + QDF_STATUS_E_FAILURE); + return QDF_STATUS_E_FAILURE; } /* check if we are in proper state to work as TDLS client */ @@ -3071,8 +3071,8 @@ tSirRetStatus lim_process_sme_tdls_del_sta_req(tpAniSirGlobal pMac, pDelStaReq->sessionId); lim_send_sme_tdls_del_sta_rsp(pMac, pDelStaReq->sessionId, pDelStaReq->peermac, NULL, - eSIR_FAILURE); - return eSIR_FAILURE; + QDF_STATUS_E_FAILURE); + return QDF_STATUS_E_FAILURE; } /* @@ -3089,12 +3089,12 @@ tSirRetStatus lim_process_sme_tdls_del_sta_req(tpAniSirGlobal pMac, status = lim_tdls_del_sta(pMac, pDelStaReq->peermac, psessionEntry, true); - if (status == eSIR_SUCCESS) + if (status == QDF_STATUS_SUCCESS) return status; lim_tdls_del_sta_error: lim_send_sme_tdls_del_sta_rsp(pMac, psessionEntry->smeSessionId, - pDelStaReq->peermac, NULL, eSIR_FAILURE); + pDelStaReq->peermac, NULL, QDF_STATUS_E_FAILURE); return status; } @@ -3115,7 +3115,7 @@ static void lim_check_aid_and_delete_peer(tpAniSirGlobal p_mac, int i, aid; size_t aid_bitmap_size = sizeof(session_entry->peerAIDBitmap); struct qdf_mac_addr mac_addr; - tSirRetStatus status; + QDF_STATUS status; /* * Check all the set bit in peerAIDBitmap and delete the peer @@ -3148,7 +3148,7 @@ static void lim_check_aid_and_delete_peer(tpAniSirGlobal p_mac, status = lim_tdls_del_sta(p_mac, mac_addr, session_entry, false); - if (status != eSIR_SUCCESS) + if (status != QDF_STATUS_SUCCESS) pe_debug("peer "MAC_ADDRESS_STR" not found", MAC_ADDR_ARRAY(stads->staAddr)); } @@ -3173,28 +3173,28 @@ skip: * * Delete all the TDLS peer connected before leaving the BSS * - * Return: eSIR_SUCCESS on success, error code otherwise + * Return: QDF_STATUS_SUCCESS on success, error code otherwise */ -tSirRetStatus lim_delete_tdls_peers(tpAniSirGlobal mac_ctx, +QDF_STATUS lim_delete_tdls_peers(tpAniSirGlobal mac_ctx, tpPESession session_entry) { pe_debug("Enter"); if (NULL == session_entry) { pe_err("NULL session_entry"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } lim_check_aid_and_delete_peer(mac_ctx, session_entry); if (lim_is_roam_synch_in_progress(session_entry)) - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; tgt_tdls_peers_deleted_notification(mac_ctx->psoc, session_entry->smeSessionId); pe_debug("Exit"); - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /** @@ -3204,9 +3204,9 @@ tSirRetStatus lim_delete_tdls_peers(tpAniSirGlobal mac_ctx, * * This function processes request to delete tdls peers * - * Return: Success: eSIR_SUCCESS Failure: Error value + * Return: Success: QDF_STATUS_SUCCESS Failure: Error value */ -tSirRetStatus lim_process_sme_del_all_tdls_peers(tpAniSirGlobal p_mac, +QDF_STATUS lim_process_sme_del_all_tdls_peers(tpAniSirGlobal p_mac, uint32_t *msg_buf) { struct sir_del_all_tdls_peers *msg; @@ -3216,14 +3216,14 @@ tSirRetStatus lim_process_sme_del_all_tdls_peers(tpAniSirGlobal p_mac, msg = (struct sir_del_all_tdls_peers *)msg_buf; if (msg == NULL) { pe_err("NULL msg"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } session_entry = pe_find_session_by_bssid(p_mac, msg->bssid.bytes, &session_id); if (NULL == session_entry) { pe_err("NULL psessionEntry"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } lim_check_aid_and_delete_peer(p_mac, session_entry); @@ -3231,7 +3231,7 @@ tSirRetStatus lim_process_sme_del_all_tdls_peers(tpAniSirGlobal p_mac, tgt_tdls_peers_deleted_notification(p_mac->psoc, session_entry->smeSessionId); - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /** @@ -3271,7 +3271,7 @@ void lim_process_tdls_del_sta_rsp(tpAniSirGlobal mac_ctx, pe_err("DEL STA failed!"); lim_send_sme_tdls_del_sta_rsp(mac_ctx, session_entry->smeSessionId, - peer_mac, NULL, eSIR_FAILURE); + peer_mac, NULL, QDF_STATUS_E_FAILURE); goto skip_event; } @@ -3281,7 +3281,7 @@ void lim_process_tdls_del_sta_rsp(tpAniSirGlobal mac_ctx, lim_send_sme_tdls_del_sta_rsp(mac_ctx, session_entry->smeSessionId, peer_mac, sta_ds, - eSIR_SUCCESS); + QDF_STATUS_SUCCESS); lim_release_peer_idx(mac_ctx, sta_ds->assocId, session_entry); /* Clear the aid in peerAIDBitmap as this aid is now in freepool */ diff --git a/core/mac/src/pe/lim/lim_prop_exts_utils.c b/core/mac/src/pe/lim/lim_prop_exts_utils.c index 3971d7ab73..cb48728d7a 100644 --- a/core/mac/src/pe/lim/lim_prop_exts_utils.c +++ b/core/mac/src/pe/lim/lim_prop_exts_utils.c @@ -363,7 +363,7 @@ lim_extract_ap_capability(tpAniSirGlobal mac_ctx, uint8_t *p_ie, { tSirProbeRespBeacon *beacon_struct; uint32_t enable_txbf_20mhz; - tSirRetStatus cfg_get_status = eSIR_FAILURE; + QDF_STATUS cfg_get_status = QDF_STATUS_E_FAILURE; uint8_t ap_bcon_ch_width; bool new_ch_width_dfn = false; bool is_vendor_ap_present; @@ -386,7 +386,7 @@ lim_extract_ap_capability(tpAniSirGlobal mac_ctx, uint8_t *p_ie, QDF_TRACE_HEX_DUMP(QDF_MODULE_ID_PE, QDF_TRACE_LEVEL_DEBUG, p_ie, ie_len); if (sir_parse_beacon_ie(mac_ctx, beacon_struct, p_ie, - (uint32_t) ie_len) != eSIR_SUCCESS) { + (uint32_t) ie_len) != QDF_STATUS_SUCCESS) { pe_err("sir_parse_beacon_ie failed to parse beacon"); qdf_mem_free(beacon_struct); return; @@ -458,7 +458,7 @@ lim_extract_ap_capability(tpAniSirGlobal mac_ctx, uint8_t *p_ie, cfg_get_status = wlan_cfg_get_int(mac_ctx, WNI_CFG_VHT_ENABLE_TXBF_20MHZ, &enable_txbf_20mhz); - if ((IS_SIR_STATUS_SUCCESS(cfg_get_status)) && + if ((QDF_IS_STATUS_SUCCESS(cfg_get_status)) && (false == enable_txbf_20mhz)) session->vht_config.su_beam_formee = 0; } else if (session->vhtCapabilityPresentInBeacon && diff --git a/core/mac/src/pe/lim/lim_reassoc_utils.c b/core/mac/src/pe/lim/lim_reassoc_utils.c index 3dd816ea96..47e97b2724 100644 --- a/core/mac/src/pe/lim/lim_reassoc_utils.c +++ b/core/mac/src/pe/lim/lim_reassoc_utils.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016-2017 The Linux Foundation. All rights reserved. + * Copyright (c) 2016-2018 The Linux Foundation. All rights reserved. * * Permission to use, copy, modify, and/or distribute this software for * any purpose with or without fee is hereby granted, provided that the @@ -125,7 +125,7 @@ void lim_handle_del_bss_in_re_assoc_context(tpAniSirGlobal pMac, { tpSirAssocRsp assocRsp; tpDphHashNode pStaDs; - tSirRetStatus retStatus = eSIR_SUCCESS; + QDF_STATUS retStatus = QDF_STATUS_SUCCESS; tpSchBeaconStruct beacon_struct; beacon_struct = qdf_mem_malloc(sizeof(tSchBeaconStruct)); @@ -190,14 +190,14 @@ void lim_handle_del_bss_in_re_assoc_context(tpAniSirGlobal pMac, * updateBss flag is false, as in this case, PE is first * deleting the existing BSS and then adding a new one */ - if (eSIR_SUCCESS != + if (QDF_STATUS_SUCCESS != lim_sta_send_add_bss(pMac, assocRsp, beacon_struct, bss_desc, false, psessionEntry)) { pe_err("Posting ADDBSS in the ReAssocCtx Failed"); - retStatus = eSIR_FAILURE; + retStatus = QDF_STATUS_E_FAILURE; } - if (retStatus != eSIR_SUCCESS) { + if (retStatus != QDF_STATUS_SUCCESS) { mlmReassocCnf.resultCode = eSIR_SME_RESOURCES_UNAVAILABLE; mlmReassocCnf.protStatusCode = @@ -256,7 +256,7 @@ void lim_handle_add_bss_in_re_assoc_context(tpAniSirGlobal pMac, case eLIM_SME_WT_REASSOC_STATE: { tpSirAssocRsp assocRsp; tpDphHashNode pStaDs; - tSirRetStatus retStatus = eSIR_SUCCESS; + QDF_STATUS retStatus = QDF_STATUS_SUCCESS; tSchBeaconStruct *pBeaconStruct; pBeaconStruct = @@ -315,15 +315,15 @@ void lim_handle_add_bss_in_re_assoc_context(tpAniSirGlobal pMac, } psessionEntry->isNonRoamReassoc = 1; - if (eSIR_SUCCESS != + if (QDF_STATUS_SUCCESS != lim_sta_send_add_bss(pMac, assocRsp, pBeaconStruct, &psessionEntry->pLimReAssocReq-> bssDescription, true, psessionEntry)) { pe_err("Post ADDBSS in the ReAssocCtxt Failed"); - retStatus = eSIR_FAILURE; + retStatus = QDF_STATUS_E_FAILURE; } - if (retStatus != eSIR_SUCCESS) { + if (retStatus != QDF_STATUS_SUCCESS) { mlmReassocCnf.resultCode = eSIR_SME_RESOURCES_UNAVAILABLE; mlmReassocCnf.protStatusCode = @@ -385,13 +385,13 @@ bool lim_is_reassoc_in_progress(tpAniSirGlobal pMac, tpPESession psessionEntry) * we add the self sta. We update with the association id from the reassoc * response from the AP. * - * Return: eSIR_SUCCESS on success else eSirRetStatus failure codes + * Return: QDF_STATUS_SUCCESS on success else eSirRetStatus failure codes */ -tSirRetStatus lim_add_ft_sta_self(tpAniSirGlobal mac_ctx, uint16_t assoc_id, +QDF_STATUS lim_add_ft_sta_self(tpAniSirGlobal mac_ctx, uint16_t assoc_id, tpPESession session_entry) { tpAddStaParams add_sta_params = NULL; - tSirRetStatus ret_code = eSIR_SUCCESS; + QDF_STATUS ret_code = QDF_STATUS_SUCCESS; struct scheduler_msg msg_q = {0}; add_sta_params = session_entry->ftPEContext.pAddStaReq; @@ -414,7 +414,7 @@ tSirRetStatus lim_add_ft_sta_self(tpAniSirGlobal mac_ctx, uint16_t assoc_id, session_entry->peSessionId, eLIM_MLM_WT_ADD_STA_RSP_STATE)); session_entry->limMlmState = eLIM_MLM_WT_ADD_STA_RSP_STATE; ret_code = wma_post_ctrl_msg(mac_ctx, &msg_q); - if (eSIR_SUCCESS != ret_code) { + if (QDF_STATUS_SUCCESS != ret_code) { pe_err("Posting WMA_ADD_STA_REQ to HAL failed, reason=%X", ret_code); qdf_mem_free(add_sta_params); diff --git a/core/mac/src/pe/lim/lim_roam_timer_utils.c b/core/mac/src/pe/lim/lim_roam_timer_utils.c index d9f8b10674..a3b1395f80 100644 --- a/core/mac/src/pe/lim/lim_roam_timer_utils.c +++ b/core/mac/src/pe/lim/lim_roam_timer_utils.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2016-2017 The Linux Foundation. All rights reserved. + * Copyright (c) 2016-2018 The Linux Foundation. All rights reserved. * * Permission to use, copy, modify, and/or distribute this software for * any purpose with or without fee is hereby granted, provided that the @@ -40,7 +40,7 @@ uint32_t lim_create_timers_host_roam(tpAniSirGlobal mac_ctx) uint32_t cfg_value; if (wlan_cfg_get_int(mac_ctx, WNI_CFG_REASSOCIATION_FAILURE_TIMEOUT, - &cfg_value) != eSIR_SUCCESS) + &cfg_value) != QDF_STATUS_SUCCESS) pe_warn("could not retrieve ReassocFailureTimeout value"); cfg_value = SYS_MS_TO_TICKS(cfg_value); @@ -113,7 +113,7 @@ void lim_deactivate_and_change_timer_host_roam(tpAniSirGlobal mac_ctx, if (wlan_cfg_get_int(mac_ctx, WNI_CFG_REASSOCIATION_FAILURE_TIMEOUT, - &val) != eSIR_SUCCESS) + &val) != QDF_STATUS_SUCCESS) pe_warn("could not get ReassocFailureTimeout val"); val = SYS_MS_TO_TICKS(val); diff --git a/core/mac/src/pe/lim/lim_security_utils.c b/core/mac/src/pe/lim/lim_security_utils.c index 365ddf0840..3d5dc42539 100644 --- a/core/mac/src/pe/lim/lim_security_utils.c +++ b/core/mac/src/pe/lim/lim_security_utils.c @@ -87,7 +87,7 @@ lim_is_auth_algo_supported(tpAniSirGlobal pMac, tAniAuthType authType, } if (wlan_cfg_get_int(pMac, WNI_CFG_OPEN_SYSTEM_AUTH_ENABLE, - &algoEnable) != eSIR_SUCCESS) { + &algoEnable) != QDF_STATUS_SUCCESS) { pe_err("could not retrieve AuthAlgo1 Enable value"); return false; @@ -106,7 +106,7 @@ lim_is_auth_algo_supported(tpAniSirGlobal pMac, tAniAuthType authType, if (wlan_cfg_get_int (pMac, WNI_CFG_SHARED_KEY_AUTH_ENABLE, - &algoEnable) != eSIR_SUCCESS) { + &algoEnable) != QDF_STATUS_SUCCESS) { pe_err("could not retrieve AuthAlgo2 Enable value"); return false; @@ -117,7 +117,7 @@ lim_is_auth_algo_supported(tpAniSirGlobal pMac, tAniAuthType authType, } else if (wlan_cfg_get_int(pMac, WNI_CFG_PRIVACY_ENABLED, - &privacyOptImp) != eSIR_SUCCESS) { + &privacyOptImp) != QDF_STATUS_SUCCESS) { pe_err("could not retrieve PrivacyOptImplemented value"); return false; @@ -691,7 +691,7 @@ lim_rc4(uint8_t *pDest, uint8_t *pSrc, uint8_t *seed, uint32_t keyLength, * @param pPlainBody Pointer to the decrypted body * @param keyLength 8 (WEP40) or 16 (WEP104) * - * @return Decrypt result - eSIR_SUCCESS for success and + * @return Decrypt result - QDF_STATUS_SUCCESS for success and * LIM_DECRYPT_ICV_FAIL for ICV mismatch. * If decryption is a success, pBody will * have decrypted auth frame body. @@ -732,7 +732,7 @@ lim_decrypt_auth_frame(tpAniSirGlobal pMac, uint8_t *pKey, uint8_t *pEncrBody, return LIM_DECRYPT_ICV_FAIL; } - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /****** end lim_decrypt_auth_frame() ******/ /** @@ -783,7 +783,7 @@ void lim_send_set_bss_key_req(tpAniSirGlobal pMac, struct scheduler_msg msgQ = {0}; tpSetBssKeyParams pSetBssKeyParams = NULL; tLimMlmSetKeysCnf mlmSetKeysCnf; - tSirRetStatus retCode; + QDF_STATUS retCode; uint32_t val = 0; if (pMlmSetKeysReq->numKeys > SIR_MAC_MAX_NUM_OF_DEFAULT_KEYS) { @@ -809,7 +809,7 @@ void lim_send_set_bss_key_req(tpAniSirGlobal pMac, pSetBssKeyParams->bssIdx = psessionEntry->bssIdx; pSetBssKeyParams->encType = pMlmSetKeysReq->edType; - if (eSIR_SUCCESS != wlan_cfg_get_int(pMac, WNI_CFG_SINGLE_TID_RC, &val)) + if (QDF_STATUS_SUCCESS != wlan_cfg_get_int(pMac, WNI_CFG_SINGLE_TID_RC, &val)) pe_warn("Unable to read WNI_CFG_SINGLE_TID_RC"); pSetBssKeyParams->singleTidRc = (uint8_t) val; @@ -847,7 +847,7 @@ void lim_send_set_bss_key_req(tpAniSirGlobal pMac, pe_debug("Sending WMA_SET_BSSKEY_REQ..."); MTRACE(mac_trace_msg_tx(pMac, psessionEntry->peSessionId, msgQ.type)); retCode = wma_post_ctrl_msg(pMac, &msgQ); - if (eSIR_SUCCESS != retCode) { + if (QDF_STATUS_SUCCESS != retCode) { pe_err("Posting SET_BSSKEY to HAL failed, reason=%X", retCode); @@ -891,7 +891,7 @@ void lim_send_set_sta_key_req(tpAniSirGlobal pMac, struct scheduler_msg msgQ = {0}; tpSetStaKeyParams pSetStaKeyParams = NULL; tLimMlmSetKeysCnf mlmSetKeysCnf; - tSirRetStatus retCode; + QDF_STATUS retCode; uint32_t val = 0; /* Package WMA_SET_STAKEY_REQ message parameters */ @@ -905,7 +905,7 @@ void lim_send_set_sta_key_req(tpAniSirGlobal pMac, pSetStaKeyParams->staIdx = staIdx; pSetStaKeyParams->encType = pMlmSetKeysReq->edType; - if (eSIR_SUCCESS != wlan_cfg_get_int(pMac, WNI_CFG_SINGLE_TID_RC, &val)) + if (QDF_STATUS_SUCCESS != wlan_cfg_get_int(pMac, WNI_CFG_SINGLE_TID_RC, &val)) pe_warn("Unable to read WNI_CFG_SINGLE_TID_RC"); pSetStaKeyParams->singleTidRc = (uint8_t) val; @@ -1017,7 +1017,7 @@ void lim_send_set_sta_key_req(tpAniSirGlobal pMac, pe_debug("Sending WMA_SET_STAKEY_REQ..."); MTRACE(mac_trace_msg_tx(pMac, sessionEntry->peSessionId, msgQ.type)); retCode = wma_post_ctrl_msg(pMac, &msgQ); - if (eSIR_SUCCESS != retCode) { + if (QDF_STATUS_SUCCESS != retCode) { pe_err("Posting SET_STAKEY to HAL failed, reason=%X", retCode); goto free_sta_key; diff --git a/core/mac/src/pe/lim/lim_send_frames_host_roam.c b/core/mac/src/pe/lim/lim_send_frames_host_roam.c index 3285019629..d756291aee 100644 --- a/core/mac/src/pe/lim/lim_send_frames_host_roam.c +++ b/core/mac/src/pe/lim/lim_send_frames_host_roam.c @@ -443,9 +443,9 @@ void lim_send_reassoc_req_with_ft_ies_mgmt_frame(tpAniSirGlobal mac_ctx, MTRACE(qdf_trace(QDF_MODULE_ID_PE, TRACE_CODE_TX_MGMT, pe_session->peSessionId, mac_hdr->fc.subType)); lim_diag_event_report(mac_ctx, WLAN_PE_DIAG_REASSOC_START_EVENT, - pe_session, eSIR_SUCCESS, eSIR_SUCCESS); + pe_session, QDF_STATUS_SUCCESS, QDF_STATUS_SUCCESS); lim_diag_mgmt_tx_event_report(mac_ctx, mac_hdr, - pe_session, eSIR_SUCCESS, eSIR_SUCCESS); + pe_session, QDF_STATUS_SUCCESS, QDF_STATUS_SUCCESS); qdf_status = wma_tx_frame(mac_ctx, packet, (uint16_t) (bytes + ft_ies_length), TXRX_FRM_802_11_MGMT, ANI_TXDIR_TODS, 7, @@ -771,10 +771,10 @@ void lim_send_reassoc_req_mgmt_frame(tpAniSirGlobal pMac, MTRACE(qdf_trace(QDF_MODULE_ID_PE, TRACE_CODE_TX_MGMT, psessionEntry->peSessionId, pMacHdr->fc.subType)); lim_diag_event_report(pMac, WLAN_PE_DIAG_REASSOC_START_EVENT, - psessionEntry, eSIR_SUCCESS, eSIR_SUCCESS); + psessionEntry, QDF_STATUS_SUCCESS, QDF_STATUS_SUCCESS); lim_diag_mgmt_tx_event_report(pMac, pMacHdr, - psessionEntry, eSIR_SUCCESS, - eSIR_SUCCESS); + psessionEntry, QDF_STATUS_SUCCESS, + QDF_STATUS_SUCCESS); qdf_status = wma_tx_frame(pMac, pPacket, (uint16_t) (sizeof(tSirMacMgmtHdr) + nPayload), diff --git a/core/mac/src/pe/lim/lim_send_management_frames.c b/core/mac/src/pe/lim/lim_send_management_frames.c index 47daa8a585..fd6b0b512e 100644 --- a/core/mac/src/pe/lim/lim_send_management_frames.c +++ b/core/mac/src/pe/lim/lim_send_management_frames.c @@ -194,9 +194,9 @@ void lim_populate_mac_header(tpAniSirGlobal mac_ctx, uint8_t *buf, * --background scan: no session * --sch_beacon_processing: to get EDCA parameters: session needed * - * Return: tSirRetStatus (eSIR_SUCCESS on success and error codes otherwise) + * Return: QDF_STATUS (QDF_STATUS_SUCCESS on success and error codes otherwise) */ -tSirRetStatus +QDF_STATUS lim_send_probe_req_mgmt_frame(tpAniSirGlobal mac_ctx, tSirMacSSid *ssid, tSirMacAddr bssid, @@ -220,7 +220,7 @@ lim_send_probe_req_mgmt_frame(tpAniSirGlobal mac_ctx, uint16_t addn_ielen = 0; bool extracted_ext_cap_flag = false; tDot11fIEExtCap extracted_ext_cap; - tSirRetStatus sir_status; + QDF_STATUS sir_status; const uint8_t *qcn_ie = NULL; if (additional_ielen) @@ -354,7 +354,7 @@ lim_send_probe_req_mgmt_frame(tpAniSirGlobal mac_ctx, additional_ie, &addn_ielen, &extracted_ext_cap); - if (eSIR_SUCCESS != sir_status) { + if (QDF_STATUS_SUCCESS != sir_status) { pe_debug("Unable to Stripoff ExtCap IE from Probe Req"); } else { struct s_ext_cap *p_ext_cap = @@ -405,7 +405,7 @@ lim_send_probe_req_mgmt_frame(tpAniSirGlobal mac_ctx, (void **)&packet); if (!QDF_IS_STATUS_SUCCESS(qdf_status)) { pe_err("Failed to allocate %d bytes for a Probe Request", bytes); - return eSIR_MEM_ALLOC_FAILED; + return QDF_STATUS_E_NOMEM; } /* Paranoia: */ qdf_mem_set(frame, bytes, 0); @@ -421,7 +421,7 @@ lim_send_probe_req_mgmt_frame(tpAniSirGlobal mac_ctx, if (DOT11F_FAILED(status)) { pe_err("Failed to pack a Probe Request (0x%08x)", status); cds_packet_free((void *)packet); - return eSIR_FAILURE; /* allocated! */ + return QDF_STATUS_E_FAILURE; /* allocated! */ } else if (DOT11F_WARNED(status)) { pe_warn("There were warnings while packing a Probe Request (0x%08x)", status); } @@ -455,13 +455,13 @@ lim_send_probe_req_mgmt_frame(tpAniSirGlobal mac_ctx, if (!QDF_IS_STATUS_SUCCESS(qdf_status)) { pe_err("could not send Probe Request frame!"); /* Pkt will be freed up by the callback */ - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /* End lim_send_probe_req_mgmt_frame. */ -static tSirRetStatus lim_get_addn_ie_for_probe_resp(tpAniSirGlobal pMac, +static QDF_STATUS lim_get_addn_ie_for_probe_resp(tpAniSirGlobal pMac, uint8_t *addIE, uint16_t *addnIELen, uint8_t probeReqP2pIe) { @@ -476,13 +476,13 @@ static tSirRetStatus lim_get_addn_ie_for_probe_resp(tpAniSirGlobal pMac, if (NULL == addIE) { pe_err("NULL addIE pointer"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } tempbuf = qdf_mem_malloc(left); if (NULL == tempbuf) { pe_err("Unable to allocate memory to store addn IE"); - return eSIR_MEM_ALLOC_FAILED; + return QDF_STATUS_E_NOMEM; } while (left >= 2) { @@ -493,7 +493,7 @@ static tSirRetStatus lim_get_addn_ie_for_probe_resp(tpAniSirGlobal pMac, pe_err("Invalid IEs eid: %d elem_len: %d left: %d", elem_id, elem_len, left); qdf_mem_free(tempbuf); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } if (!((SIR_MAC_EID_VENDOR == elem_id) && (memcmp @@ -510,7 +510,7 @@ static tSirRetStatus lim_get_addn_ie_for_probe_resp(tpAniSirGlobal pMac, *addnIELen = tempLen; qdf_mem_free(tempbuf); } - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /** @@ -538,7 +538,7 @@ lim_send_probe_rsp_mgmt_frame(tpAniSirGlobal mac_ctx, tpPESession pe_session, uint8_t preq_p2pie) { tDot11fProbeResponse *frm; - tSirRetStatus sir_status; + QDF_STATUS sir_status; uint32_t cfg, payload, bytes = 0, status; tpSirMacMgmtHdr mac_hdr; uint8_t *frame; @@ -602,7 +602,7 @@ lim_send_probe_rsp_mgmt_frame(tpAniSirGlobal mac_ctx, } else { sir_status = wlan_cfg_get_int(mac_ctx, WNI_CFG_BEACON_INTERVAL, &cfg); - if (eSIR_SUCCESS != sir_status) { + if (QDF_STATUS_SUCCESS != sir_status) { pe_err("Failed to get WNI_CFG_BEACON_INTERVAL (%d)", sir_status); goto err_ret; @@ -626,7 +626,7 @@ lim_send_probe_rsp_mgmt_frame(tpAniSirGlobal mac_ctx, pe_session); } else { if (wlan_cfg_get_int(mac_ctx, (uint16_t) WNI_CFG_WPS_ENABLE, - &tmp) != eSIR_SUCCESS) + &tmp) != QDF_STATUS_SUCCESS) pe_err("Failed to cfg get id %d", WNI_CFG_WPS_ENABLE); wps_ap = tmp & WNI_CFG_WPS_ENABLE_AP; @@ -736,7 +736,7 @@ lim_send_probe_rsp_mgmt_frame(tpAniSirGlobal mac_ctx, pe_session->addIeParams.probeRespDataLen); addn_ie_len = pe_session->addIeParams.probeRespDataLen; - if (eSIR_SUCCESS != lim_get_addn_ie_for_probe_resp(mac_ctx, + if (QDF_STATUS_SUCCESS != lim_get_addn_ie_for_probe_resp(mac_ctx, add_ie, &addn_ie_len, preq_p2pie)) { pe_err("Unable to get addn_ie"); goto err_ret; @@ -745,7 +745,7 @@ lim_send_probe_rsp_mgmt_frame(tpAniSirGlobal mac_ctx, sir_status = lim_strip_extcap_update_struct(mac_ctx, add_ie, &addn_ie_len, &extracted_ext_cap); - if (eSIR_SUCCESS != sir_status) { + if (QDF_STATUS_SUCCESS != sir_status) { pe_debug("Unable to strip off ExtCap IE"); } else { extracted_ext_cap_flag = true; @@ -1070,8 +1070,8 @@ lim_send_addts_req_action_frame(tpAniSirGlobal pMac, MTRACE(qdf_trace(QDF_MODULE_ID_PE, TRACE_CODE_TX_MGMT, psessionEntry->peSessionId, pMacHdr->fc.subType)); lim_diag_mgmt_tx_event_report(pMac, pMacHdr, - psessionEntry, eSIR_SUCCESS, - eSIR_SUCCESS); + psessionEntry, QDF_STATUS_SUCCESS, + QDF_STATUS_SUCCESS); /* Queue Addts Response frame in high priority WQ */ qdf_status = wma_tx_frame(pMac, pPacket, (uint16_t) nBytes, @@ -1110,7 +1110,7 @@ lim_send_assoc_rsp_mgmt_frame(tpAniSirGlobal mac_ctx, static tDot11fAssocResponse frm; uint8_t *frame; tpSirMacMgmtHdr mac_hdr; - tSirRetStatus sir_status; + QDF_STATUS sir_status; uint8_t lle_mode = 0, addts; tHalBitVal qos_mode, wme_mode; uint32_t payload, bytes = 0, status; @@ -1168,7 +1168,7 @@ lim_send_assoc_rsp_mgmt_frame(tpAniSirGlobal mac_ctx, } if (LIM_IS_AP_ROLE(pe_session) && sta != NULL && - eSIR_SUCCESS == status_code) { + QDF_STATUS_SUCCESS == status_code) { assoc_req = (tpSirAssocReq) pe_session->parsedAssocReq[sta->assocId]; /* @@ -1266,12 +1266,12 @@ lim_send_assoc_rsp_mgmt_frame(tpAniSirGlobal mac_ctx, if (eSIR_MAC_TRY_AGAIN_LATER == status_code) { if (wlan_cfg_get_int (mac_ctx, WNI_CFG_PMF_SA_QUERY_MAX_RETRIES, - &max_retries) != eSIR_SUCCESS) + &max_retries) != QDF_STATUS_SUCCESS) pe_err("get WNI_CFG_PMF_SA_QUERY_MAX_RETRIES failure"); else if (wlan_cfg_get_int (mac_ctx, WNI_CFG_PMF_SA_QUERY_RETRY_INTERVAL, - &retry_int) != eSIR_SUCCESS) + &retry_int) != QDF_STATUS_SUCCESS) pe_err("get WNI_CFG_PMF_SA_QUERY_RETRY_INTERVAL failure"); else populate_dot11f_timeout_interval(mac_ctx, @@ -1336,7 +1336,7 @@ lim_send_assoc_rsp_mgmt_frame(tpAniSirGlobal mac_ctx, lim_strip_extcap_update_struct (mac_ctx, &add_ie[0], &stripoff_len, &extracted_ext_cap); - if (eSIR_SUCCESS != sir_status) { + if (QDF_STATUS_SUCCESS != sir_status) { pe_debug("strip off extcap IE failed"); } else { addn_ie_len = stripoff_len; @@ -1424,7 +1424,7 @@ lim_send_assoc_rsp_mgmt_frame(tpAniSirGlobal mac_ctx, MTRACE(qdf_trace(QDF_MODULE_ID_PE, TRACE_CODE_TX_MGMT, pe_session->peSessionId, mac_hdr->fc.subType)); lim_diag_mgmt_tx_event_report(mac_ctx, mac_hdr, - pe_session, eSIR_SUCCESS, status_code); + pe_session, QDF_STATUS_SUCCESS, status_code); /* Queue Association Response frame in high priority WQ */ qdf_status = wma_tx_frame(mac_ctx, packet, (uint16_t) bytes, TXRX_FRM_802_11_MGMT, @@ -1574,8 +1574,8 @@ lim_send_delts_req_action_frame(tpAniSirGlobal pMac, MTRACE(qdf_trace(QDF_MODULE_ID_PE, TRACE_CODE_TX_MGMT, psessionEntry->peSessionId, pMacHdr->fc.subType)); lim_diag_mgmt_tx_event_report(pMac, pMacHdr, - psessionEntry, eSIR_SUCCESS, - eSIR_SUCCESS); + psessionEntry, QDF_STATUS_SUCCESS, + QDF_STATUS_SUCCESS); qdf_status = wma_tx_frame(pMac, pPacket, (uint16_t) nBytes, TXRX_FRM_802_11_MGMT, ANI_TXDIR_TODS, @@ -1611,10 +1611,10 @@ static QDF_STATUS lim_assoc_tx_complete_cnf(void *context, pe_debug("tx_complete= %d", tx_complete); if (tx_complete == WMI_MGMT_TX_COMP_TYPE_COMPLETE_OK) { assoc_ack_status = ACKED; - reason_code = eSIR_SUCCESS; + reason_code = QDF_STATUS_SUCCESS; } else { assoc_ack_status = NOT_ACKED; - reason_code = eSIR_FAILURE; + reason_code = QDF_STATUS_E_FAILURE; } if (buf) qdf_nbuf_free(buf); @@ -1644,7 +1644,7 @@ lim_send_assoc_req_mgmt_frame(tpAniSirGlobal mac_ctx, tDot11fAssocRequest *frm; uint16_t caps; uint8_t *frame; - tSirRetStatus sir_status; + QDF_STATUS sir_status; tLimMlmAssocCnf assoc_cnf; uint32_t bytes = 0, payload, status; uint8_t qos_enabled, wme_enabled, wsm_enabled; @@ -1698,7 +1698,7 @@ lim_send_assoc_req_mgmt_frame(tpAniSirGlobal mac_ctx, 0); sir_status = lim_strip_extcap_update_struct(mac_ctx, add_ie, &add_ie_len, &extr_ext_cap); - if (eSIR_SUCCESS != sir_status) { + if (QDF_STATUS_SUCCESS != sir_status) { extr_ext_flag = false; pe_debug("Unable to Stripoff ExtCap IE from Assoc Req"); } else { @@ -1965,7 +1965,7 @@ lim_send_assoc_req_mgmt_frame(tpAniSirGlobal mac_ctx, &frm->ExtCap); } - if (eSIR_SUCCESS != lim_strip_supp_op_class_update_struct(mac_ctx, + if (QDF_STATUS_SUCCESS != lim_strip_supp_op_class_update_struct(mac_ctx, add_ie, &add_ie_len, &frm->SuppOperatingClasses)) pe_debug("Unable to Stripoff supp op classes IE from Assoc Req"); @@ -2086,9 +2086,9 @@ lim_send_assoc_req_mgmt_frame(tpAniSirGlobal mac_ctx, pe_debug("Sending Association Request length %d to ", bytes); min_rid = lim_get_min_session_txrate(pe_session); lim_diag_event_report(mac_ctx, WLAN_PE_DIAG_ASSOC_START_EVENT, - pe_session, eSIR_SUCCESS, eSIR_SUCCESS); + pe_session, QDF_STATUS_SUCCESS, QDF_STATUS_SUCCESS); lim_diag_mgmt_tx_event_report(mac_ctx, mac_hdr, - pe_session, eSIR_SUCCESS, eSIR_SUCCESS); + pe_session, QDF_STATUS_SUCCESS, QDF_STATUS_SUCCESS); qdf_status = wma_tx_frameWithTxComplete(mac_ctx, packet, (uint16_t) (sizeof(tSirMacMgmtHdr) + payload), @@ -2103,7 +2103,7 @@ lim_send_assoc_req_mgmt_frame(tpAniSirGlobal mac_ctx, pe_err("Failed to send Association Request (%X)!", qdf_status); lim_diag_event_report(mac_ctx, WLAN_PE_DIAG_ASSOC_ACK_EVENT, - pe_session, SENT_FAIL, eSIR_FAILURE); + pe_session, SENT_FAIL, QDF_STATUS_E_FAILURE); /* Pkt will be freed up by the callback */ } end: @@ -2139,13 +2139,13 @@ static QDF_STATUS lim_auth_tx_complete_cnf(void *context, if (tx_complete == WMI_MGMT_TX_COMP_TYPE_COMPLETE_OK) { mac_ctx->auth_ack_status = LIM_AUTH_ACK_RCD_SUCCESS; auth_ack_status = ACKED; - reason_code = eSIR_SUCCESS; + reason_code = QDF_STATUS_SUCCESS; /* 'Change' timer for future activations */ lim_deactivate_and_change_timer(mac_ctx, eLIM_AUTH_RETRY_TIMER); } else { mac_ctx->auth_ack_status = LIM_AUTH_ACK_RCD_FAILURE; auth_ack_status = NOT_ACKED; - reason_code = eSIR_FAILURE; + reason_code = QDF_STATUS_E_FAILURE; } if (buf) @@ -2466,7 +2466,7 @@ alloc_packet: mac_ctx->auth_ack_status = LIM_AUTH_ACK_NOT_RCD; min_rid = lim_get_min_session_txrate(session); lim_diag_mgmt_tx_event_report(mac_ctx, mac_hdr, - session, eSIR_SUCCESS, eSIR_SUCCESS); + session, QDF_STATUS_SUCCESS, QDF_STATUS_SUCCESS); qdf_status = wma_tx_frameWithTxComplete(mac_ctx, packet, (uint16_t)frame_len, TXRX_FRM_802_11_MGMT, ANI_TXDIR_TODS, @@ -2480,7 +2480,7 @@ alloc_packet: qdf_status); mac_ctx->auth_ack_status = LIM_AUTH_ACK_RCD_FAILURE; lim_diag_event_report(mac_ctx, WLAN_PE_DIAG_AUTH_ACK_EVENT, - session, SENT_FAIL, eSIR_FAILURE); + session, SENT_FAIL, QDF_STATUS_E_FAILURE); /* Pkt will be freed up by the callback */ } return; @@ -2618,7 +2618,7 @@ QDF_STATUS lim_send_disassoc_cnf(tpAniSirGlobal mac_ctx) goto end; } /* Receive path cleanup with dummy packet */ - if (eSIR_SUCCESS != + if (QDF_STATUS_SUCCESS != lim_cleanup_rx_path(mac_ctx, sta_ds, pe_session)) { disassoc_cnf.resultCode = eSIR_SME_RESOURCES_UNAVAILABLE; @@ -2853,8 +2853,8 @@ lim_send_disassoc_mgmt_frame(tpAniSirGlobal pMac, psessionEntry->peSessionId, pMacHdr->fc.subType)); lim_diag_mgmt_tx_event_report(pMac, pMacHdr, - psessionEntry, eSIR_SUCCESS, - eSIR_SUCCESS); + psessionEntry, QDF_STATUS_SUCCESS, + QDF_STATUS_SUCCESS); /* Queue Disassociation frame in high priority WQ */ /* get the duration from the request */ qdf_status = @@ -2889,7 +2889,7 @@ lim_send_disassoc_mgmt_frame(tpAniSirGlobal pMac, pMacHdr->fc.subType)); lim_diag_mgmt_tx_event_report(pMac, pMacHdr, psessionEntry, - eSIR_SUCCESS, eSIR_SUCCESS); + QDF_STATUS_SUCCESS, QDF_STATUS_SUCCESS); /* Queue Disassociation frame in high priority WQ */ qdf_status = wma_tx_frame(pMac, pPacket, (uint16_t) nBytes, TXRX_FRM_802_11_MGMT, @@ -3037,7 +3037,7 @@ lim_send_deauth_mgmt_frame(tpAniSirGlobal pMac, pMacHdr->fc.subType)); lim_diag_mgmt_tx_event_report(pMac, pMacHdr, psessionEntry, - eSIR_SUCCESS, eSIR_SUCCESS); + QDF_STATUS_SUCCESS, QDF_STATUS_SUCCESS); /* Queue Disassociation frame in high priority WQ */ qdf_status = wma_tx_frameWithTxComplete(pMac, pPacket, (uint16_t) nBytes, @@ -3086,8 +3086,8 @@ lim_send_deauth_mgmt_frame(tpAniSirGlobal pMac, /* Queue Disassociation frame in high priority WQ */ lim_diag_mgmt_tx_event_report(pMac, pMacHdr, psessionEntry, - eSIR_SUCCESS, - eSIR_SUCCESS); + QDF_STATUS_SUCCESS, + QDF_STATUS_SUCCESS); qdf_status = wma_tx_frame(pMac, pPacket, (uint16_t) nBytes, TXRX_FRM_802_11_MGMT, ANI_TXDIR_IBSS, @@ -3097,8 +3097,8 @@ lim_send_deauth_mgmt_frame(tpAniSirGlobal pMac, #endif lim_diag_mgmt_tx_event_report(pMac, pMacHdr, psessionEntry, - eSIR_SUCCESS, - eSIR_SUCCESS); + QDF_STATUS_SUCCESS, + QDF_STATUS_SUCCESS); /* Queue Disassociation frame in high priority WQ */ qdf_status = wma_tx_frame(pMac, pPacket, (uint16_t) nBytes, @@ -3128,19 +3128,19 @@ lim_send_deauth_mgmt_frame(tpAniSirGlobal pMac, * * \param pMeasReqFrame Address of a tSirMacMeasReqActionFrame * - * \return eSIR_SUCCESS on success, eSIR_FAILURE else + * \return QDF_STATUS_SUCCESS on success, QDF_STATUS_E_FAILURE else * * */ -tSirRetStatus +QDF_STATUS lim_send_meas_report_frame(tpAniSirGlobal pMac, tpSirMacMeasReqActionFrame pMeasReqFrame, tSirMacAddr peer, tpPESession psessionEntry) { tDot11fMeasurementReport frm; uint8_t *pFrame; - tSirRetStatus nSirStatus; + QDF_STATUS nSirStatus; tpSirMacMgmtHdr pMacHdr; uint32_t nBytes, nPayload, nStatus; void *pPacket; @@ -3172,11 +3172,11 @@ lim_send_meas_report_frame(tpAniSirGlobal pMac, pe_err("Unknown measurement type %d in limSen" "dMeasReportFrame", pMeasReqFrame->measReqIE.measType); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } - if (eSIR_SUCCESS != nSirStatus) - return eSIR_FAILURE; + if (QDF_STATUS_SUCCESS != nSirStatus) + return QDF_STATUS_E_FAILURE; nStatus = dot11f_get_packed_measurement_report_size(pMac, &frm, &nPayload); if (DOT11F_FAILED(nStatus)) { @@ -3198,7 +3198,7 @@ lim_send_meas_report_frame(tpAniSirGlobal pMac, if (!QDF_IS_STATUS_SUCCESS(qdf_status)) { pe_err("Failed to allocate %d bytes for a " "De-Authentication", nBytes); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } /* Paranoia: */ qdf_mem_set(pFrame, nBytes, 0); @@ -3222,7 +3222,7 @@ lim_send_meas_report_frame(tpAniSirGlobal pMac, nStatus); cds_packet_free(pMac->hHdd, TXRX_FRM_802_11_MGMT, (void *)pFrame, (void *)pPacket); - return eSIR_FAILURE; /* allocated! */ + return QDF_STATUS_E_FAILURE; /* allocated! */ } else if (DOT11F_WARNED(nStatus)) { pe_warn("There were warnings while packing a Measurement Report (0x%08x)", nStatus); @@ -3243,10 +3243,10 @@ lim_send_meas_report_frame(tpAniSirGlobal pMac, pe_err("Failed to send a Measurement Report (%X)!", qdf_status); /* Pkt will be freed up by the callback */ - return eSIR_FAILURE; /* just allocated... */ + return QDF_STATUS_E_FAILURE; /* just allocated... */ } - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /* End lim_send_meas_report_frame. */ @@ -3355,12 +3355,12 @@ lim_send_tpc_request_frame(tpAniSirGlobal pMac, * * \param pTpcReqFrame Pointer to the received TPC Request * - * \return eSIR_SUCCESS on success, eSIR_FAILURE else + * \return QDF_STATUS_SUCCESS on success, QDF_STATUS_E_FAILURE else * * */ -tSirRetStatus +QDF_STATUS lim_send_tpc_report_frame(tpAniSirGlobal pMac, tpSirMacTpcReqActionFrame pTpcReqFrame, tSirMacAddr peer, tpPESession psessionEntry) @@ -3401,7 +3401,7 @@ lim_send_tpc_report_frame(tpAniSirGlobal pMac, if (!QDF_IS_STATUS_SUCCESS(qdf_status)) { pe_err("Failed to allocate %d bytes for a TPC" " Report", nBytes); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } /* Paranoia: */ qdf_mem_set(pFrame, nBytes, 0); @@ -3426,7 +3426,7 @@ lim_send_tpc_report_frame(tpAniSirGlobal pMac, nStatus); cds_packet_free(pMac->hHdd, TXRX_FRM_802_11_MGMT, (void *)pFrame, (void *)pPacket); - return eSIR_FAILURE; /* allocated! */ + return QDF_STATUS_E_FAILURE; /* allocated! */ } else if (DOT11F_WARNED(nStatus)) { pe_warn("There were warnings while packing a TPC Report (0x%08x)", nStatus); @@ -3446,10 +3446,10 @@ lim_send_tpc_report_frame(tpAniSirGlobal pMac, pe_err("Failed to send a TPC Report (%X)!", qdf_status); /* Pkt will be freed up by the callback */ - return eSIR_FAILURE; /* just allocated... */ + return QDF_STATUS_E_FAILURE; /* just allocated... */ } - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /* End lim_send_tpc_report_frame. */ #endif /* ANI_SUPPORT_11H */ @@ -3468,12 +3468,12 @@ lim_send_tpc_report_frame(tpAniSirGlobal pMac, * * \param nCount * - * \return eSIR_SUCCESS on success, eSIR_FAILURE else + * \return QDF_STATUS_SUCCESS on success, QDF_STATUS_E_FAILURE else * * */ -tSirRetStatus +QDF_STATUS lim_send_channel_switch_mgmt_frame(tpAniSirGlobal pMac, tSirMacAddr peer, uint8_t nMode, @@ -3492,7 +3492,7 @@ lim_send_channel_switch_mgmt_frame(tpAniSirGlobal pMac, if (psessionEntry == NULL) { pe_err("Session entry is NULL!!!"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } smeSessionId = psessionEntry->smeSessionId; @@ -3523,7 +3523,7 @@ lim_send_channel_switch_mgmt_frame(tpAniSirGlobal pMac, (void **)&pPacket); if (!QDF_IS_STATUS_SUCCESS(qdf_status)) { pe_err("Failed to allocate %d bytes for a TPC Report", nBytes); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } /* Paranoia: */ qdf_mem_set(pFrame, nBytes, 0); @@ -3547,7 +3547,7 @@ lim_send_channel_switch_mgmt_frame(tpAniSirGlobal pMac, pe_err("Failed to pack a Channel Switch (0x%08x)", nStatus); cds_packet_free((void *)pPacket); - return eSIR_FAILURE; /* allocated! */ + return QDF_STATUS_E_FAILURE; /* allocated! */ } else if (DOT11F_WARNED(nStatus)) { pe_warn("There were warnings while packing a Channel Switch (0x%08x)", nStatus); @@ -3573,10 +3573,10 @@ lim_send_channel_switch_mgmt_frame(tpAniSirGlobal pMac, pe_err("Failed to send a Channel Switch (%X)!", qdf_status); /* Pkt will be freed up by the callback */ - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /* End lim_send_channel_switch_mgmt_frame. */ @@ -3595,7 +3595,7 @@ lim_send_channel_switch_mgmt_frame(tpAniSirGlobal pMac, * Return: success if frame is sent else return failure */ -tSirRetStatus +QDF_STATUS lim_send_extended_chan_switch_action_frame(tpAniSirGlobal mac_ctx, tSirMacAddr peer, uint8_t mode, uint8_t new_op_class, uint8_t new_channel, uint8_t count, tpPESession session_entry) @@ -3613,7 +3613,7 @@ lim_send_extended_chan_switch_action_frame(tpAniSirGlobal mac_ctx, if (session_entry == NULL) { pe_err("Session entry is NULL!!!"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } sme_session_id = session_entry->smeSessionId; @@ -3668,7 +3668,7 @@ lim_send_extended_chan_switch_action_frame(tpAniSirGlobal mac_ctx, if (!QDF_IS_STATUS_SUCCESS(qdf_status)) { pe_err("Failed to allocate %d bytes for a Ext Channel Switch", num_bytes); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } /* Paranoia*/ @@ -3687,7 +3687,7 @@ lim_send_extended_chan_switch_action_frame(tpAniSirGlobal mac_ctx, if (DOT11F_FAILED(status)) { pe_err("Failed to pack a Channel Switch 0x%08x", status); cds_packet_free((void *)packet); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } else if (DOT11F_WARNED(status)) { pe_warn("There were warnings while packing a Channel Switch 0x%08x", status); @@ -3722,9 +3722,9 @@ lim_send_extended_chan_switch_action_frame(tpAniSirGlobal mac_ctx, pe_err("Failed to send a Ext Channel Switch %X!", qdf_status); /* Pkt will be freed up by the callback */ - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /* End lim_send_extended_chan_switch_action_frame */ @@ -3764,7 +3764,7 @@ static QDF_STATUS lim_oper_chan_change_confirm_tx_complete_cnf( * Return: success if frame is sent else return failure */ -tSirRetStatus +QDF_STATUS lim_p2p_oper_chan_change_confirm_action_frame(tpAniSirGlobal mac_ctx, tSirMacAddr peer, tpPESession session_entry) { @@ -3779,7 +3779,7 @@ lim_p2p_oper_chan_change_confirm_action_frame(tpAniSirGlobal mac_ctx, if (session_entry == NULL) { pe_err("Session entry is NULL!!!"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } sme_session_id = session_entry->smeSessionId; @@ -3823,7 +3823,7 @@ lim_p2p_oper_chan_change_confirm_action_frame(tpAniSirGlobal mac_ctx, if (!QDF_IS_STATUS_SUCCESS(qdf_status)) { pe_err("Failed to allocate %d bytes", num_bytes); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } qdf_mem_set(frame, num_bytes, 0); @@ -3841,7 +3841,7 @@ lim_p2p_oper_chan_change_confirm_action_frame(tpAniSirGlobal mac_ctx, if (DOT11F_FAILED(status)) { pe_err("Failed to pack 0x%08x", status); cds_packet_free((void *)packet); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } else if (DOT11F_WARNED(status)) { pe_warn("There were warnings while packing 0x%08x", status); @@ -3872,13 +3872,13 @@ lim_p2p_oper_chan_change_confirm_action_frame(tpAniSirGlobal mac_ctx, if (!QDF_IS_STATUS_SUCCESS(qdf_status)) { pe_err("Failed to send status %X!", qdf_status); /* Pkt will be freed up by the callback */ - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } -tSirRetStatus +QDF_STATUS lim_send_vht_opmode_notification_frame(tpAniSirGlobal pMac, tSirMacAddr peer, uint8_t nMode, tpPESession psessionEntry) @@ -3895,7 +3895,7 @@ lim_send_vht_opmode_notification_frame(tpAniSirGlobal pMac, if (psessionEntry == NULL) { pe_err("Session entry is NULL!!!"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } smeSessionId = psessionEntry->smeSessionId; @@ -3926,7 +3926,7 @@ lim_send_vht_opmode_notification_frame(tpAniSirGlobal pMac, if (!QDF_IS_STATUS_SUCCESS(qdf_status)) { pe_err("Failed to allocate %d bytes for a Operating Mode Report", nBytes); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } /* Paranoia: */ qdf_mem_set(pFrame, nBytes, 0); @@ -3950,7 +3950,7 @@ lim_send_vht_opmode_notification_frame(tpAniSirGlobal pMac, pe_err("Failed to pack a Operating Mode (0x%08x)", nStatus); cds_packet_free((void *)pPacket); - return eSIR_FAILURE; /* allocated! */ + return QDF_STATUS_E_FAILURE; /* allocated! */ } else if (DOT11F_WARNED(nStatus)) { pe_warn("There were warnings while packing a Operating Mode (0x%08x)", nStatus); @@ -3975,10 +3975,10 @@ lim_send_vht_opmode_notification_frame(tpAniSirGlobal pMac, pe_err("Failed to send a Channel Switch (%X)!", qdf_status); /* Pkt will be freed up by the callback */ - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /** @@ -3993,17 +3993,17 @@ lim_send_vht_opmode_notification_frame(tpAniSirGlobal pMac, * * \param psessionEntry address of session entry. * - * \return eSIR_SUCCESS on success, eSIR_FAILURE else + * \return QDF_STATUS_SUCCESS on success, QDF_STATUS_E_FAILURE else * * */ -tSirRetStatus +QDF_STATUS lim_send_neighbor_report_request_frame(tpAniSirGlobal pMac, tpSirMacNeighborReportReq pNeighborReq, tSirMacAddr peer, tpPESession psessionEntry) { - tSirRetStatus statusCode = eSIR_SUCCESS; + QDF_STATUS statusCode = QDF_STATUS_SUCCESS; tDot11fNeighborReportRequest frm; uint8_t *pFrame; tpSirMacMgmtHdr pMacHdr; @@ -4015,7 +4015,7 @@ lim_send_neighbor_report_request_frame(tpAniSirGlobal pMac, if (psessionEntry == NULL) { pe_err("(psession == NULL) in Request to send Neighbor Report request action frame"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } smeSessionId = psessionEntry->smeSessionId; qdf_mem_set((uint8_t *) &frm, sizeof(frm), 0); @@ -4048,7 +4048,7 @@ lim_send_neighbor_report_request_frame(tpAniSirGlobal pMac, if (!QDF_IS_STATUS_SUCCESS(qdf_status)) { pe_err("Failed to allocate %d bytes for a Neighbor " "Report Request", nBytes); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } /* Paranoia: */ qdf_mem_set(pFrame, nBytes, 0); @@ -4077,8 +4077,8 @@ lim_send_neighbor_report_request_frame(tpAniSirGlobal pMac, pe_err("Failed to pack an Neighbor Report Request (0x%08x)", nStatus); - /* FIXME - Need to convert to tSirRetStatus */ - statusCode = eSIR_FAILURE; + /* FIXME - Need to convert to QDF_STATUS */ + statusCode = QDF_STATUS_E_FAILURE; goto returnAfterError; } else if (DOT11F_WARNED(nStatus)) { pe_warn("There were warnings while packing Neighbor Report Request (0x%08x)", @@ -4108,11 +4108,11 @@ lim_send_neighbor_report_request_frame(tpAniSirGlobal pMac, psessionEntry->peSessionId, qdf_status)); if (QDF_STATUS_SUCCESS != qdf_status) { pe_err("wma_tx_frame FAILED! Status [%d]", qdf_status); - statusCode = eSIR_FAILURE; + statusCode = QDF_STATUS_E_FAILURE; /* Pkt will be freed up by the callback */ return statusCode; } else - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; returnAfterError: cds_packet_free((void *)pPacket); @@ -4132,17 +4132,17 @@ returnAfterError: * * \param psessionEntry address of session entry. * - * \return eSIR_SUCCESS on success, eSIR_FAILURE else + * \return QDF_STATUS_SUCCESS on success, QDF_STATUS_E_FAILURE else * * */ -tSirRetStatus +QDF_STATUS lim_send_link_report_action_frame(tpAniSirGlobal pMac, tpSirMacLinkReport pLinkReport, tSirMacAddr peer, tpPESession psessionEntry) { - tSirRetStatus statusCode = eSIR_SUCCESS; + QDF_STATUS statusCode = QDF_STATUS_SUCCESS; tDot11fLinkMeasurementReport frm; uint8_t *pFrame; tpSirMacMgmtHdr pMacHdr; @@ -4154,7 +4154,7 @@ lim_send_link_report_action_frame(tpAniSirGlobal pMac, if (psessionEntry == NULL) { pe_err("(psession == NULL) in Request to send Link Report action frame"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } qdf_mem_set((uint8_t *) &frm, sizeof(frm), 0); @@ -4197,7 +4197,7 @@ lim_send_link_report_action_frame(tpAniSirGlobal pMac, if (!QDF_IS_STATUS_SUCCESS(qdf_status)) { pe_err("Failed to allocate %d bytes for a Link " "Report", nBytes); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } /* Paranoia: */ qdf_mem_set(pFrame, nBytes, 0); @@ -4225,8 +4225,8 @@ lim_send_link_report_action_frame(tpAniSirGlobal pMac, if (DOT11F_FAILED(nStatus)) { pe_err("Failed to pack an Link Report (0x%08x)", nStatus); - /* FIXME - Need to convert to tSirRetStatus */ - statusCode = eSIR_FAILURE; + /* FIXME - Need to convert to QDF_STATUS */ + statusCode = QDF_STATUS_E_FAILURE; goto returnAfterError; } else if (DOT11F_WARNED(nStatus)) { pe_warn("There were warnings while packing Link Report (0x%08x)", @@ -4255,11 +4255,11 @@ lim_send_link_report_action_frame(tpAniSirGlobal pMac, psessionEntry->peSessionId, qdf_status)); if (QDF_STATUS_SUCCESS != qdf_status) { pe_err("wma_tx_frame FAILED! Status [%d]", qdf_status); - statusCode = eSIR_FAILURE; + statusCode = QDF_STATUS_E_FAILURE; /* Pkt will be freed up by the callback */ return statusCode; } else - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; returnAfterError: cds_packet_free((void *)pPacket); @@ -4267,7 +4267,7 @@ returnAfterError: return statusCode; } /* End lim_send_link_report_action_frame. */ -tSirRetStatus +QDF_STATUS lim_send_radio_measure_report_action_frame(tpAniSirGlobal pMac, uint8_t dialog_token, uint8_t num_report, @@ -4277,7 +4277,7 @@ lim_send_radio_measure_report_action_frame(tpAniSirGlobal pMac, tSirMacAddr peer, tpPESession psessionEntry) { - tSirRetStatus statusCode = eSIR_SUCCESS; + QDF_STATUS statusCode = QDF_STATUS_SUCCESS; uint8_t *pFrame; tpSirMacMgmtHdr pMacHdr; uint32_t nBytes, nPayload, nStatus; @@ -4291,13 +4291,13 @@ lim_send_radio_measure_report_action_frame(tpAniSirGlobal pMac, qdf_mem_malloc(sizeof(tDot11fRadioMeasurementReport)); if (!frm) { pe_err("Not enough memory to allocate tDot11fRadioMeasurementReport"); - return eSIR_MEM_ALLOC_FAILED; + return QDF_STATUS_E_NOMEM; } if (psessionEntry == NULL) { pe_err("(psession == NULL) in Request to send Beacon Report action frame"); qdf_mem_free(frm); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } smeSessionId = psessionEntry->smeSessionId; @@ -4349,7 +4349,7 @@ lim_send_radio_measure_report_action_frame(tpAniSirGlobal pMac, /* We'll fall back on the worst case scenario: */ nPayload = sizeof(tDot11fLinkMeasurementReport); qdf_mem_free(frm); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } else if (DOT11F_WARNED(nStatus)) { pe_warn("There were warnings while calculating the packed size for a Radio Measure Report (0x%08x)", nStatus); @@ -4364,7 +4364,7 @@ lim_send_radio_measure_report_action_frame(tpAniSirGlobal pMac, pe_err("Failed to allocate %d bytes for a Radio Measure " "Report", nBytes); qdf_mem_free(frm); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } /* Paranoia: */ qdf_mem_set(pFrame, nBytes, 0); @@ -4393,8 +4393,8 @@ lim_send_radio_measure_report_action_frame(tpAniSirGlobal pMac, pe_err("Failed to pack an Radio Measure Report (0x%08x)", nStatus); - /* FIXME - Need to convert to tSirRetStatus */ - statusCode = eSIR_FAILURE; + /* FIXME - Need to convert to QDF_STATUS */ + statusCode = QDF_STATUS_E_FAILURE; goto returnAfterError; } else if (DOT11F_WARNED(nStatus)) { pe_warn("There were warnings while packing Radio Measure Report (0x%08x)", @@ -4424,13 +4424,13 @@ lim_send_radio_measure_report_action_frame(tpAniSirGlobal pMac, psessionEntry->peSessionId, qdf_status)); if (QDF_STATUS_SUCCESS != qdf_status) { pe_err("wma_tx_frame FAILED! Status [%d]", qdf_status); - statusCode = eSIR_FAILURE; + statusCode = QDF_STATUS_E_FAILURE; /* Pkt will be freed up by the callback */ qdf_mem_free(frm); return statusCode; } else { qdf_mem_free(frm); - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } returnAfterError: @@ -4454,18 +4454,18 @@ returnAfterError: * * \param psessionEntry The PE session entry * - * \return eSIR_SUCCESS if setup completes successfully - * eSIR_FAILURE is some problem is encountered + * \return QDF_STATUS_SUCCESS if setup completes successfully + * QDF_STATUS_E_FAILURE is some problem is encountered */ -tSirRetStatus lim_send_sa_query_request_frame(tpAniSirGlobal pMac, uint8_t *transId, +QDF_STATUS lim_send_sa_query_request_frame(tpAniSirGlobal pMac, uint8_t *transId, tSirMacAddr peer, tpPESession psessionEntry) { tDot11fSaQueryReq frm; /* SA query request action frame */ uint8_t *pFrame; - tSirRetStatus nSirStatus; + QDF_STATUS nSirStatus; tpSirMacMgmtHdr pMacHdr; uint32_t nBytes, nPayload, nStatus; void *pPacket; @@ -4499,7 +4499,7 @@ tSirRetStatus lim_send_sa_query_request_frame(tpAniSirGlobal pMac, uint8_t *tran if (!QDF_IS_STATUS_SUCCESS(qdf_status)) { pe_err("Failed to allocate %d bytes for a SA Query Request " "action frame", nBytes); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } /* Paranoia: */ qdf_mem_set(pFrame, nBytes, 0); @@ -4526,8 +4526,8 @@ tSirRetStatus lim_send_sa_query_request_frame(tpAniSirGlobal pMac, uint8_t *tran if (DOT11F_FAILED(nStatus)) { pe_err("Failed to pack an SA Query Request (0x%08x)", nStatus); - /* FIXME - Need to convert to tSirRetStatus */ - nSirStatus = eSIR_FAILURE; + /* FIXME - Need to convert to QDF_STATUS */ + nSirStatus = QDF_STATUS_E_FAILURE; goto returnAfterError; } else if (DOT11F_WARNED(nStatus)) { pe_warn("There were warnings while packing SA Query Request (0x%08x)", @@ -4558,11 +4558,11 @@ tSirRetStatus lim_send_sa_query_request_frame(tpAniSirGlobal pMac, uint8_t *tran smeSessionId, 0, RATEID_DEFAULT); if (QDF_STATUS_SUCCESS != qdf_status) { pe_err("wma_tx_frame FAILED! Status [%d]", qdf_status); - nSirStatus = eSIR_FAILURE; + nSirStatus = QDF_STATUS_E_FAILURE; /* Pkt will be freed up by the callback */ return nSirStatus; } else { - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } returnAfterError: @@ -4584,18 +4584,18 @@ returnAfterError: * * \param psessionEntry The PE session entry * - * \return eSIR_SUCCESS if setup completes successfully - * eSIR_FAILURE is some problem is encountered + * \return QDF_STATUS_SUCCESS if setup completes successfully + * QDF_STATUS_E_FAILURE is some problem is encountered */ -tSirRetStatus lim_send_sa_query_response_frame(tpAniSirGlobal pMac, +QDF_STATUS lim_send_sa_query_response_frame(tpAniSirGlobal pMac, uint8_t *transId, tSirMacAddr peer, tpPESession psessionEntry) { tDot11fSaQueryRsp frm; /* SA query response action frame */ uint8_t *pFrame; - tSirRetStatus nSirStatus; + QDF_STATUS nSirStatus; tpSirMacMgmtHdr pMacHdr; uint32_t nBytes, nPayload, nStatus; void *pPacket; @@ -4632,7 +4632,7 @@ tSirRetStatus lim_send_sa_query_response_frame(tpAniSirGlobal pMac, if (!QDF_IS_STATUS_SUCCESS(qdf_status)) { pe_err("Failed to allocate %d bytes for a SA query response" " action frame", nBytes); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } /* Paranoia: */ qdf_mem_set(pFrame, nBytes, 0); @@ -4659,8 +4659,8 @@ tSirRetStatus lim_send_sa_query_response_frame(tpAniSirGlobal pMac, if (DOT11F_FAILED(nStatus)) { pe_err("Failed to pack an SA Query Response (0x%08x)", nStatus); - /* FIXME - Need to convert to tSirRetStatus */ - nSirStatus = eSIR_FAILURE; + /* FIXME - Need to convert to QDF_STATUS */ + nSirStatus = QDF_STATUS_E_FAILURE; goto returnAfterError; } else if (DOT11F_WARNED(nStatus)) { pe_warn("There were warnings while packing SA Query Response (0x%08x)", @@ -4692,11 +4692,11 @@ tSirRetStatus lim_send_sa_query_response_frame(tpAniSirGlobal pMac, psessionEntry->peSessionId, qdf_status)); if (QDF_STATUS_SUCCESS != qdf_status) { pe_err("wma_tx_frame FAILED! Status [%d]", qdf_status); - nSirStatus = eSIR_FAILURE; + nSirStatus = QDF_STATUS_E_FAILURE; /* Pkt will be freed up by the callback */ return nSirStatus; } else { - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } returnAfterError: @@ -4934,7 +4934,7 @@ static void lim_tx_mgmt_frame(tpAniSirGlobal mac_ctx, mac_ctx->auth_ack_status = LIM_AUTH_ACK_RCD_FAILURE; auth_ack_status = SENT_FAIL; lim_diag_event_report(mac_ctx, WLAN_PE_DIAG_AUTH_ACK_EVENT, - session, auth_ack_status, eSIR_FAILURE); + session, auth_ack_status, QDF_STATUS_E_FAILURE); /* Pkt will be freed up by the callback */ } } diff --git a/core/mac/src/pe/lim/lim_send_messages.c b/core/mac/src/pe/lim/lim_send_messages.c index d395594464..661ff19b96 100644 --- a/core/mac/src/pe/lim/lim_send_messages.c +++ b/core/mac/src/pe/lim/lim_send_messages.c @@ -57,17 +57,17 @@ * * @return success if message send is ok, else false. */ -tSirRetStatus lim_send_cf_params(tpAniSirGlobal pMac, uint8_t bssIdx, +QDF_STATUS lim_send_cf_params(tpAniSirGlobal pMac, uint8_t bssIdx, uint8_t cfpCount, uint8_t cfpPeriod) { tpUpdateCFParams pCFParams = NULL; - tSirRetStatus retCode = eSIR_SUCCESS; + QDF_STATUS retCode = QDF_STATUS_SUCCESS; struct scheduler_msg msgQ = {0}; pCFParams = qdf_mem_malloc(sizeof(tUpdateCFParams)); if (NULL == pCFParams) { pe_err("Unable to allocate memory during Update CF Params"); - retCode = eSIR_MEM_ALLOC_FAILED; + retCode = QDF_STATUS_E_NOMEM; goto returnFailure; } pCFParams->cfpCount = cfpCount; @@ -81,7 +81,7 @@ tSirRetStatus lim_send_cf_params(tpAniSirGlobal pMac, uint8_t bssIdx, pe_debug("Sending WMA_UPDATE_CF_IND"); MTRACE(mac_trace_msg_tx(pMac, NO_SESSION, msgQ.type)); retCode = wma_post_ctrl_msg(pMac, &msgQ); - if (eSIR_SUCCESS != retCode) { + if (QDF_STATUS_SUCCESS != retCode) { qdf_mem_free(pCFParams); pe_err("Posting WMA_UPDATE_CF_IND failed, reason=%X", retCode); @@ -102,18 +102,18 @@ returnFailure: * * @return success if message send is ok, else false. */ -tSirRetStatus lim_send_beacon_params(tpAniSirGlobal pMac, +QDF_STATUS lim_send_beacon_params(tpAniSirGlobal pMac, tpUpdateBeaconParams pUpdatedBcnParams, tpPESession psessionEntry) { tpUpdateBeaconParams pBcnParams = NULL; - tSirRetStatus retCode = eSIR_SUCCESS; + QDF_STATUS retCode = QDF_STATUS_SUCCESS; struct scheduler_msg msgQ = {0}; pBcnParams = qdf_mem_malloc(sizeof(*pBcnParams)); if (NULL == pBcnParams) { pe_err("Unable to allocate memory during Update Beacon Params"); - return eSIR_MEM_ALLOC_FAILED; + return QDF_STATUS_E_NOMEM; } qdf_mem_copy((uint8_t *) pBcnParams, pUpdatedBcnParams, sizeof(*pBcnParams)); @@ -126,7 +126,7 @@ tSirRetStatus lim_send_beacon_params(tpAniSirGlobal pMac, if (NULL == psessionEntry) { qdf_mem_free(pBcnParams); MTRACE(mac_trace_msg_tx(pMac, NO_SESSION, msgQ.type)); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } else { MTRACE(mac_trace_msg_tx(pMac, psessionEntry->peSessionId, @@ -134,7 +134,7 @@ tSirRetStatus lim_send_beacon_params(tpAniSirGlobal pMac, } pBcnParams->smeSessionId = psessionEntry->smeSessionId; retCode = wma_post_ctrl_msg(pMac, &msgQ); - if (eSIR_SUCCESS != retCode) { + if (QDF_STATUS_SUCCESS != retCode) { qdf_mem_free(pBcnParams); pe_err("Posting WMA_UPDATE_BEACON_IND, reason=%X", retCode); @@ -164,7 +164,7 @@ tSirRetStatus lim_send_beacon_params(tpAniSirGlobal pMac, * * @return success if message send is ok, else false. */ -tSirRetStatus lim_send_switch_chnl_params(tpAniSirGlobal pMac, +QDF_STATUS lim_send_switch_chnl_params(tpAniSirGlobal pMac, uint8_t chnlNumber, uint8_t ch_center_freq_seg0, uint8_t ch_center_freq_seg1, @@ -183,12 +183,12 @@ tSirRetStatus lim_send_switch_chnl_params(tpAniSirGlobal pMac, if (pSessionEntry == NULL) { pe_err("Unable to get Session for session Id %d", peSessionId); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } pChnlParams = qdf_mem_malloc(sizeof(tSwitchChannelParams)); if (NULL == pChnlParams) { pe_err("Unable to allocate memory for Switch Ch Params"); - return eSIR_MEM_ALLOC_FAILED; + return QDF_STATUS_E_NOMEM; } pChnlParams->channelNumber = chnlNumber; pChnlParams->ch_center_freq_seg0 = ch_center_freq_seg0; @@ -252,13 +252,13 @@ tSirRetStatus lim_send_switch_chnl_params(tpAniSirGlobal pMac, pChnlParams->ch_width, pChnlParams->channelNumber, pChnlParams->maxTxPower); MTRACE(mac_trace_msg_tx(pMac, peSessionId, msgQ.type)); - if (eSIR_SUCCESS != wma_post_ctrl_msg(pMac, &msgQ)) { + if (QDF_STATUS_SUCCESS != wma_post_ctrl_msg(pMac, &msgQ)) { qdf_mem_free(pChnlParams); pe_err("Posting CH_SWITCH_REQ to WMA failed"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } pSessionEntry->ch_switch_in_progress = true; - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /** @@ -282,18 +282,18 @@ tSirRetStatus lim_send_switch_chnl_params(tpAniSirGlobal pMac, * * @return success if message send is ok, else false. */ -tSirRetStatus lim_send_edca_params(tpAniSirGlobal pMac, +QDF_STATUS lim_send_edca_params(tpAniSirGlobal pMac, tSirMacEdcaParamRecord *pUpdatedEdcaParams, uint16_t bssIdx, bool mu_edca) { tEdcaParams *pEdcaParams = NULL; - tSirRetStatus retCode = eSIR_SUCCESS; + QDF_STATUS retCode = QDF_STATUS_SUCCESS; struct scheduler_msg msgQ = {0}; pEdcaParams = qdf_mem_malloc(sizeof(tEdcaParams)); if (NULL == pEdcaParams) { pe_err("Unable to allocate memory during Update EDCA Params"); - retCode = eSIR_MEM_ALLOC_FAILED; + retCode = QDF_STATUS_E_NOMEM; return retCode; } pEdcaParams->bssIdx = bssIdx; @@ -309,7 +309,7 @@ tSirRetStatus lim_send_edca_params(tpAniSirGlobal pMac, pe_debug("Sending WMA_UPDATE_EDCA_PROFILE_IND"); MTRACE(mac_trace_msg_tx(pMac, NO_SESSION, msgQ.type)); retCode = wma_post_ctrl_msg(pMac, &msgQ); - if (eSIR_SUCCESS != retCode) { + if (QDF_STATUS_SUCCESS != retCode) { qdf_mem_free(pEdcaParams); pe_err("Posting WMA_UPDATE_EDCA_PROFILE_IND failed, reason=%X", retCode); @@ -440,19 +440,19 @@ void lim_set_active_edca_params(tpAniSirGlobal mac_ctx, \param tSirLinkState state \return None -----------------------------------------------------------*/ -tSirRetStatus lim_set_link_state(tpAniSirGlobal pMac, tSirLinkState state, +QDF_STATUS lim_set_link_state(tpAniSirGlobal pMac, tSirLinkState state, tSirMacAddr bssId, tSirMacAddr selfMacAddr, tpSetLinkStateCallback callback, void *callbackArg) { struct scheduler_msg msgQ = {0}; - tSirRetStatus retCode; + QDF_STATUS retCode; tpLinkStateParams pLinkStateParams = NULL; /* Allocate memory. */ pLinkStateParams = qdf_mem_malloc(sizeof(tLinkStateParams)); if (NULL == pLinkStateParams) { pe_err("Unable to allocate memory while sending Set Link State"); - retCode = eSIR_MEM_ALLOC_FAILED; + retCode = QDF_STATUS_E_NOMEM; return retCode; } pLinkStateParams->state = state; @@ -471,7 +471,7 @@ tSirRetStatus lim_set_link_state(tpAniSirGlobal pMac, tSirLinkState state, MTRACE(mac_trace_msg_tx(pMac, NO_SESSION, msgQ.type)); retCode = (uint32_t) wma_post_ctrl_msg(pMac, &msgQ); - if (retCode != eSIR_SUCCESS) { + if (retCode != QDF_STATUS_SUCCESS) { qdf_mem_free(pLinkStateParams); pe_err("Posting link state %d failed, reason = %x", state, retCode); @@ -479,19 +479,19 @@ tSirRetStatus lim_set_link_state(tpAniSirGlobal pMac, tSirLinkState state, return retCode; } -extern tSirRetStatus lim_set_link_state_ft(tpAniSirGlobal pMac, tSirLinkState +extern QDF_STATUS lim_set_link_state_ft(tpAniSirGlobal pMac, tSirLinkState state, tSirMacAddr bssId, tSirMacAddr selfMacAddr, int ft, tpPESession psessionEntry) { struct scheduler_msg msgQ = {0}; - tSirRetStatus retCode; + QDF_STATUS retCode; tpLinkStateParams pLinkStateParams = NULL; /* Allocate memory. */ pLinkStateParams = qdf_mem_malloc(sizeof(tLinkStateParams)); if (NULL == pLinkStateParams) { pe_err("Unable to allocate memory while sending Set Link State"); - retCode = eSIR_MEM_ALLOC_FAILED; + retCode = QDF_STATUS_E_NOMEM; return retCode; } pLinkStateParams->state = state; @@ -513,7 +513,7 @@ extern tSirRetStatus lim_set_link_state_ft(tpAniSirGlobal pMac, tSirLinkState } retCode = (uint32_t) wma_post_ctrl_msg(pMac, &msgQ); - if (retCode != eSIR_SUCCESS) { + if (retCode != QDF_STATUS_SUCCESS) { qdf_mem_free(pLinkStateParams); pe_err("Posting link state %d failed, reason = %x", state, retCode); @@ -521,18 +521,18 @@ extern tSirRetStatus lim_set_link_state_ft(tpAniSirGlobal pMac, tSirLinkState return retCode; } -tSirRetStatus lim_send_mode_update(tpAniSirGlobal pMac, +QDF_STATUS lim_send_mode_update(tpAniSirGlobal pMac, tUpdateVHTOpMode *pTempParam, tpPESession psessionEntry) { tUpdateVHTOpMode *pVhtOpMode = NULL; - tSirRetStatus retCode = eSIR_SUCCESS; + QDF_STATUS retCode = QDF_STATUS_SUCCESS; struct scheduler_msg msgQ = {0}; pVhtOpMode = qdf_mem_malloc(sizeof(tUpdateVHTOpMode)); if (NULL == pVhtOpMode) { pe_err("Unable to allocate memory during Update Op Mode"); - return eSIR_MEM_ALLOC_FAILED; + return QDF_STATUS_E_NOMEM; } qdf_mem_copy((uint8_t *) pVhtOpMode, pTempParam, sizeof(tUpdateVHTOpMode)); @@ -549,7 +549,7 @@ tSirRetStatus lim_send_mode_update(tpAniSirGlobal pMac, psessionEntry->peSessionId, msgQ.type)); retCode = wma_post_ctrl_msg(pMac, &msgQ); - if (eSIR_SUCCESS != retCode) { + if (QDF_STATUS_SUCCESS != retCode) { qdf_mem_free(pVhtOpMode); pe_err("Posting WMA_UPDATE_OP_MODE failed, reason=%X", retCode); @@ -558,18 +558,18 @@ tSirRetStatus lim_send_mode_update(tpAniSirGlobal pMac, return retCode; } -tSirRetStatus lim_send_rx_nss_update(tpAniSirGlobal pMac, +QDF_STATUS lim_send_rx_nss_update(tpAniSirGlobal pMac, tUpdateRxNss *pTempParam, tpPESession psessionEntry) { tUpdateRxNss *pRxNss = NULL; - tSirRetStatus retCode = eSIR_SUCCESS; + QDF_STATUS retCode = QDF_STATUS_SUCCESS; struct scheduler_msg msgQ = {0}; pRxNss = qdf_mem_malloc(sizeof(tUpdateRxNss)); if (NULL == pRxNss) { pe_err("Unable to allocate memory during Update Rx Nss"); - return eSIR_MEM_ALLOC_FAILED; + return QDF_STATUS_E_NOMEM; } qdf_mem_copy((uint8_t *) pRxNss, pTempParam, sizeof(tUpdateRxNss)); msgQ.type = WMA_UPDATE_RX_NSS; @@ -584,7 +584,7 @@ tSirRetStatus lim_send_rx_nss_update(tpAniSirGlobal pMac, psessionEntry->peSessionId, msgQ.type)); retCode = wma_post_ctrl_msg(pMac, &msgQ); - if (eSIR_SUCCESS != retCode) { + if (QDF_STATUS_SUCCESS != retCode) { qdf_mem_free(pRxNss); pe_err("Posting WMA_UPDATE_RX_NSS failed, reason=%X", retCode); @@ -593,18 +593,18 @@ tSirRetStatus lim_send_rx_nss_update(tpAniSirGlobal pMac, return retCode; } -tSirRetStatus lim_set_membership(tpAniSirGlobal pMac, +QDF_STATUS lim_set_membership(tpAniSirGlobal pMac, tUpdateMembership *pTempParam, tpPESession psessionEntry) { tUpdateMembership *pMembership = NULL; - tSirRetStatus retCode = eSIR_SUCCESS; + QDF_STATUS retCode = QDF_STATUS_SUCCESS; struct scheduler_msg msgQ = {0}; pMembership = qdf_mem_malloc(sizeof(tUpdateMembership)); if (NULL == pMembership) { pe_err("Unable to allocate memory during Update Membership Mode"); - return eSIR_MEM_ALLOC_FAILED; + return QDF_STATUS_E_NOMEM; } qdf_mem_copy((uint8_t *) pMembership, pTempParam, sizeof(tUpdateMembership)); @@ -621,7 +621,7 @@ tSirRetStatus lim_set_membership(tpAniSirGlobal pMac, psessionEntry->peSessionId, msgQ.type)); retCode = wma_post_ctrl_msg(pMac, &msgQ); - if (eSIR_SUCCESS != retCode) { + if (QDF_STATUS_SUCCESS != retCode) { qdf_mem_free(pMembership); pe_err("Posting WMA_UPDATE_MEMBERSHIP failed, reason=%X", retCode); @@ -630,18 +630,18 @@ tSirRetStatus lim_set_membership(tpAniSirGlobal pMac, return retCode; } -tSirRetStatus lim_set_user_pos(tpAniSirGlobal pMac, +QDF_STATUS lim_set_user_pos(tpAniSirGlobal pMac, tUpdateUserPos *pTempParam, tpPESession psessionEntry) { tUpdateUserPos *pUserPos = NULL; - tSirRetStatus retCode = eSIR_SUCCESS; + QDF_STATUS retCode = QDF_STATUS_SUCCESS; struct scheduler_msg msgQ = {0}; pUserPos = qdf_mem_malloc(sizeof(tUpdateUserPos)); if (NULL == pUserPos) { pe_err("Unable to allocate memory during Update User Position"); - return eSIR_MEM_ALLOC_FAILED; + return QDF_STATUS_E_NOMEM; } qdf_mem_copy((uint8_t *) pUserPos, pTempParam, sizeof(tUpdateUserPos)); @@ -657,7 +657,7 @@ tSirRetStatus lim_set_user_pos(tpAniSirGlobal pMac, psessionEntry->peSessionId, msgQ.type)); retCode = wma_post_ctrl_msg(pMac, &msgQ); - if (eSIR_SUCCESS != retCode) { + if (QDF_STATUS_SUCCESS != retCode) { qdf_mem_free(pUserPos); pe_err("Posting WMA_UPDATE_USERPOS failed, reason=%X", retCode); @@ -678,11 +678,11 @@ tSirRetStatus lim_set_user_pos(tpAniSirGlobal pMac, * * Return: status of operation */ -tSirRetStatus lim_send_exclude_unencrypt_ind(tpAniSirGlobal pMac, +QDF_STATUS lim_send_exclude_unencrypt_ind(tpAniSirGlobal pMac, bool excludeUnenc, tpPESession psessionEntry) { - tSirRetStatus retCode = eSIR_SUCCESS; + QDF_STATUS retCode = QDF_STATUS_SUCCESS; struct scheduler_msg msgQ = {0}; tSirWlanExcludeUnencryptParam *pExcludeUnencryptParam; @@ -690,7 +690,7 @@ tSirRetStatus lim_send_exclude_unencrypt_ind(tpAniSirGlobal pMac, qdf_mem_malloc(sizeof(tSirWlanExcludeUnencryptParam)); if (NULL == pExcludeUnencryptParam) { pe_err("Unable to allocate memory during lim_send_exclude_unencrypt_ind"); - return eSIR_MEM_ALLOC_FAILED; + return QDF_STATUS_E_NOMEM; } pExcludeUnencryptParam->excludeUnencrypt = excludeUnenc; @@ -704,7 +704,7 @@ tSirRetStatus lim_send_exclude_unencrypt_ind(tpAniSirGlobal pMac, pe_debug("Sending WMA_EXCLUDE_UNENCRYPTED_IND"); MTRACE(mac_trace_msg_tx(pMac, psessionEntry->peSessionId, msgQ.type)); retCode = wma_post_ctrl_msg(pMac, &msgQ); - if (eSIR_SUCCESS != retCode) { + if (QDF_STATUS_SUCCESS != retCode) { qdf_mem_free(pExcludeUnencryptParam); pe_err("Posting WMA_EXCLUDE_UNENCRYPTED_IND failed, reason=%X", retCode); @@ -723,10 +723,10 @@ tSirRetStatus lim_send_exclude_unencrypt_ind(tpAniSirGlobal pMac, * * Return: status of operation */ -tSirRetStatus lim_send_ht40_obss_scanind(tpAniSirGlobal mac_ctx, +QDF_STATUS lim_send_ht40_obss_scanind(tpAniSirGlobal mac_ctx, struct sPESession *session) { - tSirRetStatus ret = eSIR_SUCCESS; + QDF_STATUS ret = QDF_STATUS_SUCCESS; struct obss_ht40_scanind *ht40_obss_scanind; uint32_t channelnum; struct scheduler_msg msg = {0}; @@ -737,7 +737,7 @@ tSirRetStatus lim_send_ht40_obss_scanind(tpAniSirGlobal mac_ctx, if (NULL == ht40_obss_scanind) { QDF_TRACE(QDF_MODULE_ID_PE, QDF_TRACE_LEVEL_ERROR, "Memory allocation failed"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } QDF_TRACE(QDF_MODULE_ID_PE, QDF_TRACE_LEVEL_ERROR, "OBSS Scan Indication bssIdx- %d staId %d", @@ -766,10 +766,10 @@ tSirRetStatus lim_send_ht40_obss_scanind(tpAniSirGlobal mac_ctx, session->ch_width); channelnum = WNI_CFG_VALID_CHANNEL_LIST_LEN; if (wlan_cfg_get_str(mac_ctx, WNI_CFG_VALID_CHANNEL_LIST, - chan_list, &channelnum) != eSIR_SUCCESS) { + chan_list, &channelnum) != QDF_STATUS_SUCCESS) { pe_err("could not retrieve Valid channel list"); qdf_mem_free(ht40_obss_scanind); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } /* Extract 24G channel list */ channel24gnum = 0; @@ -797,7 +797,7 @@ tSirRetStatus lim_send_ht40_obss_scanind(tpAniSirGlobal mac_ctx, ht40_obss_scanind->obss_width_trigger_interval, ht40_obss_scanind->bsswidth_ch_trans_delay); ret = wma_post_ctrl_msg(mac_ctx, &msg); - if (eSIR_SUCCESS != ret) { + if (QDF_STATUS_SUCCESS != ret) { pe_err("WDA_HT40_OBSS_SCAN_IND msg failed, reason=%X", ret); qdf_mem_free(ht40_obss_scanind); diff --git a/core/mac/src/pe/lim/lim_send_messages.h b/core/mac/src/pe/lim/lim_send_messages.h index b182f26930..6d3d405be9 100644 --- a/core/mac/src/pe/lim/lim_send_messages.h +++ b/core/mac/src/pe/lim/lim_send_messages.h @@ -34,27 +34,27 @@ #include "lim_types.h" #include "wma_if.h" #include "sir_params.h" -tSirRetStatus lim_send_cf_params(tpAniSirGlobal pMac, uint8_t bssIdx, +QDF_STATUS lim_send_cf_params(tpAniSirGlobal pMac, uint8_t bssIdx, uint8_t cfpCount, uint8_t cfpPeriod); -tSirRetStatus lim_send_beacon_params(tpAniSirGlobal pMac, +QDF_STATUS lim_send_beacon_params(tpAniSirGlobal pMac, tpUpdateBeaconParams pUpdatedBcnParams, tpPESession psessionEntry); -/* tSirRetStatus lim_send_beacon_params(tpAniSirGlobal pMac, tpUpdateBeaconParams pUpdatedBcnParams); */ -tSirRetStatus lim_send_mode_update(tpAniSirGlobal pMac, +/* QDF_STATUS lim_send_beacon_params(tpAniSirGlobal pMac, tpUpdateBeaconParams pUpdatedBcnParams); */ +QDF_STATUS lim_send_mode_update(tpAniSirGlobal pMac, tUpdateVHTOpMode *tempParam, tpPESession psessionEntry); -tSirRetStatus lim_send_rx_nss_update(tpAniSirGlobal pMac, +QDF_STATUS lim_send_rx_nss_update(tpAniSirGlobal pMac, tUpdateRxNss *tempParam, tpPESession psessionEntry); -tSirRetStatus lim_set_membership(tpAniSirGlobal pMac, +QDF_STATUS lim_set_membership(tpAniSirGlobal pMac, tUpdateMembership *pTempParam, tpPESession psessionEntry); -tSirRetStatus lim_set_user_pos(tpAniSirGlobal pMac, +QDF_STATUS lim_set_user_pos(tpAniSirGlobal pMac, tUpdateUserPos *pTempParam, tpPESession psessionEntry); -tSirRetStatus lim_send_switch_chnl_params(tpAniSirGlobal pMac, +QDF_STATUS lim_send_switch_chnl_params(tpAniSirGlobal pMac, uint8_t chnlNumber, uint8_t ch_center_freq_seg0, uint8_t ch_center_freq_seg1, @@ -65,14 +65,14 @@ tSirRetStatus lim_send_switch_chnl_params(tpAniSirGlobal pMac, uint32_t cac_duration_ms, uint32_t dfs_regdomain); -tSirRetStatus lim_send_edca_params(tpAniSirGlobal pMac, +QDF_STATUS lim_send_edca_params(tpAniSirGlobal pMac, tSirMacEdcaParamRecord *pUpdatedEdcaParams, uint16_t bssIdx, bool mu_edca); -tSirRetStatus lim_set_link_state(tpAniSirGlobal pMac, tSirLinkState state, +QDF_STATUS lim_set_link_state(tpAniSirGlobal pMac, tSirLinkState state, tSirMacAddr bssId, tSirMacAddr selfMac, tpSetLinkStateCallback callback, void *callbackArg); -extern tSirRetStatus lim_set_link_state_ft(tpAniSirGlobal pMac, tSirLinkState +extern QDF_STATUS lim_set_link_state_ft(tpAniSirGlobal pMac, tSirLinkState state, tSirMacAddr bssId, tSirMacAddr selfMacAddr, int ft, tpPESession psessionEntry); @@ -90,11 +90,11 @@ void lim_set_active_edca_params(tpAniSirGlobal pMac, #define VHTOP_CHWIDTH_MASK 0xFC #ifdef WLAN_FEATURE_11W -tSirRetStatus lim_send_exclude_unencrypt_ind(tpAniSirGlobal pMac, +QDF_STATUS lim_send_exclude_unencrypt_ind(tpAniSirGlobal pMac, bool excludeUnenc, tpPESession psessionEntry); #endif -tSirRetStatus lim_send_ht40_obss_scanind(tpAniSirGlobal mac_ctx, +QDF_STATUS lim_send_ht40_obss_scanind(tpAniSirGlobal mac_ctx, tpPESession session); void lim_handle_sme_join_result(tpAniSirGlobal, tSirResultCodes, uint16_t, tpPESession); 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 669f8aa6c3..5b37358454 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 @@ -663,7 +663,7 @@ lim_send_sme_start_bss_rsp(tpAniSirGlobal pMac, if (cfg_get_capability_info (pMac, &pSirSmeRsp->bssDescription.capabilityInfo, psessionEntry) - != eSIR_SUCCESS) + != QDF_STATUS_SUCCESS) pe_err("could not retrieve Capabilities value"); lim_get_phy_mode(pMac, @@ -840,7 +840,7 @@ lim_send_sme_disassoc_ntf(tpAniSirGlobal pMac, #endif ) { if (lim_add_sta(pMac, sta_ds, false, session) != - eSIR_SUCCESS) + QDF_STATUS_SUCCESS) pe_err("could not Add STA with assocId: %d", sta_ds->assocId); } @@ -1413,7 +1413,7 @@ lim_send_sme_wm_status_change_ntf(tpAniSirGlobal mac_ctx, } MTRACE(mac_trace(mac_ctx, TRACE_CODE_TX_SME_MSG, session_id, msg.type)); - if (eSIR_SUCCESS != lim_sys_process_mmh_msg_api(mac_ctx, &msg, ePROT)) { + if (QDF_STATUS_SUCCESS != lim_sys_process_mmh_msg_api(mac_ctx, &msg, ePROT)) { qdf_mem_free(wm_status_change_ntf); pe_err("lim_sys_process_mmh_msg_api failed"); } @@ -1619,7 +1619,7 @@ lim_send_sme_delts_ind(tpAniSirGlobal pMac, tpSirDeltsReqInfo delts, uint16_t ai } rsp->messageType = eWNI_SME_DELTS_IND; - rsp->rc = eSIR_SUCCESS; + rsp->rc = QDF_STATUS_SUCCESS; rsp->aid = aid; qdf_mem_copy((uint8_t *) &rsp->rsp, (uint8_t *) delts, sizeof(*delts)); @@ -2182,7 +2182,7 @@ void lim_handle_csa_offload_msg(tpAniSirGlobal mac_ctx, #ifdef FEATURE_WLAN_DIAG_SUPPORT lim_diag_event_report(mac_ctx, WLAN_PE_DIAG_SWITCH_CHL_IND_EVENT, session_entry, - eSIR_SUCCESS, eSIR_SUCCESS); + QDF_STATUS_SUCCESS, QDF_STATUS_SUCCESS); #endif lim_sys_process_mmh_msg_api(mac_ctx, &mmh_msg, ePROT); @@ -2298,7 +2298,7 @@ lim_send_dfs_chan_sw_ie_update(tpAniSirGlobal pMac, tpPESession psessionEntry) { /* Update the beacon template and send to FW */ - if (sch_set_fixed_beacon_fields(pMac, psessionEntry) != eSIR_SUCCESS) { + if (sch_set_fixed_beacon_fields(pMac, psessionEntry) != QDF_STATUS_SUCCESS) { pe_err("Unable to set CSA IE in beacon"); return; } @@ -2411,7 +2411,7 @@ lim_send_bss_color_change_ie_update(tpAniSirGlobal mac_ctx, tpPESession session) { /* Update the beacon template and send to FW */ - if (sch_set_fixed_beacon_fields(mac_ctx, session) != eSIR_SUCCESS) { + if (sch_set_fixed_beacon_fields(mac_ctx, session) != QDF_STATUS_SUCCESS) { pe_err("Unable to set BSS color change IE in beacon"); return; } diff --git a/core/mac/src/pe/lim/lim_ser_des_utils.c b/core/mac/src/pe/lim/lim_ser_des_utils.c index 61b3bc470a..a76d386ee4 100644 --- a/core/mac/src/pe/lim/lim_ser_des_utils.c +++ b/core/mac/src/pe/lim/lim_ser_des_utils.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2011-2017 The Linux Foundation. All rights reserved. + * Copyright (c) 2011-2018 The Linux Foundation. All rights reserved. * * Permission to use, copy, modify, and/or distribute this software for * any purpose with or without fee is hereby granted, provided that the @@ -76,16 +76,16 @@ lim_get_session_info(tpAniSirGlobal pMac, uint8_t *pBuf, uint8_t *sessionId, * * function send's disassoc frame request on receiving SME_DISASSOC_REQ * - * return: eSIR_SUCCESS:Success Error value: Failure + * return: QDF_STATUS_SUCCESS:Success Error value: Failure */ -tSirRetStatus lim_send_disassoc_frm_req_ser_des(tpAniSirGlobal mac_ctx, +QDF_STATUS lim_send_disassoc_frm_req_ser_des(tpAniSirGlobal mac_ctx, struct sme_send_disassoc_frm_req *disassoc_frm_req, uint8_t *buf) { A_INT16 len = 0; if (!disassoc_frm_req || !buf) - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; disassoc_frm_req->msg_type = lim_get_u16(buf); buf += sizeof(A_UINT16); @@ -94,19 +94,19 @@ tSirRetStatus lim_send_disassoc_frm_req_ser_des(tpAniSirGlobal mac_ctx, buf += sizeof(A_UINT16); if (len < (A_INT16) sizeof(A_UINT32)) - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; /* skip message header */ len -= sizeof(A_UINT32); if (len < 0) - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; /* Extract sessionID */ disassoc_frm_req->session_id = *buf; buf += sizeof(A_UINT8); len -= sizeof(A_UINT8); if (len < 0) - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; /* Extract transactionid */ disassoc_frm_req->trans_id = lim_get_u16(buf); @@ -114,7 +114,7 @@ tSirRetStatus lim_send_disassoc_frm_req_ser_des(tpAniSirGlobal mac_ctx, len -= sizeof(A_UINT16); if (len < 0) - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; /* Extract peerMacAddr */ qdf_mem_copy(disassoc_frm_req->peer_mac, buf, sizeof(tSirMacAddr)); @@ -122,7 +122,7 @@ tSirRetStatus lim_send_disassoc_frm_req_ser_des(tpAniSirGlobal mac_ctx, len -= sizeof(tSirMacAddr); if (len < 0) - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; /* Extract reasonCode */ disassoc_frm_req->reason = lim_get_u16(buf); @@ -130,11 +130,11 @@ tSirRetStatus lim_send_disassoc_frm_req_ser_des(tpAniSirGlobal mac_ctx, len -= sizeof(A_UINT16); if (len < 0) - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; disassoc_frm_req->wait_for_ack = *buf; buf += sizeof(A_UINT8); len -= sizeof(A_UINT8); - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } diff --git a/core/mac/src/pe/lim/lim_ser_des_utils.h b/core/mac/src/pe/lim/lim_ser_des_utils.h index 92b8f08ce4..eb5c036a15 100644 --- a/core/mac/src/pe/lim/lim_ser_des_utils.h +++ b/core/mac/src/pe/lim/lim_ser_des_utils.h @@ -111,7 +111,7 @@ static inline uint16_t lim_get_u16_be(uint8_t *buf) return (buf[0] << 8) | buf[1]; } -tSirRetStatus lim_send_disassoc_frm_req_ser_des(tpAniSirGlobal mac_ctx, +QDF_STATUS lim_send_disassoc_frm_req_ser_des(tpAniSirGlobal mac_ctx, struct sme_send_disassoc_frm_req *disassoc_frm_req, uint8_t *buf); diff --git a/core/mac/src/pe/lim/lim_sme_req_utils.c b/core/mac/src/pe/lim/lim_sme_req_utils.c index ac23b503d4..1d1f3e2fd0 100644 --- a/core/mac/src/pe/lim/lim_sme_req_utils.c +++ b/core/mac/src/pe/lim/lim_sme_req_utils.c @@ -63,11 +63,11 @@ lim_is_rsn_ie_valid_in_sme_req_message(tpAniSirGlobal mac_ctx, tpSirRSNie rsn_ie int len; if (wlan_cfg_get_int(mac_ctx, WNI_CFG_PRIVACY_ENABLED, - &privacy) != eSIR_SUCCESS) + &privacy) != QDF_STATUS_SUCCESS) pe_warn("Unable to retrieve POI from CFG"); if (wlan_cfg_get_int(mac_ctx, WNI_CFG_RSN_ENABLED, &val) - != eSIR_SUCCESS) + != QDF_STATUS_SUCCESS) pe_warn("Unable to retrieve RSN_ENABLED from CFG"); if (rsn_ie->length && (!privacy || !val)) { @@ -228,11 +228,11 @@ lim_set_rs_nie_wp_aiefrom_sme_start_bss_req_message(tpAniSirGlobal mac_ctx, uint32_t privacy, val; if (wlan_cfg_get_int(mac_ctx, WNI_CFG_PRIVACY_ENABLED, - &privacy) != eSIR_SUCCESS) + &privacy) != QDF_STATUS_SUCCESS) pe_warn("Unable to retrieve POI from CFG"); if (wlan_cfg_get_int(mac_ctx, WNI_CFG_RSN_ENABLED, - &val) != eSIR_SUCCESS) + &val) != QDF_STATUS_SUCCESS) pe_warn("Unable to retrieve RSN_ENABLED from CFG"); if (rsn_ie->length && (!privacy || !val)) { @@ -720,7 +720,7 @@ lim_is_sme_set_context_req_valid(tpAniSirGlobal pMac, uint32_t poi; if (wlan_cfg_get_int(pMac, WNI_CFG_PRIVACY_ENABLED, - &poi) != eSIR_SUCCESS) + &poi) != QDF_STATUS_SUCCESS) pe_warn("Unable to retrieve POI from CFG"); if (!poi) { diff --git a/core/mac/src/pe/lim/lim_sta_hash_api.c b/core/mac/src/pe/lim/lim_sta_hash_api.c index 22af0788c0..3fa1df7e31 100644 --- a/core/mac/src/pe/lim/lim_sta_hash_api.c +++ b/core/mac/src/pe/lim/lim_sta_hash_api.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2011-2012, 2017 The Linux Foundation. All rights reserved. + * Copyright (c) 2011-2012, 2017-2018 The Linux Foundation. All rights reserved. * * Permission to use, copy, modify, and/or distribute this software for * any purpose with or without fee is hereby granted, provided that the @@ -51,7 +51,7 @@ * @return success if GET operation is ok, else Failure. */ -tSirRetStatus lim_get_sta_hash_bssidx(tpAniSirGlobal pMac, uint16_t assocId, +QDF_STATUS lim_get_sta_hash_bssidx(tpAniSirGlobal pMac, uint16_t assocId, uint8_t *bssidx, tpPESession psessionEntry) { tpDphHashNode pSta = @@ -59,9 +59,9 @@ tSirRetStatus lim_get_sta_hash_bssidx(tpAniSirGlobal pMac, uint16_t assocId, if (pSta == NULL) { pe_err("invalid STA: %d", assocId); - return eSIR_LIM_INVALID_STA; + return QDF_STATUS_E_NOENT; } *bssidx = (uint8_t) pSta->bssId; - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } diff --git a/core/mac/src/pe/lim/lim_sta_hash_api.h b/core/mac/src/pe/lim/lim_sta_hash_api.h index 5f39bcc6da..ad02da7a7d 100644 --- a/core/mac/src/pe/lim/lim_sta_hash_api.h +++ b/core/mac/src/pe/lim/lim_sta_hash_api.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2011-2012, 2014 The Linux Foundation. All rights reserved. + * Copyright (c) 2011-2012, 2014, 2018 The Linux Foundation. All rights reserved. * * Permission to use, copy, modify, and/or distribute this software for * any purpose with or without fee is hereby granted, provided that the @@ -35,7 +35,7 @@ #include "ani_global.h" #include "lim_types.h" -tSirRetStatus lim_get_sta_hash_bssidx(tpAniSirGlobal pMac, uint16_t assocId, +QDF_STATUS lim_get_sta_hash_bssidx(tpAniSirGlobal pMac, uint16_t assocId, uint8_t *bssidx, tpPESession psessionEntry); #endif diff --git a/core/mac/src/pe/lim/lim_timer_utils.c b/core/mac/src/pe/lim/lim_timer_utils.c index 7eb49e731f..97f7db8d0e 100644 --- a/core/mac/src/pe/lim/lim_timer_utils.c +++ b/core/mac/src/pe/lim/lim_timer_utils.c @@ -93,7 +93,7 @@ static bool lim_create_non_ap_timers(tpAniSirGlobal pMac) } if (wlan_cfg_get_int(pMac, WNI_CFG_JOIN_FAILURE_TIMEOUT, - &cfgValue) != eSIR_SUCCESS) + &cfgValue) != QDF_STATUS_SUCCESS) pe_err("could not retrieve JoinFailureTimeout value"); cfgValue = SYS_MS_TO_TICKS(cfgValue); /* Create Join failure timer and activate it later */ @@ -131,7 +131,7 @@ static bool lim_create_non_ap_timers(tpAniSirGlobal pMac) } if (wlan_cfg_get_int(pMac, WNI_CFG_ASSOCIATION_FAILURE_TIMEOUT, - &cfgValue) != eSIR_SUCCESS) + &cfgValue) != QDF_STATUS_SUCCESS) pe_err("could not retrieve AssocFailureTimeout value"); cfgValue = SYS_MS_TO_TICKS(cfgValue); @@ -145,7 +145,7 @@ static bool lim_create_non_ap_timers(tpAniSirGlobal pMac) } if (wlan_cfg_get_int(pMac, WNI_CFG_ADDTS_RSP_TIMEOUT, &cfgValue) - != eSIR_SUCCESS) + != QDF_STATUS_SUCCESS) pe_err("Fail to get WNI_CFG_ADDTS_RSP_TIMEOUT"); cfgValue = SYS_MS_TO_TICKS(cfgValue); @@ -161,7 +161,7 @@ static bool lim_create_non_ap_timers(tpAniSirGlobal pMac) } if (wlan_cfg_get_int(pMac, WNI_CFG_AUTHENTICATE_FAILURE_TIMEOUT, - &cfgValue) != eSIR_SUCCESS) + &cfgValue) != QDF_STATUS_SUCCESS) pe_err("could not retrieve AuthFailureTimeout value"); cfgValue = SYS_MS_TO_TICKS(cfgValue); @@ -176,7 +176,7 @@ static bool lim_create_non_ap_timers(tpAniSirGlobal pMac) } if (wlan_cfg_get_int(pMac, WNI_CFG_PROBE_AFTER_HB_FAIL_TIMEOUT, - &cfgValue) != eSIR_SUCCESS) + &cfgValue) != QDF_STATUS_SUCCESS) pe_err("could not retrieve PROBE_AFTER_HB_FAIL_TIMEOUT value"); /* Change timer to reactivate it in future */ @@ -234,7 +234,7 @@ uint32_t lim_create_timers(tpAniSirGlobal pMac) /* Create all CNF_WAIT Timers upfront */ if (wlan_cfg_get_int(pMac, WNI_CFG_WT_CNF_TIMEOUT, &cfgValue) - != eSIR_SUCCESS) { + != QDF_STATUS_SUCCESS) { pe_err("could not retrieve CNF timeout value"); } @@ -253,7 +253,7 @@ uint32_t lim_create_timers(tpAniSirGlobal pMac) /* Alloc and init table for the preAuth timer list */ if (wlan_cfg_get_int(pMac, WNI_CFG_MAX_NUM_PRE_AUTH, - &cfgValue) != eSIR_SUCCESS) + &cfgValue) != QDF_STATUS_SUCCESS) pe_err("could not retrieve mac preauth value"); pMac->lim.gLimPreAuthTimerTable.numEntry = cfgValue; pMac->lim.gLimPreAuthTimerTable.pTable = @@ -278,7 +278,7 @@ uint32_t lim_create_timers(tpAniSirGlobal pMac) pe_debug("alloc and init table for preAuth timers"); if (wlan_cfg_get_int(pMac, WNI_CFG_OLBC_DETECT_TIMEOUT, - &cfgValue) != eSIR_SUCCESS) + &cfgValue) != QDF_STATUS_SUCCESS) pe_err("could not retrieve OLBD detect timeout value"); cfgValue = SYS_MS_TO_TICKS(cfgValue); @@ -393,7 +393,7 @@ void lim_timer_handler(void *pMacGlobal, uint32_t param) msg.bodyval = 0; statusCode = lim_post_msg_high_priority(pMac, &msg); - if (statusCode != eSIR_SUCCESS) + if (statusCode != QDF_STATUS_SUCCESS) pe_err("posting message: %X to LIM failed, reason: %d", msg.type, statusCode); } /****** end lim_timer_handler() ******/ @@ -604,7 +604,7 @@ void lim_deactivate_and_change_timer(tpAniSirGlobal pMac, uint32_t timerId) } if (wlan_cfg_get_int(pMac, WNI_CFG_JOIN_FAILURE_TIMEOUT, - &val) != eSIR_SUCCESS) { + &val) != QDF_STATUS_SUCCESS) { /** * Could not get JoinFailureTimeout value * from CFG. Log error. @@ -653,7 +653,7 @@ void lim_deactivate_and_change_timer(tpAniSirGlobal pMac, uint32_t timerId) } /* Change timer to reactivate it in future */ if (wlan_cfg_get_int(pMac, WNI_CFG_AUTHENTICATE_FAILURE_TIMEOUT, - &val) != eSIR_SUCCESS) { + &val) != QDF_STATUS_SUCCESS) { /** * Could not get AuthFailureTimeout value * from CFG. Log error. @@ -709,7 +709,7 @@ void lim_deactivate_and_change_timer(tpAniSirGlobal pMac, uint32_t timerId) } /* Change timer to reactivate it in future */ if (wlan_cfg_get_int(pMac, WNI_CFG_ASSOCIATION_FAILURE_TIMEOUT, - &val) != eSIR_SUCCESS) { + &val) != QDF_STATUS_SUCCESS) { /** * Could not get AssocFailureTimeout value * from CFG. Log error. @@ -739,7 +739,7 @@ void lim_deactivate_and_change_timer(tpAniSirGlobal pMac, uint32_t timerId) } if (wlan_cfg_get_int(pMac, WNI_CFG_PROBE_AFTER_HB_FAIL_TIMEOUT, - &val) != eSIR_SUCCESS) { + &val) != QDF_STATUS_SUCCESS) { /** * Could not get PROBE_AFTER_HB_FAILURE * value from CFG. Log error. @@ -895,7 +895,7 @@ lim_deactivate_and_change_per_sta_id_timer(tpAniSirGlobal pMac, uint32_t timerId /* Change timer to reactivate it in future */ if (wlan_cfg_get_int(pMac, WNI_CFG_WT_CNF_TIMEOUT, - &val) != eSIR_SUCCESS) { + &val) != QDF_STATUS_SUCCESS) { /** * Could not get cnf timeout value * from CFG. Log error. @@ -940,7 +940,7 @@ lim_deactivate_and_change_per_sta_id_timer(tpAniSirGlobal pMac, uint32_t timerId if (wlan_cfg_get_int (pMac, WNI_CFG_AUTHENTICATE_RSP_TIMEOUT, - &val) != eSIR_SUCCESS) { + &val) != QDF_STATUS_SUCCESS) { /** * Could not get auth rsp timeout value * from CFG. Log error. @@ -1055,7 +1055,7 @@ void lim_cnf_wait_tmer_handler(void *pMacGlobal, uint32_t param) msg.bodyptr = NULL; statusCode = lim_post_msg_api(pMac, &msg); - if (statusCode != eSIR_SUCCESS) + if (statusCode != QDF_STATUS_SUCCESS) pe_err("posting to LIM failed, reason: %d", statusCode); } diff --git a/core/mac/src/pe/lim/lim_types.h b/core/mac/src/pe/lim/lim_types.h index d7fccdea9f..4ab837ab3b 100644 --- a/core/mac/src/pe/lim/lim_types.h +++ b/core/mac/src/pe/lim/lim_types.h @@ -439,7 +439,7 @@ void lim_apply_configuration(tpAniSirGlobal, tpPESession); void lim_set_cfg_protection(tpAniSirGlobal pMac, tpPESession pesessionEntry); /* Function to Initialize MLM state machine on STA */ -tSirRetStatus lim_init_mlm(tpAniSirGlobal); +QDF_STATUS lim_init_mlm(tpAniSirGlobal); /* Function to cleanup MLM state machine */ void lim_cleanup_mlm(tpAniSirGlobal); @@ -453,7 +453,7 @@ void lim_process_probe_req_frame_multiple_bss(tpAniSirGlobal, uint8_t *, /* Process Auth frame when we have a session in progress. */ void lim_process_auth_frame(tpAniSirGlobal, uint8_t *, tpPESession); -tSirRetStatus lim_process_auth_frame_no_session(tpAniSirGlobal pMac, uint8_t *, +QDF_STATUS lim_process_auth_frame_no_session(tpAniSirGlobal pMac, uint8_t *, void *body); void lim_process_assoc_req_frame(tpAniSirGlobal, uint8_t *, uint8_t, tpPESession); @@ -511,7 +511,7 @@ void lim_process_action_frame_no_session(tpAniSirGlobal pMac, uint8_t *pRxMetaIn void lim_populate_p2p_mac_header(tpAniSirGlobal, uint8_t *); void lim_populate_mac_header(tpAniSirGlobal, uint8_t *, uint8_t, uint8_t, tSirMacAddr, tSirMacAddr); -tSirRetStatus lim_send_probe_req_mgmt_frame(tpAniSirGlobal, tSirMacSSid *, +QDF_STATUS lim_send_probe_req_mgmt_frame(tpAniSirGlobal, tSirMacSSid *, tSirMacAddr, uint8_t, tSirMacAddr, uint32_t, uint16_t *, uint8_t *); void lim_send_probe_rsp_mgmt_frame(tpAniSirGlobal, tSirMacAddr, tpAniSSID, short, @@ -618,25 +618,25 @@ void lim_process_mlm_update_hidden_ssid_rsp(tpAniSirGlobal mac_ctx, tSirResultCodes lim_mlm_add_bss(tpAniSirGlobal, tLimMlmStartReq *, tpPESession psessionEntry); -tSirRetStatus lim_send_channel_switch_mgmt_frame(tpAniSirGlobal, tSirMacAddr, +QDF_STATUS lim_send_channel_switch_mgmt_frame(tpAniSirGlobal, tSirMacAddr, uint8_t, uint8_t, uint8_t, tpPESession); -tSirRetStatus lim_send_extended_chan_switch_action_frame(tpAniSirGlobal mac_ctx, +QDF_STATUS lim_send_extended_chan_switch_action_frame(tpAniSirGlobal mac_ctx, tSirMacAddr peer, uint8_t mode, uint8_t new_op_class, uint8_t new_channel, uint8_t count, tpPESession session_entry); -tSirRetStatus lim_p2p_oper_chan_change_confirm_action_frame( +QDF_STATUS lim_p2p_oper_chan_change_confirm_action_frame( tpAniSirGlobal mac_ctx, tSirMacAddr peer, tpPESession session_entry); -tSirRetStatus lim_send_vht_opmode_notification_frame(tpAniSirGlobal pMac, +QDF_STATUS lim_send_vht_opmode_notification_frame(tpAniSirGlobal pMac, tSirMacAddr peer, uint8_t nMode, tpPESession psessionEntry); -tSirRetStatus lim_send_neighbor_report_request_frame(tpAniSirGlobal, +QDF_STATUS lim_send_neighbor_report_request_frame(tpAniSirGlobal, tpSirMacNeighborReportReq, tSirMacAddr, tpPESession); -tSirRetStatus lim_send_link_report_action_frame(tpAniSirGlobal, tpSirMacLinkReport, +QDF_STATUS lim_send_link_report_action_frame(tpAniSirGlobal, tpSirMacLinkReport, tSirMacAddr, tpPESession); /** @@ -651,7 +651,7 @@ tSirRetStatus lim_send_link_report_action_frame(tpAniSirGlobal, tpSirMacLinkRepo * * Return: Ret Status */ -tSirRetStatus +QDF_STATUS lim_send_radio_measure_report_action_frame(tpAniSirGlobal pMac, uint8_t dialog_token, uint8_t num_report, @@ -663,27 +663,27 @@ lim_send_radio_measure_report_action_frame(tpAniSirGlobal pMac, #ifdef FEATURE_WLAN_TDLS void lim_init_tdls_data(tpAniSirGlobal, tpPESession); -tSirRetStatus lim_process_sme_tdls_mgmt_send_req(tpAniSirGlobal pMac, +QDF_STATUS lim_process_sme_tdls_mgmt_send_req(tpAniSirGlobal pMac, uint32_t *pMsgBuf); -tSirRetStatus lim_process_sme_tdls_add_sta_req(tpAniSirGlobal pMac, +QDF_STATUS lim_process_sme_tdls_add_sta_req(tpAniSirGlobal pMac, uint32_t *pMsgBuf); -tSirRetStatus lim_process_sme_tdls_del_sta_req(tpAniSirGlobal pMac, +QDF_STATUS lim_process_sme_tdls_del_sta_req(tpAniSirGlobal pMac, uint32_t *pMsgBuf); void lim_send_sme_mgmt_tx_completion( tpAniSirGlobal pMac, uint32_t sme_session_id, uint32_t txCompleteStatus); -tSirRetStatus lim_delete_tdls_peers(tpAniSirGlobal mac_ctx, +QDF_STATUS lim_delete_tdls_peers(tpAniSirGlobal mac_ctx, tpPESession session_entry); QDF_STATUS lim_process_tdls_add_sta_rsp(tpAniSirGlobal pMac, void *msg, tpPESession); void lim_process_tdls_del_sta_rsp(tpAniSirGlobal mac_ctx, struct scheduler_msg *lim_msg, tpPESession session_entry); #else -static inline tSirRetStatus lim_delete_tdls_peers(tpAniSirGlobal mac_ctx, +static inline QDF_STATUS lim_delete_tdls_peers(tpAniSirGlobal mac_ctx, tpPESession session_entry) { - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } static inline void lim_init_tdls_data(tpAniSirGlobal pMac, tpPESession pSessionEntry) @@ -715,11 +715,11 @@ void lim_set_channel(tpAniSirGlobal pMac, uint8_t channel, #ifdef ANI_SUPPORT_11H /* / Function that sends Measurement Report action frame */ -tSirRetStatus lim_send_meas_report_frame(tpAniSirGlobal, tpSirMacMeasReqActionFrame, +QDF_STATUS lim_send_meas_report_frame(tpAniSirGlobal, tpSirMacMeasReqActionFrame, tSirMacAddr, tpPESession psessionEntry); /* / Function that sends TPC Report action frame */ -tSirRetStatus lim_send_tpc_report_frame(tpAniSirGlobal, tpSirMacTpcReqActionFrame, +QDF_STATUS lim_send_tpc_report_frame(tpAniSirGlobal, tpSirMacTpcReqActionFrame, tSirMacAddr, tpPESession psessionEntry); #endif @@ -763,11 +763,11 @@ void limContinueChannelLearn(tpAniSirGlobal); #ifdef WLAN_FEATURE_11W /* 11w send SA query request action frame */ -tSirRetStatus lim_send_sa_query_request_frame(tpAniSirGlobal pMac, uint8_t *transId, +QDF_STATUS lim_send_sa_query_request_frame(tpAniSirGlobal pMac, uint8_t *transId, tSirMacAddr peer, tpPESession psessionEntry); /* 11w SA query request action frame handler */ -tSirRetStatus lim_send_sa_query_response_frame(tpAniSirGlobal pMac, +QDF_STATUS lim_send_sa_query_response_frame(tpAniSirGlobal pMac, uint8_t *transId, tSirMacAddr peer, tpPESession psessionEntry); #endif @@ -990,14 +990,14 @@ void lim_send_sme_disassoc_deauth_ntf(tpAniSirGlobal mac_ctx, QDF_STATUS status, uint32_t *ctx); #ifdef FEATURE_WLAN_TDLS -tSirRetStatus lim_process_sme_del_all_tdls_peers(tpAniSirGlobal p_mac, +QDF_STATUS lim_process_sme_del_all_tdls_peers(tpAniSirGlobal p_mac, uint32_t *msg_buf); #else static inline -tSirRetStatus lim_process_sme_del_all_tdls_peers(tpAniSirGlobal p_mac, +QDF_STATUS lim_process_sme_del_all_tdls_peers(tpAniSirGlobal p_mac, uint32_t *msg_buf) { - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } #endif diff --git a/core/mac/src/pe/lim/lim_utils.c b/core/mac/src/pe/lim/lim_utils.c index 5f07d1dbdf..f35ab23e1e 100644 --- a/core/mac/src/pe/lim/lim_utils.c +++ b/core/mac/src/pe/lim/lim_utils.c @@ -509,7 +509,7 @@ void lim_print_msg_name(tpAniSirGlobal pMac, uint16_t logLevel, uint32_t msgType * * @Return: Status of operation */ -tSirRetStatus lim_init_mlm(tpAniSirGlobal pMac) +QDF_STATUS lim_init_mlm(tpAniSirGlobal pMac) { uint32_t retVal; @@ -528,11 +528,11 @@ tSirRetStatus lim_init_mlm(tpAniSirGlobal pMac) retVal = lim_create_timers(pMac); if (retVal != TX_SUCCESS) { pe_err("lim_create_timers Failed"); - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } pMac->lim.gLimTimersCreated = 1; - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /*** end lim_init_mlm() ***/ void lim_deactivate_timers(tpAniSirGlobal mac_ctx) @@ -991,13 +991,13 @@ struct scheduler_msg *lim_read_deferred_msg_q(tpAniSirGlobal pMac) return msg; } -tSirRetStatus +QDF_STATUS lim_sys_process_mmh_msg_api(tpAniSirGlobal pMac, struct scheduler_msg *pMsg, uint8_t qType) { /* FIXME */ sys_process_mmh_msg(pMac, pMsg); - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /* @@ -1460,7 +1460,7 @@ lim_update_short_preamble(tpAniSirGlobal mac_ctx, tSirMacAddr peer_mac_addr, pe_debug("Disabling short preamble"); if (lim_enable_short_preamble(mac_ctx, false, beaconparams, - psession_entry) != eSIR_SUCCESS) + psession_entry) != QDF_STATUS_SUCCESS) pe_err("Cannot enable long preamble"); } @@ -2002,7 +2002,7 @@ void lim_process_channel_switch_timeout(tpAniSirGlobal pMac) if (!lim_is_channel_valid_for_channel_switch(pMac, channel)) { /* We need to restore pre-channelSwitch state on the STA */ if (lim_restore_pre_channel_switch_state(pMac, psessionEntry) != - eSIR_SUCCESS) { + QDF_STATUS_SUCCESS) { pe_err("Could not restore pre-channelSwitch (11h) state, resetting the system"); return; } @@ -2052,7 +2052,7 @@ void lim_process_channel_switch_timeout(tpAniSirGlobal pMac) default: pe_err("incorrect state"); if (lim_restore_pre_channel_switch_state(pMac, psessionEntry) != - eSIR_SUCCESS) { + QDF_STATUS_SUCCESS) { pe_err("Could not restore pre-channelSwitch (11h) state, resetting the system"); } return; /* Please note, this is 'return' and not 'break' */ @@ -2139,7 +2139,7 @@ lim_update_channel_switch(struct sAniSirGlobal *mac_ctx, newCenterChanFreq1; } } - if (eSIR_SUCCESS != lim_start_channel_switch(mac_ctx, psession_entry)) + if (QDF_STATUS_SUCCESS != lim_start_channel_switch(mac_ctx, psession_entry)) pe_warn("Could not start Channel Switch"); pe_debug("session: %d primary chl: %d ch_width: %d count: %d (%d ticks)", @@ -2182,13 +2182,13 @@ void lim_cancel_dot11h_channel_switch(tpAniSirGlobal pMac, psessionEntry->peSessionId, eLIM_CHANNEL_SWITCH_TIMER)); if (tx_timer_deactivate(&pMac->lim.limTimers.gLimChannelSwitchTimer) != - eSIR_SUCCESS) { + QDF_STATUS_SUCCESS) { pe_err("tx_timer_deactivate failed!"); } /* We need to restore pre-channelSwitch state on the STA */ if (lim_restore_pre_channel_switch_state(pMac, psessionEntry) != - eSIR_SUCCESS) { + QDF_STATUS_SUCCESS) { pe_err("LIM: Could not restore pre-channelSwitch (11h) state, resetting the system"); } } @@ -2553,7 +2553,7 @@ void lim_switch_channel_cback(tpAniSirGlobal pMac, QDF_STATUS status, /* We need to restore pre-channelSwitch state on the STA */ if (lim_restore_pre_channel_switch_state(pMac, psessionEntry) != - eSIR_SUCCESS) { + QDF_STATUS_SUCCESS) { pe_err("Could not restore pre-channelSwitch (11h) state, resetting the system"); return; } @@ -2743,7 +2743,7 @@ uint8_t lim_get_ht_capability(tpAniSirGlobal pMac, /* */ if (htCap >= eHT_ANTENNA_SELECTION && htCap < eHT_SI_GRANULARITY) { /* Get Antenna Seletion HT Capabilities */ - if (eSIR_SUCCESS != + if (QDF_STATUS_SUCCESS != wlan_cfg_get_int(pMac, WNI_CFG_AS_CAP, &cfgValue)) cfgValue = 0; ptr = (uint8_t *) &macASCapabilityInfo; @@ -2752,7 +2752,7 @@ uint8_t lim_get_ht_capability(tpAniSirGlobal pMac, if (htCap >= eHT_TX_BEAMFORMING && htCap < eHT_ANTENNA_SELECTION) { /* Get Transmit Beam Forming HT Capabilities */ - if (eSIR_SUCCESS != + if (QDF_STATUS_SUCCESS != wlan_cfg_get_int(pMac, WNI_CFG_TX_BF_CAP, &cfgValue)) cfgValue = 0; ptr = (uint8_t *) &macTxBFCapabilityInfo; @@ -2760,7 +2760,7 @@ uint8_t lim_get_ht_capability(tpAniSirGlobal pMac, } else { if (htCap >= eHT_PCO && htCap < eHT_TX_BEAMFORMING) { /* Get Extended HT Capabilities */ - if (eSIR_SUCCESS != + if (QDF_STATUS_SUCCESS != wlan_cfg_get_int(pMac, WNI_CFG_EXT_HT_CAP_INFO, &cfgValue)) @@ -2771,7 +2771,7 @@ uint8_t lim_get_ht_capability(tpAniSirGlobal pMac, } else { if (htCap < eHT_MAX_RX_AMPDU_FACTOR) { /* Get HT Capabilities */ - if (eSIR_SUCCESS != + if (QDF_STATUS_SUCCESS != wlan_cfg_get_int(pMac, WNI_CFG_HT_CAP_INFO, &cfgValue)) @@ -3109,14 +3109,14 @@ disable_11a_end: * * @Return: success of failure of operation */ -tSirRetStatus +QDF_STATUS lim_update_11a_protection(tpAniSirGlobal mac_ctx, uint8_t enable, uint8_t overlap, tpUpdateBeaconParams bcn_prms, tpPESession session) { if (NULL == session) { pe_err("session is NULL"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } /* overlapping protection configuration check. */ if (!overlap) { @@ -3125,7 +3125,7 @@ lim_update_11a_protection(tpAniSirGlobal mac_ctx, uint8_t enable, (!session->cfgProtection.fromlla)) { /* protection disabled. */ pe_warn("protection from 11a is disabled"); - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } } @@ -3134,7 +3134,7 @@ lim_update_11a_protection(tpAniSirGlobal mac_ctx, uint8_t enable, else lim_disable_11a_protection(mac_ctx, overlap, bcn_prms, session); - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /** @@ -3355,9 +3355,9 @@ lim_handle_11g_protection_for_11bcoexist(tpAniSirGlobal mac_ctx, * * based on config setting enables\disables 11g protection. * - * Return: Success - eSIR_SUCCESS - Success, Error number - Failure + * Return: Success - QDF_STATUS_SUCCESS - Success, Error number - Failure */ -tSirRetStatus +QDF_STATUS lim_enable11g_protection(tpAniSirGlobal mac_ctx, uint8_t enable, uint8_t overlap, tpUpdateBeaconParams beaconparams, tpPESession session_entry) @@ -3370,12 +3370,12 @@ lim_enable11g_protection(tpAniSirGlobal mac_ctx, uint8_t enable, !session_entry->cfgProtection.fromllb) { /* protection disabled. */ pe_debug("protection from 11b is disabled"); - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } else if (!LIM_IS_AP_ROLE(session_entry)) { if (!mac_ctx->lim.cfgProtection.fromllb) { /* protection disabled. */ pe_debug("protection from 11b is disabled"); - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } } } @@ -3387,7 +3387,7 @@ lim_enable11g_protection(tpAniSirGlobal mac_ctx, uint8_t enable, lim_handle_11g_protection_for_11bcoexist(mac_ctx, beaconparams, overlap, session_entry); } - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /** ------------------------------------------------------------- @@ -3398,14 +3398,14 @@ lim_enable11g_protection(tpAniSirGlobal mac_ctx, uint8_t enable, \param tpUpdateBeaconParams pBeaconParams \return None -------------------------------------------------------------*/ -tSirRetStatus +QDF_STATUS lim_enable_ht_protection_from11g(tpAniSirGlobal pMac, uint8_t enable, uint8_t overlap, tpUpdateBeaconParams pBeaconParams, tpPESession psessionEntry) { if (!psessionEntry->htCapability) - return eSIR_SUCCESS; /* protection from 11g is only for HT stations. */ + return QDF_STATUS_SUCCESS; /* protection from 11g is only for HT stations. */ /* overlapping protection configuration check. */ if (overlap) { @@ -3413,7 +3413,7 @@ lim_enable_ht_protection_from11g(tpAniSirGlobal pMac, uint8_t enable, && (!psessionEntry->cfgProtection.overlapFromllg)) { /* protection disabled. */ pe_debug("overlap protection from 11g is disabled"); - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } } else { /* normal protection config check */ @@ -3421,12 +3421,12 @@ lim_enable_ht_protection_from11g(tpAniSirGlobal pMac, uint8_t enable, !psessionEntry->cfgProtection.fromllg) { /* protection disabled. */ pe_debug("protection from 11g is disabled"); - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } else if (!LIM_IS_AP_ROLE(psessionEntry)) { if (!pMac->lim.cfgProtection.fromllg) { /* protection disabled. */ pe_debug("protection from 11g is disabled"); - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } } } @@ -3614,7 +3614,7 @@ lim_enable_ht_protection_from11g(tpAniSirGlobal pMac, uint8_t enable, PARAM_llGCOEXIST_CHANGED; } } - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /* FIXME_PROTECTION : need to check for no APSD whenever we want to enable this protection. */ @@ -3628,14 +3628,14 @@ lim_enable_ht_protection_from11g(tpAniSirGlobal pMac, uint8_t enable, \param tpUpdateBeaconParams pBeaconParams \return None -------------------------------------------------------------*/ -tSirRetStatus +QDF_STATUS lim_enable_ht_obss_protection(tpAniSirGlobal pMac, uint8_t enable, uint8_t overlap, tpUpdateBeaconParams pBeaconParams, tpPESession psessionEntry) { if (!psessionEntry->htCapability) - return eSIR_SUCCESS; /* this protection is only for HT stations. */ + return QDF_STATUS_SUCCESS; /* this protection is only for HT stations. */ /* overlapping protection configuration check. */ if (overlap) { @@ -3646,12 +3646,12 @@ lim_enable_ht_obss_protection(tpAniSirGlobal pMac, uint8_t enable, !psessionEntry->cfgProtection.obss) { /* ToDo Update this field */ /* protection disabled. */ pe_debug("protection from Obss is disabled"); - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } else if (!LIM_IS_AP_ROLE(psessionEntry)) { if (!pMac->lim.cfgProtection.obss) { /* ToDo Update this field */ /* protection disabled. */ pe_debug("protection from Obss is disabled"); - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } } } @@ -3694,7 +3694,7 @@ lim_enable_ht_obss_protection(tpAniSirGlobal pMac, uint8_t enable, } } - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /** @@ -3854,13 +3854,13 @@ static void lim_handle_ht20coexist_ht20protection(tpAniSirGlobal mac_ctx, * * Return: 0 - success */ -tSirRetStatus lim_enable_ht20_protection(tpAniSirGlobal mac_ctx, uint8_t enable, +QDF_STATUS lim_enable_ht20_protection(tpAniSirGlobal mac_ctx, uint8_t enable, uint8_t overlap, tpUpdateBeaconParams beaconparams, tpPESession session_entry) { /* This protection is only for HT stations. */ if (!session_entry->htCapability) - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; /* overlapping protection configuration check. */ if (!overlap) { @@ -3869,12 +3869,12 @@ tSirRetStatus lim_enable_ht20_protection(tpAniSirGlobal mac_ctx, uint8_t enable, !session_entry->cfgProtection.ht20) { /* protection disabled. */ pe_debug("protection from HT20 is disabled"); - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } else if (!LIM_IS_AP_ROLE(session_entry)) { if (!mac_ctx->lim.cfgProtection.ht20) { /* protection disabled. */ pe_debug("protection from HT20 is disabled"); - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } } } @@ -3886,7 +3886,7 @@ tSirRetStatus lim_enable_ht20_protection(tpAniSirGlobal mac_ctx, uint8_t enable, lim_handle_ht20coexist_ht20protection(mac_ctx, beaconparams, session_entry, overlap); - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /** ------------------------------------------------------------- @@ -3897,13 +3897,13 @@ tSirRetStatus lim_enable_ht20_protection(tpAniSirGlobal mac_ctx, uint8_t enable, \param tpUpdateBeaconParams pBeaconParams \return None -------------------------------------------------------------*/ -tSirRetStatus +QDF_STATUS lim_enable_ht_non_gf_protection(tpAniSirGlobal pMac, uint8_t enable, uint8_t overlap, tpUpdateBeaconParams pBeaconParams, tpPESession psessionEntry) { if (!psessionEntry->htCapability) - return eSIR_SUCCESS; /* this protection is only for HT stations. */ + return QDF_STATUS_SUCCESS; /* this protection is only for HT stations. */ /* overlapping protection configuration check. */ if (overlap) { @@ -3913,13 +3913,13 @@ lim_enable_ht_non_gf_protection(tpAniSirGlobal pMac, uint8_t enable, !psessionEntry->cfgProtection.nonGf) { /* protection disabled. */ pe_debug("protection from NonGf is disabled"); - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } else if (!LIM_IS_AP_ROLE(psessionEntry)) { /* normal protection config check */ if (!pMac->lim.cfgProtection.nonGf) { /* protection disabled. */ pe_debug("protection from NonGf is disabled"); - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } } } @@ -3959,7 +3959,7 @@ lim_enable_ht_non_gf_protection(tpAniSirGlobal pMac, uint8_t enable, } } - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /** ------------------------------------------------------------- @@ -3970,14 +3970,14 @@ lim_enable_ht_non_gf_protection(tpAniSirGlobal pMac, uint8_t enable, \param tpUpdateBeaconParams pBeaconParams \return None -------------------------------------------------------------*/ -tSirRetStatus +QDF_STATUS lim_enable_ht_lsig_txop_protection(tpAniSirGlobal pMac, uint8_t enable, uint8_t overlap, tpUpdateBeaconParams pBeaconParams, tpPESession psessionEntry) { if (!psessionEntry->htCapability) - return eSIR_SUCCESS; /* this protection is only for HT stations. */ + return QDF_STATUS_SUCCESS; /* this protection is only for HT stations. */ /* overlapping protection configuration check. */ if (overlap) { @@ -3987,13 +3987,13 @@ lim_enable_ht_lsig_txop_protection(tpAniSirGlobal pMac, uint8_t enable, !psessionEntry->cfgProtection.lsigTxop) { /* protection disabled. */ pe_debug("protection from LsigTxop not supported is disabled"); - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } else if (!LIM_IS_AP_ROLE(psessionEntry)) { /* normal protection config check */ if (!pMac->lim.cfgProtection.lsigTxop) { /* protection disabled. */ pe_debug("protection from LsigTxop not supported is disabled"); - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } } } @@ -4043,7 +4043,7 @@ lim_enable_ht_lsig_txop_protection(tpAniSirGlobal pMac, uint8_t enable, PARAM_LSIG_TXOP_FULL_SUPPORT_CHANGED; } } - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /* FIXME_PROTECTION : need to check for no APSD whenever we want to enable this protection. */ @@ -4056,13 +4056,13 @@ lim_enable_ht_lsig_txop_protection(tpAniSirGlobal pMac, uint8_t enable, \param tpUpdateBeaconParams pBeaconParams \return None -------------------------------------------------------------*/ -tSirRetStatus +QDF_STATUS lim_enable_ht_rifs_protection(tpAniSirGlobal pMac, uint8_t enable, uint8_t overlap, tpUpdateBeaconParams pBeaconParams, tpPESession psessionEntry) { if (!psessionEntry->htCapability) - return eSIR_SUCCESS; /* this protection is only for HT stations. */ + return QDF_STATUS_SUCCESS; /* this protection is only for HT stations. */ /* overlapping protection configuration check. */ if (overlap) { @@ -4072,13 +4072,13 @@ lim_enable_ht_rifs_protection(tpAniSirGlobal pMac, uint8_t enable, !psessionEntry->cfgProtection.rifs) { /* protection disabled. */ pe_debug("protection from Rifs is disabled"); - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } else if (!LIM_IS_AP_ROLE(psessionEntry)) { /* normal protection config check */ if (!pMac->lim.cfgProtection.rifs) { /* protection disabled. */ pe_debug("protection from Rifs is disabled"); - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } } } @@ -4122,7 +4122,7 @@ lim_enable_ht_rifs_protection(tpAniSirGlobal pMac, uint8_t enable, PARAM_RIFS_MODE_CHANGED; } } - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /* --------------------------------------------------------------------- */ @@ -4142,30 +4142,30 @@ lim_enable_ht_rifs_protection(tpAniSirGlobal pMac, uint8_t enable, * @return None */ -tSirRetStatus +QDF_STATUS lim_enable_short_preamble(tpAniSirGlobal pMac, uint8_t enable, tpUpdateBeaconParams pBeaconParams, tpPESession psessionEntry) { uint32_t val; - if (wlan_cfg_get_int(pMac, WNI_CFG_SHORT_PREAMBLE, &val) != eSIR_SUCCESS) { + if (wlan_cfg_get_int(pMac, WNI_CFG_SHORT_PREAMBLE, &val) != QDF_STATUS_SUCCESS) { /* Could not get short preamble enabled flag from CFG. Log error. */ pe_err("could not retrieve short preamble flag"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } if (!val) - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; if (wlan_cfg_get_int(pMac, WNI_CFG_11G_SHORT_PREAMBLE_ENABLED, &val) != - eSIR_SUCCESS) { + QDF_STATUS_SUCCESS) { pe_err("could not retrieve 11G short preamble switching enabled flag"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } if (!val) /* 11G short preamble switching is disabled. */ - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; if (LIM_IS_AP_ROLE(psessionEntry)) { if (enable && (psessionEntry->beaconParams.fShortPreamble == 0)) { @@ -4189,7 +4189,7 @@ lim_enable_short_preamble(tpAniSirGlobal pMac, uint8_t enable, } } - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /** @@ -4482,7 +4482,7 @@ void lim_update_sta_run_time_ht_info(tpAniSirGlobal pMac, \return tSirRetStatu - status -------------------------------------------------------------*/ -tSirRetStatus lim_process_hal_ind_messages(tpAniSirGlobal pMac, uint32_t msgId, +QDF_STATUS lim_process_hal_ind_messages(tpAniSirGlobal pMac, uint32_t msgId, void *msgParam) { /* its PE's responsibility to free msgparam when its done extracting the message parameters. */ @@ -4500,15 +4500,15 @@ tSirRetStatus lim_process_hal_ind_messages(tpAniSirGlobal pMac, uint32_t msgId, default: qdf_mem_free(msgParam); pe_err("invalid message id: %d received", msgId); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } - if (lim_post_msg_api(pMac, &msg) != eSIR_SUCCESS) { + if (lim_post_msg_api(pMac, &msg) != QDF_STATUS_SUCCESS) { qdf_mem_free(msgParam); pe_err("lim_post_msg_api failed for msgid: %d", msg.type); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /** @@ -4520,10 +4520,10 @@ tSirRetStatus lim_process_hal_ind_messages(tpAniSirGlobal pMac, uint32_t msgId, * Function validates DelTs req originated by SME or by HAL and also * sends halMsg_DelTs to HAL * - * Return: eSIR_SUCCESS - Success, eSIR_FAILURE - Failure + * Return: QDF_STATUS_SUCCESS - Success, QDF_STATUS_E_FAILURE - Failure */ -tSirRetStatus +QDF_STATUS lim_validate_delts_req(tpAniSirGlobal mac_ctx, tpSirDeltsReq delts_req, tSirMacAddr peer_mac_addr, tpPESession psession_entry) { @@ -4543,7 +4543,7 @@ lim_validate_delts_req(tpAniSirGlobal mac_ctx, tpSirDeltsReq delts_req, */ if (delts_req == NULL) { pe_err("Delete TS request pointer is NULL"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } if (LIM_IS_STA_ROLE(psession_entry)) { @@ -4579,14 +4579,14 @@ lim_validate_delts_req(tpAniSirGlobal mac_ctx, tpSirDeltsReq delts_req, if (sta == NULL) { pe_err("Cannot find station context for delts req"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } if ((!sta->valid) || (sta->mlmStaContext.mlmState != eLIM_MLM_LINK_ESTABLISHED_STATE)) { pe_err("Invalid Sta (or state) for DelTsReq"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } delts_req->req.wsmTspecPresent = 0; @@ -4603,7 +4603,7 @@ lim_validate_delts_req(tpAniSirGlobal mac_ctx, tpSirDeltsReq delts_req, delts_req->req.lleTspecPresent = 1; else { pe_warn("DELTS_REQ ignore - qos is disabled"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } tsinfo = delts_req->req.wmeTspecPresent ? &delts_req->req.tspec.tsinfo @@ -4616,28 +4616,28 @@ lim_validate_delts_req(tpAniSirGlobal mac_ctx, tpSirDeltsReq delts_req, /* if no Access Control, ignore the request */ if (lim_admit_control_delete_ts(mac_ctx, sta->assocId, tsinfo, - &ts_status, &tspec_idx) != eSIR_SUCCESS) { + &ts_status, &tspec_idx) != QDF_STATUS_SUCCESS) { pe_err("DELTS request for sta assocId: %d tsid: %d up: %d", sta->assocId, tsinfo->traffic.tsid, tsinfo->traffic.userPrio); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } else if ((tsinfo->traffic.accessPolicy == SIR_MAC_ACCESSPOLICY_HCCA) || (tsinfo->traffic.accessPolicy == SIR_MAC_ACCESSPOLICY_BOTH)) { /* edca only now. */ } else if (tsinfo->traffic.accessPolicy == SIR_MAC_ACCESSPOLICY_EDCA) { /* send message to HAL to delete TS */ - if (eSIR_SUCCESS != + if (QDF_STATUS_SUCCESS != lim_send_hal_msg_del_ts(mac_ctx, sta->staIndex, tspec_idx, delts_req->req, psession_entry->peSessionId, psession_entry->bssId)) { pe_warn("DelTs with UP: %d failed in lim_send_hal_msg_del_ts - ignoring request", tsinfo->traffic.userPrio); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } } - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /** ------------------------------------------------------------- @@ -4664,7 +4664,7 @@ void lim_register_hal_ind_call_back(tpAniSirGlobal pMac) msg.bodyval = 0; MTRACE(mac_trace_msg_tx(pMac, NO_SESSION, msg.type)); - if (eSIR_SUCCESS != wma_post_ctrl_msg(pMac, &msg)) { + if (QDF_STATUS_SUCCESS != wma_post_ctrl_msg(pMac, &msg)) { qdf_mem_free(pHalCB); pe_err("wma_post_ctrl_msg() failed"); } @@ -4735,7 +4735,7 @@ void lim_process_del_ts_ind(tpAniSirGlobal pMac, struct scheduler_msg *limMsg) sizeof(tSirMacTSInfo)); /* validate the req */ - if (eSIR_SUCCESS != + if (QDF_STATUS_SUCCESS != lim_validate_delts_req(pMac, pDelTsReq, peerMacAddr, psessionEntry)) { pe_err("lim_validate_delts_req failed"); goto error2; @@ -4793,12 +4793,12 @@ error1: * @param limMsg - Lim Message structure object with the MimoPSparam in body * @return None */ -tSirRetStatus +QDF_STATUS lim_post_sm_state_update(tpAniSirGlobal pMac, uint16_t staIdx, tSirMacHTMIMOPowerSaveState state, uint8_t *pPeerStaMac, uint8_t sessionId) { - tSirRetStatus retCode = eSIR_SUCCESS; + QDF_STATUS retCode = QDF_STATUS_SUCCESS; struct scheduler_msg msgQ = {0}; tpSetMIMOPS pMIMO_PSParams; @@ -4809,7 +4809,7 @@ lim_post_sm_state_update(tpAniSirGlobal pMac, pMIMO_PSParams = qdf_mem_malloc(sizeof(tSetMIMOPS)); if (NULL == pMIMO_PSParams) { pe_err(" AllocateMemory failed"); - return eSIR_MEM_ALLOC_FAILED; + return QDF_STATUS_E_NOMEM; } pMIMO_PSParams->htMIMOPSState = state; @@ -4825,7 +4825,7 @@ lim_post_sm_state_update(tpAniSirGlobal pMac, MTRACE(mac_trace_msg_tx(pMac, NO_SESSION, msgQ.type)); retCode = wma_post_ctrl_msg(pMac, &msgQ); - if (eSIR_SUCCESS != retCode) { + if (QDF_STATUS_SUCCESS != retCode) { pe_err("Posting WMA_SET_MIMOPS_REQ to HAL failed! Reason: %d", retCode); qdf_mem_free(pMIMO_PSParams); @@ -4963,7 +4963,7 @@ bool lim_is_channel_valid_for_channel_switch(tpAniSirGlobal pMac, uint8_t channe if (wlan_cfg_get_str(pMac, WNI_CFG_VALID_CHANNEL_LIST, (uint8_t *) validChannelList, (uint32_t *) &validChannelListLen) != - eSIR_SUCCESS) { + QDF_STATUS_SUCCESS) { pe_err("could not retrieve valid channel list"); return false; } @@ -5082,7 +5082,7 @@ void lim_frame_transmission_control(tpAniSirGlobal pMac, tLimQuietTxMode type, msgQ.type = WMA_TRANSMISSION_CONTROL_IND; MTRACE(mac_trace_msg_tx(pMac, NO_SESSION, msgQ.type)); - if (wma_post_ctrl_msg(pMac, &msgQ) != eSIR_SUCCESS) { + if (wma_post_ctrl_msg(pMac, &msgQ) != QDF_STATUS_SUCCESS) { qdf_mem_free(pTxCtrlMsg); pe_err("Posting Message to HAL failed"); return; @@ -5112,11 +5112,11 @@ void lim_frame_transmission_control(tpAniSirGlobal pMac, tLimQuietTxMode type, * @return None */ -tSirRetStatus +QDF_STATUS lim_restore_pre_channel_switch_state(tpAniSirGlobal pMac, tpPESession psessionEntry) { - tSirRetStatus retCode = eSIR_SUCCESS; + QDF_STATUS retCode = QDF_STATUS_SUCCESS; if (!LIM_IS_STA_ROLE(psessionEntry)) return retCode; @@ -5137,11 +5137,11 @@ lim_restore_pre_channel_switch_state(tpAniSirGlobal pMac, tpPESession psessionEn \param pMac \return NONE ---------------------------------------------*/ -tSirRetStatus lim_restore_pre_quiet_state(tpAniSirGlobal pMac, +QDF_STATUS lim_restore_pre_quiet_state(tpAniSirGlobal pMac, tpPESession psessionEntry) { - tSirRetStatus retCode = eSIR_SUCCESS; + QDF_STATUS retCode = QDF_STATUS_SUCCESS; if (pMac->lim.gLimSystemRole != eLIM_STA_ROLE) return retCode; @@ -5899,7 +5899,7 @@ void lim_pmf_sa_query_timer_handler(void *pMacGlobal, uint32_t param) /* Increment the retry count, check if reached maximum */ if (wlan_cfg_get_int(pMac, WNI_CFG_PMF_SA_QUERY_MAX_RETRIES, - &maxRetries) != eSIR_SUCCESS) { + &maxRetries) != QDF_STATUS_SUCCESS) { pe_err("Could not retrieve PMF SA Query maximum retries value"); pSta->pmfSaQueryState = DPH_SA_QUERY_NOT_IN_PROGRESS; return; @@ -6501,7 +6501,7 @@ QDF_STATUS lim_send_ext_cap_ie(tpAniSirGlobal mac_ctx, bool vht_enabled = false; struct vdev_ie_info *vdev_ie; struct scheduler_msg msg = {0}; - tSirRetStatus status; + QDF_STATUS status; wlan_cfg_get_int(mac_ctx, WNI_CFG_DOT11_MODE, &dot11mode); if (IS_DOT11_MODE_VHT(dot11mode)) @@ -6509,7 +6509,7 @@ QDF_STATUS lim_send_ext_cap_ie(tpAniSirGlobal mac_ctx, status = populate_dot11f_ext_cap(mac_ctx, vht_enabled, &ext_cap_data, NULL); - if (eSIR_SUCCESS != status) { + if (QDF_STATUS_SUCCESS != status) { pe_err("Failed to populate ext cap IE"); return QDF_STATUS_E_FAILURE; } @@ -6565,9 +6565,9 @@ QDF_STATUS lim_send_ext_cap_ie(tpAniSirGlobal mac_ctx, * This utility function is used to strip of the requested IE if present * in IE buffer. * - * Return: tSirRetStatus + * Return: QDF_STATUS */ -tSirRetStatus lim_strip_ie(tpAniSirGlobal mac_ctx, +QDF_STATUS lim_strip_ie(tpAniSirGlobal mac_ctx, uint8_t *addn_ie, uint16_t *addn_ielen, uint8_t eid, eSizeOfLenField size_of_len_field, uint8_t *oui, uint8_t oui_length, uint8_t *extracted_ie, @@ -6582,13 +6582,13 @@ tSirRetStatus lim_strip_ie(tpAniSirGlobal mac_ctx, if (NULL == addn_ie) { pe_debug("NULL addn_ie pointer"); - return eSIR_IGNORE_IE; + return QDF_STATUS_E_INVAL; } tempbuf = qdf_mem_malloc(left); if (NULL == tempbuf) { pe_err("Unable to allocate memory"); - return eSIR_MEM_ALLOC_FAILED; + return QDF_STATUS_E_NOMEM; } while (left >= 2) { @@ -6605,7 +6605,7 @@ tSirRetStatus lim_strip_ie(tpAniSirGlobal mac_ctx, pe_err("Invalid IEs eid: %d elem_len: %d left: %d", elem_id, elem_len, left); qdf_mem_free(tempbuf); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } if (eid != elem_id || @@ -6637,7 +6637,7 @@ tSirRetStatus lim_strip_ie(tpAniSirGlobal mac_ctx, *addn_ielen = templen; qdf_mem_free(tempbuf); - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } #ifdef WLAN_FEATURE_11W @@ -6667,12 +6667,12 @@ void lim_del_pmf_sa_query_timer(tpAniSirGlobal mac_ctx, tpPESession pe_session) } #endif -tSirRetStatus lim_strip_supp_op_class_update_struct(tpAniSirGlobal mac_ctx, +QDF_STATUS lim_strip_supp_op_class_update_struct(tpAniSirGlobal mac_ctx, uint8_t *addn_ie, uint16_t *addn_ielen, tDot11fIESuppOperatingClasses *dst) { uint8_t extracted_buff[DOT11F_IE_SUPPOPERATINGCLASSES_MAX_LEN + 2]; - tSirRetStatus status; + QDF_STATUS status; qdf_mem_set((uint8_t *)&extracted_buff[0], DOT11F_IE_SUPPOPERATINGCLASSES_MAX_LEN + 2, @@ -6681,7 +6681,7 @@ tSirRetStatus lim_strip_supp_op_class_update_struct(tpAniSirGlobal mac_ctx, DOT11F_EID_SUPPOPERATINGCLASSES, ONE_BYTE, NULL, 0, extracted_buff, DOT11F_IE_SUPPOPERATINGCLASSES_MAX_LEN); - if (eSIR_SUCCESS != status) { + if (QDF_STATUS_SUCCESS != status) { pe_warn("Failed to strip supp_op_mode IE status: %d", status); return status; @@ -6691,17 +6691,17 @@ tSirRetStatus lim_strip_supp_op_class_update_struct(tpAniSirGlobal mac_ctx, extracted_buff[1] > DOT11F_IE_SUPPOPERATINGCLASSES_MAX_LEN) { pe_warn("Invalid IEs eid: %d elem_len: %d", extracted_buff[0], extracted_buff[1]); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } /* update the extracted supp op class to struct*/ if (DOT11F_PARSE_SUCCESS != dot11f_unpack_ie_supp_operating_classes( mac_ctx, &extracted_buff[2], extracted_buff[1], dst, false)) { pe_err("dot11f_unpack Parse Error"); - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; } - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } /** @@ -6756,13 +6756,13 @@ void lim_update_extcap_struct(tpAniSirGlobal mac_ctx, * This function is used to strip extended capability IE from IE buffer and * update the passed structure. * - * Return: tSirRetStatus + * Return: QDF_STATUS */ -tSirRetStatus lim_strip_extcap_update_struct(tpAniSirGlobal mac_ctx, +QDF_STATUS lim_strip_extcap_update_struct(tpAniSirGlobal mac_ctx, uint8_t *addn_ie, uint16_t *addn_ielen, tDot11fIEExtCap *dst) { uint8_t extracted_buff[DOT11F_IE_EXTCAP_MAX_LEN + 2]; - tSirRetStatus status; + QDF_STATUS status; qdf_mem_set((uint8_t *)&extracted_buff[0], DOT11F_IE_EXTCAP_MAX_LEN + 2, 0); @@ -6770,7 +6770,7 @@ tSirRetStatus lim_strip_extcap_update_struct(tpAniSirGlobal mac_ctx, DOT11F_EID_EXTCAP, ONE_BYTE, NULL, 0, extracted_buff, DOT11F_IE_EXTCAP_MAX_LEN); - if (eSIR_SUCCESS != status) { + if (QDF_STATUS_SUCCESS != status) { pe_debug("Failed to strip extcap IE status: %d", status); return status; } @@ -6885,7 +6885,7 @@ void lim_init_obss_params(tpAniSirGlobal mac_ctx, tpPESession session) uint32_t cfg_value; if (wlan_cfg_get_int(mac_ctx, WNI_CFG_OBSS_HT40_SCAN_ACTIVE_DWELL_TIME, - &cfg_value) != eSIR_SUCCESS) { + &cfg_value) != QDF_STATUS_SUCCESS) { pe_err("Fail to retrieve: %x value", WNI_CFG_OBSS_HT40_SCAN_ACTIVE_DWELL_TIME); return; @@ -6893,7 +6893,7 @@ void lim_init_obss_params(tpAniSirGlobal mac_ctx, tpPESession session) session->obss_ht40_scanparam.obss_active_dwelltime = cfg_value; if (wlan_cfg_get_int(mac_ctx, WNI_CFG_OBSS_HT40_SCAN_PASSIVE_DWELL_TIME, - &cfg_value) != eSIR_SUCCESS) { + &cfg_value) != QDF_STATUS_SUCCESS) { pe_err("Fail to retrieve: %x value", WNI_CFG_OBSS_HT40_SCAN_PASSIVE_DWELL_TIME); return; @@ -6902,7 +6902,7 @@ void lim_init_obss_params(tpAniSirGlobal mac_ctx, tpPESession session) if (wlan_cfg_get_int(mac_ctx, WNI_CFG_OBSS_HT40_SCAN_WIDTH_TRIGGER_INTERVAL, - &cfg_value) != eSIR_SUCCESS) { + &cfg_value) != QDF_STATUS_SUCCESS) { pe_err("Fail to retrieve: %x value", WNI_CFG_OBSS_HT40_SCAN_WIDTH_TRIGGER_INTERVAL); return; @@ -6910,7 +6910,7 @@ void lim_init_obss_params(tpAniSirGlobal mac_ctx, tpPESession session) session->obss_ht40_scanparam.obss_width_trigger_interval = cfg_value; if (wlan_cfg_get_int(mac_ctx, WNI_CFG_OBSS_HT40_SCAN_ACTIVE_TOTAL_PER_CHANNEL, - &cfg_value) != eSIR_SUCCESS) { + &cfg_value) != QDF_STATUS_SUCCESS) { pe_err("Fail to retrieve: %x value", WNI_CFG_OBSS_HT40_SCAN_ACTIVE_TOTAL_PER_CHANNEL); return; @@ -6918,7 +6918,7 @@ void lim_init_obss_params(tpAniSirGlobal mac_ctx, tpPESession session) session->obss_ht40_scanparam.obss_active_total_per_channel = cfg_value; if (wlan_cfg_get_int(mac_ctx, WNI_CFG_OBSS_HT40_SCAN_PASSIVE_TOTAL_PER_CHANNEL, &cfg_value) - != eSIR_SUCCESS) { + != QDF_STATUS_SUCCESS) { pe_err("Fail to retrieve: %x value", WNI_CFG_OBSS_HT40_SCAN_PASSIVE_TOTAL_PER_CHANNEL); return; @@ -6927,7 +6927,7 @@ void lim_init_obss_params(tpAniSirGlobal mac_ctx, tpPESession session) if (wlan_cfg_get_int(mac_ctx, WNI_CFG_OBSS_HT40_WIDTH_CH_TRANSITION_DELAY, &cfg_value) - != eSIR_SUCCESS) { + != QDF_STATUS_SUCCESS) { pe_err("Fail to retrieve: %x value", WNI_CFG_OBSS_HT40_WIDTH_CH_TRANSITION_DELAY); return; @@ -6936,7 +6936,7 @@ void lim_init_obss_params(tpAniSirGlobal mac_ctx, tpPESession session) cfg_value; if (wlan_cfg_get_int(mac_ctx, WNI_CFG_OBSS_HT40_SCAN_ACTIVITY_THRESHOLD, - &cfg_value) != eSIR_SUCCESS) { + &cfg_value) != QDF_STATUS_SUCCESS) { pe_err("Fail to retrieve: %x value", WNI_CFG_OBSS_HT40_SCAN_ACTIVITY_THRESHOLD); return; @@ -7114,7 +7114,7 @@ void lim_send_set_dtim_period(tpAniSirGlobal mac_ctx, uint8_t dtim_period, tpPESession session) { struct set_dtim_params *dtim_params = NULL; - tSirRetStatus ret = eSIR_SUCCESS; + QDF_STATUS ret = QDF_STATUS_SUCCESS; struct scheduler_msg msg = {0}; if (!session) { @@ -7133,7 +7133,7 @@ void lim_send_set_dtim_period(tpAniSirGlobal mac_ctx, uint8_t dtim_period, msg.bodyval = 0; pe_debug("Post WMA_SET_DTIM_PERIOD to WMA"); ret = wma_post_ctrl_msg(mac_ctx, &msg); - if (eSIR_SUCCESS != ret) { + if (QDF_STATUS_SUCCESS != ret) { pe_err("wma_post_ctrl_msg() failed"); qdf_mem_free(dtim_params); } @@ -7363,14 +7363,14 @@ void lim_update_usr_he_cap(tpAniSirGlobal mac_ctx, tpPESession session) tDot11fIEhe_cap *he_cap = &session->he_config; struct he_cap_network_endian *he_cap_from_ie; uint8_t extracted_buff[DOT11F_IE_HE_CAP_MAX_LEN + 2]; - tSirRetStatus status; + QDF_STATUS status; qdf_mem_zero(extracted_buff, sizeof(extracted_buff)); status = lim_strip_ie(mac_ctx, add_ie->probeRespBCNData_buff, &add_ie->probeRespBCNDataLen, DOT11F_EID_HE_CAP, ONE_BYTE, HE_CAP_OUI_TYPE, (uint8_t)HE_CAP_OUI_SIZE, extracted_buff, DOT11F_IE_HE_CAP_MAX_LEN); - if (eSIR_SUCCESS != status) { + if (QDF_STATUS_SUCCESS != status) { pe_debug("Failed to strip HE cap IE status: %d", status); return; } @@ -7401,7 +7401,7 @@ void lim_decide_he_op(tpAniSirGlobal mac_ctx, tpAddBssParams add_bss, tDot11fIEhe_op *he_ops = &add_bss->he_op; tSirAddIeParams *add_ie = &session->addIeParams; uint8_t extracted_buff[DOT11F_IE_HE_OP_MAX_LEN + 2]; - tSirRetStatus status; + QDF_STATUS status; qdf_mem_zero(extracted_buff, sizeof(extracted_buff)); status = lim_strip_ie(mac_ctx, add_ie->probeRespBCNData_buff, @@ -7409,7 +7409,7 @@ void lim_decide_he_op(tpAniSirGlobal mac_ctx, tpAddBssParams add_bss, DOT11F_EID_HE_OP, ONE_BYTE, HE_OP_OUI_TYPE, (uint8_t)HE_OP_OUI_SIZE, extracted_buff, DOT11F_IE_HE_OP_MAX_LEN); - if (eSIR_SUCCESS != status) { + if (QDF_STATUS_SUCCESS != status) { pe_debug("Failed to strip HE OP IE status: %d", status); return; } @@ -7430,7 +7430,7 @@ void lim_decide_he_op(tpAniSirGlobal mac_ctx, tpAddBssParams add_bss, he_ops->tx_bssid_ind = he_ops_from_ie->tx_bssid_ind; he_ops->bss_col_disabled = he_ops_from_ie->bss_col_disabled; - if (eSIR_SUCCESS != wlan_cfg_get_int(mac_ctx, + if (QDF_STATUS_SUCCESS != wlan_cfg_get_int(mac_ctx, WNI_CFG_HE_OPS_BASIC_MCS_NSS, &val)) val = WNI_CFG_HE_OPS_BASIC_MCS_NSS_DEF; *((uint16_t *)he_ops->basic_mcs_nss) = (uint16_t)val; @@ -7879,12 +7879,12 @@ static QDF_STATUS lim_populate_he_mcs_per_bw(tpAniSirGlobal mac_ctx, pe_debug("peer rates: rx_mcs - 0x%04x tx_mcs - 0x%04x", peer_rx, peer_tx); - if (wlan_cfg_get_int(mac_ctx, cfg_rx_param, &val) != eSIR_SUCCESS) { + if (wlan_cfg_get_int(mac_ctx, cfg_rx_param, &val) != QDF_STATUS_SUCCESS) { pe_err("could not retrieve HE_MCS"); return QDF_STATUS_E_FAILURE; } *self_rx = (uint16_t) val; - if (wlan_cfg_get_int(mac_ctx, cfg_tx_param, &val) != eSIR_SUCCESS) { + if (wlan_cfg_get_int(mac_ctx, cfg_tx_param, &val) != QDF_STATUS_SUCCESS) { pe_err("could not retrieve HE_MCS"); return QDF_STATUS_E_FAILURE; } diff --git a/core/mac/src/pe/lim/lim_utils.h b/core/mac/src/pe/lim/lim_utils.h index 4811825efc..a639408aa0 100644 --- a/core/mac/src/pe/lim/lim_utils.h +++ b/core/mac/src/pe/lim/lim_utils.h @@ -135,7 +135,7 @@ void lim_print_sme_state(tpAniSirGlobal pMac, uint16_t logLevel, tLimSmeStates state); void lim_print_msg_name(tpAniSirGlobal pMac, uint16_t logLevel, uint32_t msgType); -extern tSirRetStatus lim_send_set_max_tx_power_req(tpAniSirGlobal pMac, +extern QDF_STATUS lim_send_set_max_tx_power_req(tpAniSirGlobal pMac, int8_t txPower, tpPESession pSessionEntry); extern uint8_t lim_get_max_tx_power(int8_t regMax, int8_t apTxPower, @@ -215,45 +215,45 @@ void lim_decide_ap_protection_on_delete(tpAniSirGlobal pMac, tpUpdateBeaconParams pBeaconParams, tpPESession psessionEntry); -extern tSirRetStatus lim_update_11a_protection(tpAniSirGlobal pMac, +extern QDF_STATUS lim_update_11a_protection(tpAniSirGlobal pMac, uint8_t enable, uint8_t overlap, tpUpdateBeaconParams pBeaconParams, tpPESession); -extern tSirRetStatus lim_enable11g_protection(tpAniSirGlobal pMac, +extern QDF_STATUS lim_enable11g_protection(tpAniSirGlobal pMac, uint8_t enable, uint8_t overlap, tpUpdateBeaconParams pBeaconParams, tpPESession psessionEntry); -extern tSirRetStatus lim_enable_ht_protection_from11g(tpAniSirGlobal pMac, +extern QDF_STATUS lim_enable_ht_protection_from11g(tpAniSirGlobal pMac, uint8_t enable, uint8_t overlap, tpUpdateBeaconParams pBeaconParams, tpPESession psessionEntry); -extern tSirRetStatus lim_enable_ht20_protection(tpAniSirGlobal pMac, +extern QDF_STATUS lim_enable_ht20_protection(tpAniSirGlobal pMac, uint8_t enable, uint8_t overlap, tpUpdateBeaconParams pBeaconParams, tpPESession sessionEntry); -extern tSirRetStatus lim_enable_ht_non_gf_protection(tpAniSirGlobal pMac, +extern QDF_STATUS lim_enable_ht_non_gf_protection(tpAniSirGlobal pMac, uint8_t enable, uint8_t overlap, tpUpdateBeaconParams pBeaconParams, tpPESession); -extern tSirRetStatus lim_enable_ht_rifs_protection(tpAniSirGlobal pMac, +extern QDF_STATUS lim_enable_ht_rifs_protection(tpAniSirGlobal pMac, uint8_t enable, uint8_t overlap, tpUpdateBeaconParams pBeaconParams, tpPESession psessionEntry); -extern tSirRetStatus lim_enable_ht_lsig_txop_protection(tpAniSirGlobal pMac, +extern QDF_STATUS lim_enable_ht_lsig_txop_protection(tpAniSirGlobal pMac, uint8_t enable, uint8_t overlap, tpUpdateBeaconParams pBeaconParams, tpPESession); -extern tSirRetStatus lim_enable_short_preamble(tpAniSirGlobal pMac, +extern QDF_STATUS lim_enable_short_preamble(tpAniSirGlobal pMac, uint8_t enable, tpUpdateBeaconParams pBeaconParams, tpPESession psessionEntry); -extern tSirRetStatus lim_enable_ht_obss_protection(tpAniSirGlobal pMac, +extern QDF_STATUS lim_enable_ht_obss_protection(tpAniSirGlobal pMac, uint8_t enable, uint8_t overlap, tpUpdateBeaconParams pBeaconParams, tpPESession); @@ -281,7 +281,7 @@ void lim_handle_defer_msg_error(tpAniSirGlobal pMac, /* Deferred Message Queue Reset */ void lim_reset_deferred_msg_q(tpAniSirGlobal pMac); -tSirRetStatus lim_sys_process_mmh_msg_api(tpAniSirGlobal, +QDF_STATUS lim_sys_process_mmh_msg_api(tpAniSirGlobal, struct scheduler_msg *, uint8_t); void lim_handle_update_olbc_cache(tpAniSirGlobal pMac); @@ -291,7 +291,7 @@ uint8_t lim_is_null_ssid(tSirMacSSid *pSsid); /* 11h Support */ void lim_stop_tx_and_switch_channel(tpAniSirGlobal pMac, uint8_t sessionId); void lim_process_channel_switch_timeout(tpAniSirGlobal); -tSirRetStatus lim_start_channel_switch(tpAniSirGlobal pMac, +QDF_STATUS lim_start_channel_switch(tpAniSirGlobal pMac, tpPESession psessionEntry); void lim_update_channel_switch(tpAniSirGlobal, tpSirProbeRespBeacon, tpPESession psessionEntry); @@ -321,9 +321,9 @@ bool lim_is_channel_valid_for_channel_switch(tpAniSirGlobal pMac, uint8_t channel); void lim_frame_transmission_control(tpAniSirGlobal pMac, tLimQuietTxMode type, tLimControlTx mode); -tSirRetStatus lim_restore_pre_channel_switch_state(tpAniSirGlobal pMac, +QDF_STATUS lim_restore_pre_channel_switch_state(tpAniSirGlobal pMac, tpPESession psessionEntry); -tSirRetStatus lim_restore_pre_quiet_state(tpAniSirGlobal pMac, +QDF_STATUS lim_restore_pre_quiet_state(tpAniSirGlobal pMac, tpPESession psessionEntry); void lim_prepare_for11h_channel_switch(tpAniSirGlobal pMac, @@ -356,7 +356,7 @@ static inline enum band_info lim_get_rf_band(uint8_t channel) return BAND_UNKNOWN; } -static inline tSirRetStatus +static inline QDF_STATUS lim_get_mgmt_staid(tpAniSirGlobal pMac, uint16_t *staid, tpPESession psessionEntry) { @@ -365,9 +365,9 @@ lim_get_mgmt_staid(tpAniSirGlobal pMac, uint16_t *staid, else if (LIM_IS_STA_ROLE(psessionEntry)) *staid = 0; else - return eSIR_FAILURE; + return QDF_STATUS_E_FAILURE; - return eSIR_SUCCESS; + return QDF_STATUS_SUCCESS; } static inline uint8_t lim_is_system_in_set_mimops_state(tpAniSirGlobal pMac) @@ -443,9 +443,9 @@ QDF_STATUS lim_tx_complete(void *context, qdf_nbuf_t buf, bool free); */ void lim_process_del_ts_ind(tpAniSirGlobal pMac, struct scheduler_msg *limMsg); -tSirRetStatus lim_process_hal_ind_messages(tpAniSirGlobal pMac, uint32_t mesgId, +QDF_STATUS lim_process_hal_ind_messages(tpAniSirGlobal pMac, uint32_t mesgId, void *mesgParam); -tSirRetStatus lim_validate_delts_req(tpAniSirGlobal pMac, +QDF_STATUS lim_validate_delts_req(tpAniSirGlobal pMac, tpSirDeltsReq pDeltsReq, tSirMacAddr peerMacAddr, tpPESession psessionEntry); @@ -478,7 +478,7 @@ static inline uint32_t utils_power_xy(uint16_t base, uint16_t power) return result; } -tSirRetStatus lim_post_sm_state_update(tpAniSirGlobal pMac, +QDF_STATUS lim_post_sm_state_update(tpAniSirGlobal pMac, uint16_t StaIdx, tSirMacHTMIMOPowerSaveState MIMOPSState, uint8_t *pPeerStaMac, uint8_t sessionId); @@ -763,11 +763,11 @@ QDF_STATUS lim_send_ext_cap_ie(tpAniSirGlobal mac_ctx, uint32_t session_id, QDF_STATUS lim_send_ies_per_band(tpAniSirGlobal mac_ctx, tpPESession session, uint8_t vdev_id); -tSirRetStatus lim_strip_extcap_ie(tpAniSirGlobal mac_ctx, uint8_t *addn_ie, +QDF_STATUS lim_strip_extcap_ie(tpAniSirGlobal mac_ctx, uint8_t *addn_ie, uint16_t *addn_ielen, uint8_t *extracted_extcap); void lim_update_extcap_struct(tpAniSirGlobal mac_ctx, uint8_t *buf, tDot11fIEExtCap *ext_cap); -tSirRetStatus lim_strip_extcap_update_struct(tpAniSirGlobal mac_ctx, +QDF_STATUS lim_strip_extcap_update_struct(tpAniSirGlobal mac_ctx, uint8_t *addn_ie, uint16_t *addn_ielen, tDot11fIEExtCap *dst); void lim_merge_extcap_struct(tDot11fIEExtCap *dst, tDot11fIEExtCap *src, bool add); @@ -810,9 +810,9 @@ lim_del_pmf_sa_query_timer(tpAniSirGlobal mac_ctx, tpPESession pe_session) * This function is used to strip supp op class IE from IE buffer and * update the passed structure. * - * Return: tSirRetStatus + * Return: QDF_STATUS */ -tSirRetStatus lim_strip_supp_op_class_update_struct(tpAniSirGlobal mac_ctx, +QDF_STATUS lim_strip_supp_op_class_update_struct(tpAniSirGlobal mac_ctx, uint8_t *addn_ie, uint16_t *addn_ielen, tDot11fIESuppOperatingClasses *dst); @@ -877,7 +877,7 @@ void lim_update_caps_info_for_bss(tpAniSirGlobal mac_ctx, void lim_send_set_dtim_period(tpAniSirGlobal mac_ctx, uint8_t dtim_period, tpPESession session); -tSirRetStatus lim_strip_ie(tpAniSirGlobal mac_ctx, +QDF_STATUS lim_strip_ie(tpAniSirGlobal mac_ctx, uint8_t *addn_ie, uint16_t *addn_ielen, uint8_t eid, eSizeOfLenField size_of_len_field, uint8_t *oui, uint8_t out_len, uint8_t *extracted_ie,