mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-15 01:01:56 -04:00
qcacld-3.0: pe: sch: Replace tSirRetStatus with QDF_STATUS
The tSirRetStatus definitions are obsolete, so replace them with QDF_STATUS definitions in the mac pe/sch folder. Change-Id: I7301c209adccdb63b1f1ac063d4590b5019f2e40 CRs-Fixed: 2269738
This commit is contained in:
parent
cb88d0abbc
commit
65250f2456
5 changed files with 142 additions and 122 deletions
|
|
@ -35,60 +35,65 @@
|
|||
#include "ani_global.h"
|
||||
|
||||
/* update only the broadcast qos params */
|
||||
extern void sch_qos_update_broadcast(tpAniSirGlobal pMac,
|
||||
tpPESession psessionEntry);
|
||||
void sch_qos_update_broadcast(tpAniSirGlobal pMac,
|
||||
tpPESession psessionEntry);
|
||||
|
||||
/* fill in the default local edca parameter into gLimEdcaParams[] */
|
||||
extern void sch_set_default_edca_params(tpAniSirGlobal pMac, tpPESession psessionE);
|
||||
void sch_set_default_edca_params(tpAniSirGlobal pMac, tpPESession psessionE);
|
||||
|
||||
/* update only local qos params */
|
||||
extern void sch_qos_update_local(tpAniSirGlobal pMac, tpPESession psessionEntry);
|
||||
void sch_qos_update_local(tpAniSirGlobal pMac, tpPESession psessionEntry);
|
||||
|
||||
/* update the edca profile parameters */
|
||||
extern void sch_edca_profile_update(tpAniSirGlobal pMac,
|
||||
tpPESession psessionEntry);
|
||||
void sch_edca_profile_update(tpAniSirGlobal pMac,
|
||||
tpPESession psessionEntry);
|
||||
|
||||
/* / Set the fixed fields in a beacon frame */
|
||||
extern tSirRetStatus sch_set_fixed_beacon_fields(tpAniSirGlobal pMac,
|
||||
tpPESession psessionEntry);
|
||||
QDF_STATUS sch_set_fixed_beacon_fields(tpAniSirGlobal pMac,
|
||||
tpPESession psessionEntry);
|
||||
|
||||
/* / Process the scheduler messages */
|
||||
extern void sch_process_message(tpAniSirGlobal pMac,
|
||||
struct scheduler_msg *pSchMsg);
|
||||
void sch_process_message(tpAniSirGlobal pMac,
|
||||
struct scheduler_msg *pSchMsg);
|
||||
|
||||
/* / The beacon Indication handler function */
|
||||
extern void sch_process_pre_beacon_ind(tpAniSirGlobal pMac,
|
||||
struct scheduler_msg *limMsg);
|
||||
void sch_process_pre_beacon_ind(tpAniSirGlobal pMac,
|
||||
struct scheduler_msg *limMsg);
|
||||
|
||||
/* / Post a message to the scheduler message queue */
|
||||
extern tSirRetStatus sch_post_message(tpAniSirGlobal pMac,
|
||||
struct scheduler_msg *pMsg);
|
||||
QDF_STATUS sch_post_message(tpAniSirGlobal pMac,
|
||||
struct scheduler_msg *pMsg);
|
||||
|
||||
extern void sch_beacon_process(tpAniSirGlobal pMac, uint8_t *pRxPacketInfo,
|
||||
tpPESession psessionEntry);
|
||||
extern tSirRetStatus sch_beacon_edca_process(tpAniSirGlobal pMac,
|
||||
tSirMacEdcaParamSetIE *edca,
|
||||
tpPESession psessionEntry);
|
||||
void sch_beacon_process(tpAniSirGlobal pMac, uint8_t *pRxPacketInfo,
|
||||
tpPESession psessionEntry);
|
||||
|
||||
QDF_STATUS sch_beacon_edca_process(tpAniSirGlobal pMac,
|
||||
tSirMacEdcaParamSetIE *edca,
|
||||
tpPESession psessionEntry);
|
||||
|
||||
void sch_generate_tim(tpAniSirGlobal, uint8_t **, uint16_t *, uint8_t);
|
||||
|
||||
void sch_set_beacon_interval(tpAniSirGlobal pMac, tpPESession psessionEntry);
|
||||
|
||||
tSirRetStatus sch_send_beacon_req(tpAniSirGlobal, uint8_t *, uint16_t,
|
||||
tpPESession psessionEntry);
|
||||
QDF_STATUS sch_send_beacon_req(tpAniSirGlobal, uint8_t *, uint16_t,
|
||||
tpPESession psessionEntry);
|
||||
|
||||
tSirRetStatus lim_update_probe_rsp_template_ie_bitmap_beacon1(tpAniSirGlobal,
|
||||
tDot11fBeacon1 *,
|
||||
tpPESession
|
||||
psessionEntry);
|
||||
void lim_update_probe_rsp_template_ie_bitmap_beacon2(tpAniSirGlobal, tDot11fBeacon2 *,
|
||||
QDF_STATUS lim_update_probe_rsp_template_ie_bitmap_beacon1(tpAniSirGlobal,
|
||||
tDot11fBeacon1 *,
|
||||
tpPESession
|
||||
psessionEntry);
|
||||
void lim_update_probe_rsp_template_ie_bitmap_beacon2(tpAniSirGlobal,
|
||||
tDot11fBeacon2 *,
|
||||
uint32_t *,
|
||||
tDot11fProbeResponse *);
|
||||
void set_probe_rsp_ie_bitmap(uint32_t *, uint32_t);
|
||||
uint32_t lim_send_probe_rsp_template_to_hal(tpAniSirGlobal, tpPESession, uint32_t *);
|
||||
uint32_t lim_send_probe_rsp_template_to_hal(tpAniSirGlobal,
|
||||
tpPESession,
|
||||
uint32_t *);
|
||||
|
||||
int sch_gen_timing_advert_frame(tpAniSirGlobal pMac, tSirMacAddr self_addr,
|
||||
uint8_t **buf, uint32_t *timestamp_offset, uint32_t *time_value_offset);
|
||||
uint8_t **buf, uint32_t *timestamp_offset,
|
||||
uint32_t *time_value_offset);
|
||||
|
||||
/*
|
||||
* sch_beacon_process_for_ap() - process the beacon frame for AP sessions
|
||||
|
|
@ -109,8 +114,8 @@ int sch_gen_timing_advert_frame(tpAniSirGlobal pMac, tSirMacAddr self_addr,
|
|||
* Return: None
|
||||
*/
|
||||
void sch_beacon_process_for_ap(tpAniSirGlobal mac_ctx,
|
||||
uint8_t session_id,
|
||||
uint8_t *rx_pkt_info,
|
||||
tSchBeaconStruct *bcn);
|
||||
uint8_t session_id,
|
||||
uint8_t *rx_pkt_info,
|
||||
tSchBeaconStruct *bcn);
|
||||
|
||||
#endif
|
||||
|
|
|
|||
|
|
@ -69,11 +69,11 @@
|
|||
* @return None
|
||||
*/
|
||||
|
||||
tSirRetStatus sch_post_message(tpAniSirGlobal pMac, struct scheduler_msg *pMsg)
|
||||
QDF_STATUS sch_post_message(tpAniSirGlobal pMac, struct scheduler_msg *pMsg)
|
||||
{
|
||||
sch_process_message(pMac, pMsg);
|
||||
|
||||
return eSIR_SUCCESS;
|
||||
return QDF_STATUS_SUCCESS;
|
||||
}
|
||||
|
||||
/* --------------------------------------------------------------------------- */
|
||||
|
|
@ -103,12 +103,12 @@ tSirRetStatus sch_post_message(tpAniSirGlobal pMac, struct scheduler_msg *pMsg)
|
|||
*
|
||||
* @return QDF_STATUS
|
||||
*/
|
||||
tSirRetStatus sch_send_beacon_req(tpAniSirGlobal pMac, uint8_t *beaconPayload,
|
||||
uint16_t size, tpPESession psessionEntry)
|
||||
QDF_STATUS sch_send_beacon_req(tpAniSirGlobal pMac, uint8_t *beaconPayload,
|
||||
uint16_t size, tpPESession psessionEntry)
|
||||
{
|
||||
struct scheduler_msg msgQ = {0};
|
||||
tpSendbeaconParams beaconParams = NULL;
|
||||
tSirRetStatus retCode;
|
||||
QDF_STATUS retCode;
|
||||
|
||||
pe_debug("Indicating HAL to copy the beacon template [%d bytes] to memory",
|
||||
size);
|
||||
|
|
@ -118,14 +118,14 @@ tSirRetStatus sch_send_beacon_req(tpAniSirGlobal pMac, uint8_t *beaconPayload,
|
|||
retCode = lim_send_probe_rsp_template_to_hal(pMac,
|
||||
psessionEntry,
|
||||
&psessionEntry->DefProbeRspIeBitmap[0]);
|
||||
if (eSIR_SUCCESS != retCode)
|
||||
if (QDF_STATUS_SUCCESS != retCode)
|
||||
pe_err("FAILED to send probe response template with retCode %d",
|
||||
retCode);
|
||||
}
|
||||
|
||||
beaconParams = qdf_mem_malloc(sizeof(tSendbeaconParams));
|
||||
if (NULL == beaconParams)
|
||||
return eSIR_MEM_ALLOC_FAILED;
|
||||
return QDF_STATUS_E_NOMEM;
|
||||
|
||||
msgQ.type = WMA_SEND_BEACON_REQ;
|
||||
|
||||
|
|
@ -159,7 +159,7 @@ tSirRetStatus sch_send_beacon_req(tpAniSirGlobal pMac, uint8_t *beaconPayload,
|
|||
pMac->sch.schObject.p2pIeOffset);
|
||||
QDF_ASSERT(0);
|
||||
qdf_mem_free(beaconParams);
|
||||
return eSIR_FAILURE;
|
||||
return QDF_STATUS_E_FAILURE;
|
||||
}
|
||||
beaconParams->p2pIeOffset = pMac->sch.schObject.p2pIeOffset;
|
||||
#ifdef WLAN_SOFTAP_FW_BEACON_TX_PRNT_LOG
|
||||
|
|
@ -189,7 +189,7 @@ tSirRetStatus sch_send_beacon_req(tpAniSirGlobal pMac, uint8_t *beaconPayload,
|
|||
|
||||
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 SEND_BEACON_REQ to HAL failed, reason=%X",
|
||||
retCode);
|
||||
else
|
||||
|
|
@ -219,7 +219,7 @@ static uint32_t lim_remove_p2p_ie_from_add_ie(tpAniSirGlobal pMac,
|
|||
left -= 2;
|
||||
if (elem_len > left) {
|
||||
pe_err("Invalid IEs");
|
||||
return eSIR_FAILURE;
|
||||
return QDF_STATUS_E_FAILURE;
|
||||
}
|
||||
if ((elem_id == eid) &&
|
||||
(!qdf_mem_cmp(&ptr[2],
|
||||
|
|
@ -235,7 +235,7 @@ static uint32_t lim_remove_p2p_ie_from_add_ie(tpAniSirGlobal pMac,
|
|||
}
|
||||
}
|
||||
}
|
||||
return eSIR_SUCCESS;
|
||||
return QDF_STATUS_SUCCESS;
|
||||
}
|
||||
|
||||
uint32_t lim_send_probe_rsp_template_to_hal(tpAniSirGlobal pMac,
|
||||
|
|
@ -245,7 +245,7 @@ uint32_t lim_send_probe_rsp_template_to_hal(tpAniSirGlobal pMac,
|
|||
struct scheduler_msg msgQ = {0};
|
||||
uint8_t *pFrame2Hal = psessionEntry->pSchProbeRspTemplate;
|
||||
tpSendProbeRespParams pprobeRespParams = NULL;
|
||||
uint32_t retCode = eSIR_FAILURE;
|
||||
uint32_t retCode = QDF_STATUS_E_FAILURE;
|
||||
uint32_t nPayload, nBytes = 0, nStatus;
|
||||
tpSirMacMgmtHdr pMacHdr;
|
||||
uint32_t addnIEPresent = false;
|
||||
|
|
@ -256,7 +256,7 @@ uint32_t lim_send_probe_rsp_template_to_hal(tpAniSirGlobal pMac,
|
|||
tDot11fIEExtCap extracted_extcap;
|
||||
bool extcap_present = false;
|
||||
tDot11fProbeResponse *prb_rsp_frm;
|
||||
tSirRetStatus status;
|
||||
QDF_STATUS status;
|
||||
uint16_t addn_ielen = 0;
|
||||
|
||||
/* Check if probe response IE is present or not */
|
||||
|
|
@ -276,14 +276,14 @@ uint32_t lim_send_probe_rsp_template_to_hal(tpAniSirGlobal pMac,
|
|||
probeRespDataLen);
|
||||
if (NULL == addIeWoP2pIe) {
|
||||
pe_err("FAILED to alloc memory when removing P2P IE");
|
||||
return eSIR_MEM_ALLOC_FAILED;
|
||||
return QDF_STATUS_E_NOMEM;
|
||||
}
|
||||
|
||||
retStatus = lim_remove_p2p_ie_from_add_ie(pMac, psessionEntry,
|
||||
addIeWoP2pIe, &addnIELenWoP2pIe);
|
||||
if (retStatus != eSIR_SUCCESS) {
|
||||
if (retStatus != QDF_STATUS_SUCCESS) {
|
||||
qdf_mem_free(addIeWoP2pIe);
|
||||
return eSIR_FAILURE;
|
||||
return QDF_STATUS_E_FAILURE;
|
||||
}
|
||||
|
||||
/* Probe rsp IE available */
|
||||
|
|
@ -292,7 +292,7 @@ uint32_t lim_send_probe_rsp_template_to_hal(tpAniSirGlobal pMac,
|
|||
if (NULL == addIE) {
|
||||
pe_err("Unable to get WNI_CFG_PROBE_RSP_ADDNIE_DATA1 length");
|
||||
qdf_mem_free(addIeWoP2pIe);
|
||||
return eSIR_MEM_ALLOC_FAILED;
|
||||
return QDF_STATUS_E_NOMEM;
|
||||
}
|
||||
addn_ielen = addnIELenWoP2pIe;
|
||||
|
||||
|
|
@ -306,7 +306,7 @@ uint32_t lim_send_probe_rsp_template_to_hal(tpAniSirGlobal pMac,
|
|||
sizeof(tDot11fIEExtCap));
|
||||
status = lim_strip_extcap_update_struct(pMac, addIE,
|
||||
&addn_ielen, &extracted_extcap);
|
||||
if (eSIR_SUCCESS != status) {
|
||||
if (QDF_STATUS_SUCCESS != status) {
|
||||
pe_debug("extcap not extracted");
|
||||
} else {
|
||||
extcap_present = true;
|
||||
|
|
@ -349,7 +349,7 @@ uint32_t lim_send_probe_rsp_template_to_hal(tpAniSirGlobal pMac,
|
|||
if (nBytes > SCH_MAX_PROBE_RESP_SIZE) {
|
||||
pe_err("nBytes %d greater than max size", nBytes);
|
||||
qdf_mem_free(addIE);
|
||||
return eSIR_FAILURE;
|
||||
return QDF_STATUS_E_FAILURE;
|
||||
}
|
||||
|
||||
/* Paranoia: */
|
||||
|
|
@ -404,7 +404,7 @@ uint32_t lim_send_probe_rsp_template_to_hal(tpAniSirGlobal pMac,
|
|||
msgQ.bodyval = 0;
|
||||
|
||||
retCode = wma_post_ctrl_msg(pMac, &msgQ);
|
||||
if (eSIR_SUCCESS != retCode) {
|
||||
if (QDF_STATUS_SUCCESS != retCode) {
|
||||
pe_err("lim_send_probe_rsp_template_to_hal: FAIL bytes %d retcode[%X]",
|
||||
nBytes, retCode);
|
||||
qdf_mem_free(pprobeRespParams);
|
||||
|
|
@ -461,7 +461,7 @@ int sch_gen_timing_advert_frame(tpAniSirGlobal mac_ctx, tSirMacAddr self_addr,
|
|||
*buf = qdf_mem_malloc(buf_size);
|
||||
if (*buf == NULL) {
|
||||
pe_err("Cannot allocate memory");
|
||||
return eSIR_FAILURE;
|
||||
return QDF_STATUS_E_FAILURE;
|
||||
}
|
||||
|
||||
payload_size = 0;
|
||||
|
|
|
|||
|
|
@ -49,11 +49,11 @@
|
|||
|
||||
const uint8_t p2p_oui[] = { 0x50, 0x6F, 0x9A, 0x9 };
|
||||
|
||||
static tSirRetStatus sch_get_p2p_ie_offset(uint8_t *pExtraIe,
|
||||
uint32_t extraIeLen,
|
||||
uint16_t *pP2pIeOffset)
|
||||
static QDF_STATUS sch_get_p2p_ie_offset(uint8_t *pExtraIe,
|
||||
uint32_t extraIeLen,
|
||||
uint16_t *pP2pIeOffset)
|
||||
{
|
||||
tSirRetStatus status = eSIR_FAILURE;
|
||||
QDF_STATUS status = QDF_STATUS_E_FAILURE;
|
||||
*pP2pIeOffset = 0;
|
||||
|
||||
/* Extra IE is not present */
|
||||
|
|
@ -65,7 +65,7 @@ static tSirRetStatus sch_get_p2p_ie_offset(uint8_t *pExtraIe,
|
|||
if (*pExtraIe == 0xDD) {
|
||||
if (!qdf_mem_cmp
|
||||
((void *)(pExtraIe + 2), &p2p_oui, sizeof(p2p_oui))) {
|
||||
status = eSIR_SUCCESS;
|
||||
status = QDF_STATUS_SUCCESS;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
|
@ -89,12 +89,12 @@ static tSirRetStatus sch_get_p2p_ie_offset(uint8_t *pExtraIe,
|
|||
*
|
||||
* Return: status of operation
|
||||
*/
|
||||
static tSirRetStatus
|
||||
static QDF_STATUS
|
||||
sch_append_addn_ie(tpAniSirGlobal mac_ctx, tpPESession session,
|
||||
uint8_t *frm, uint32_t max_bcn_size, uint32_t *num_bytes,
|
||||
uint8_t *addn_ie, uint16_t addn_ielen)
|
||||
{
|
||||
tSirRetStatus status = eSIR_FAILURE;
|
||||
QDF_STATUS status = QDF_STATUS_E_FAILURE;
|
||||
uint8_t add_ie[WNI_CFG_PROBE_RSP_BCN_ADDNIE_DATA_LEN];
|
||||
uint8_t *p2p_ie = NULL;
|
||||
uint8_t noa_len = 0;
|
||||
|
|
@ -121,9 +121,10 @@ sch_append_addn_ie(tpAniSirGlobal mac_ctx, tpPESession session,
|
|||
|
||||
qdf_mem_copy(&add_ie[0], addn_ie, addn_ielen);
|
||||
|
||||
if (status == eSIR_SUCCESS && ext_p2p_ie[0] == SIR_MAC_EID_VENDOR &&
|
||||
if (status == QDF_STATUS_SUCCESS &&
|
||||
ext_p2p_ie[0] == SIR_MAC_EID_VENDOR &&
|
||||
!qdf_mem_cmp(&ext_p2p_ie[2], SIR_MAC_P2P_OUI,
|
||||
SIR_MAC_P2P_OUI_SIZE)) {
|
||||
SIR_MAC_P2P_OUI_SIZE)) {
|
||||
qdf_mem_copy(&add_ie[addn_ielen], ext_p2p_ie,
|
||||
ext_p2p_ie[1] + 2);
|
||||
addn_ielen += ext_p2p_ie[1] + 2;
|
||||
|
|
@ -212,7 +213,7 @@ static void sch_get_csa_ecsa_count_offset(uint8_t *ie, uint32_t ie_len,
|
|||
* Return: status of operation
|
||||
*/
|
||||
|
||||
tSirRetStatus
|
||||
QDF_STATUS
|
||||
sch_set_fixed_beacon_fields(tpAniSirGlobal mac_ctx, tpPESession session)
|
||||
{
|
||||
tpAniBeaconStruct bcn_struct = (tpAniBeaconStruct)
|
||||
|
|
@ -231,7 +232,7 @@ sch_set_fixed_beacon_fields(tpAniSirGlobal mac_ctx, tpPESession session)
|
|||
uint16_t p2p_ie_offset = 0;
|
||||
uint32_t csa_count_offset = 0;
|
||||
uint32_t ecsa_count_offset = 0;
|
||||
tSirRetStatus status = eSIR_SUCCESS;
|
||||
QDF_STATUS status = QDF_STATUS_SUCCESS;
|
||||
bool is_vht_enabled = false;
|
||||
uint16_t addn_ielen = 0;
|
||||
uint8_t *addn_ie = NULL;
|
||||
|
|
@ -241,14 +242,14 @@ sch_set_fixed_beacon_fields(tpAniSirGlobal mac_ctx, tpPESession session)
|
|||
bcn_1 = qdf_mem_malloc(sizeof(tDot11fBeacon1));
|
||||
if (NULL == bcn_1) {
|
||||
pe_err("Failed to allocate memory");
|
||||
return eSIR_MEM_ALLOC_FAILED;
|
||||
return QDF_STATUS_E_NOMEM;
|
||||
}
|
||||
|
||||
bcn_2 = qdf_mem_malloc(sizeof(tDot11fBeacon2));
|
||||
if (NULL == bcn_2) {
|
||||
pe_err("Failed to allocate memory");
|
||||
qdf_mem_free(bcn_1);
|
||||
return eSIR_MEM_ALLOC_FAILED;
|
||||
return QDF_STATUS_E_NOMEM;
|
||||
}
|
||||
|
||||
wsc_prb_res = qdf_mem_malloc(sizeof(tDot11fIEWscProbeRes));
|
||||
|
|
@ -256,7 +257,7 @@ sch_set_fixed_beacon_fields(tpAniSirGlobal mac_ctx, tpPESession session)
|
|||
pe_err("Failed to allocate memory");
|
||||
qdf_mem_free(bcn_1);
|
||||
qdf_mem_free(bcn_2);
|
||||
return eSIR_MEM_ALLOC_FAILED;
|
||||
return QDF_STATUS_E_NOMEM;
|
||||
}
|
||||
|
||||
pe_debug("Setting fixed beacon fields");
|
||||
|
|
@ -317,7 +318,7 @@ sch_set_fixed_beacon_fields(tpAniSirGlobal mac_ctx, tpPESession session)
|
|||
* response in future
|
||||
*/
|
||||
if (lim_update_probe_rsp_template_ie_bitmap_beacon1(mac_ctx,
|
||||
bcn_1, session) != eSIR_SUCCESS)
|
||||
bcn_1, session) != QDF_STATUS_SUCCESS)
|
||||
pe_err("Failed to build ProbeRsp template");
|
||||
}
|
||||
|
||||
|
|
@ -329,7 +330,7 @@ sch_set_fixed_beacon_fields(tpAniSirGlobal mac_ctx, tpPESession session)
|
|||
qdf_mem_free(bcn_1);
|
||||
qdf_mem_free(bcn_2);
|
||||
qdf_mem_free(wsc_prb_res);
|
||||
return eSIR_FAILURE;
|
||||
return QDF_STATUS_E_FAILURE;
|
||||
} else if (DOT11F_WARNED(n_status)) {
|
||||
pe_warn("Warnings while packing a tDot11fBeacon1(0x%08x)",
|
||||
n_status);
|
||||
|
|
@ -487,8 +488,8 @@ sch_set_fixed_beacon_fields(tpAniSirGlobal mac_ctx, tpPESession session)
|
|||
&bcn_2->WscBeacon, session);
|
||||
}
|
||||
} else {
|
||||
if (wlan_cfg_get_int(mac_ctx,
|
||||
(uint16_t) WNI_CFG_WPS_ENABLE, &tmp) != eSIR_SUCCESS)
|
||||
status = wlan_cfg_get_int(mac_ctx, WNI_CFG_WPS_ENABLE, &tmp);
|
||||
if (QDF_IS_STATUS_ERROR(status))
|
||||
pe_err("Failed to cfg get id %d", WNI_CFG_WPS_ENABLE);
|
||||
|
||||
wps_ap_enable = tmp & WNI_CFG_WPS_ENABLE_AP;
|
||||
|
|
@ -551,7 +552,7 @@ sch_set_fixed_beacon_fields(tpAniSirGlobal mac_ctx, tpPESession session)
|
|||
qdf_mem_free(bcn_1);
|
||||
qdf_mem_free(bcn_2);
|
||||
qdf_mem_free(wsc_prb_res);
|
||||
return eSIR_MEM_ALLOC_FAILED;
|
||||
return QDF_STATUS_E_NOMEM;
|
||||
}
|
||||
qdf_mem_copy(addn_ie,
|
||||
session->addIeParams.probeRespBCNData_buff,
|
||||
|
|
@ -561,7 +562,7 @@ sch_set_fixed_beacon_fields(tpAniSirGlobal mac_ctx, tpPESession session)
|
|||
sizeof(tDot11fIEExtCap));
|
||||
status = lim_strip_extcap_update_struct(mac_ctx, addn_ie,
|
||||
&addn_ielen, &extracted_extcap);
|
||||
if (eSIR_SUCCESS != status) {
|
||||
if (QDF_STATUS_SUCCESS != status) {
|
||||
extcap_present = false;
|
||||
pe_debug("extcap not extracted");
|
||||
}
|
||||
|
|
@ -584,7 +585,7 @@ sch_set_fixed_beacon_fields(tpAniSirGlobal mac_ctx, tpPESession session)
|
|||
qdf_mem_free(bcn_2);
|
||||
qdf_mem_free(wsc_prb_res);
|
||||
qdf_mem_free(addn_ie);
|
||||
return eSIR_FAILURE;
|
||||
return QDF_STATUS_E_FAILURE;
|
||||
} else if (DOT11F_WARNED(n_status)) {
|
||||
pe_err("Warnings while packing a tDot11fBeacon2(0x%08x)",
|
||||
n_status);
|
||||
|
|
@ -623,7 +624,7 @@ sch_set_fixed_beacon_fields(tpAniSirGlobal mac_ctx, tpPESession session)
|
|||
extra_ie_len = n_bytes - extra_ie_offset;
|
||||
/* Get the p2p Ie Offset */
|
||||
status = sch_get_p2p_ie_offset(extra_ie, extra_ie_len, &p2p_ie_offset);
|
||||
if (eSIR_SUCCESS == status)
|
||||
if (QDF_STATUS_SUCCESS == status)
|
||||
/* Update the P2P Ie Offset */
|
||||
mac_ctx->sch.schObject.p2pIeOffset =
|
||||
session->schBeaconOffsetBegin + TIM_IE_SIZE +
|
||||
|
|
@ -638,20 +639,20 @@ sch_set_fixed_beacon_fields(tpAniSirGlobal mac_ctx, tpPESession session)
|
|||
qdf_mem_free(bcn_2);
|
||||
qdf_mem_free(wsc_prb_res);
|
||||
qdf_mem_free(addn_ie);
|
||||
return eSIR_SUCCESS;
|
||||
return QDF_STATUS_SUCCESS;
|
||||
}
|
||||
|
||||
tSirRetStatus lim_update_probe_rsp_template_ie_bitmap_beacon1(tpAniSirGlobal pMac,
|
||||
tDot11fBeacon1 *beacon1,
|
||||
tpPESession
|
||||
psessionEntry)
|
||||
QDF_STATUS
|
||||
lim_update_probe_rsp_template_ie_bitmap_beacon1(tpAniSirGlobal pMac,
|
||||
tDot11fBeacon1 *beacon1,
|
||||
tpPESession psessionEntry)
|
||||
{
|
||||
uint32_t *DefProbeRspIeBitmap;
|
||||
tDot11fProbeResponse *prb_rsp;
|
||||
|
||||
if (!psessionEntry) {
|
||||
pe_debug("PESession is null!");
|
||||
return eSIR_FAILURE;
|
||||
return QDF_STATUS_E_FAILURE;
|
||||
}
|
||||
DefProbeRspIeBitmap = &psessionEntry->DefProbeRspIeBitmap[0];
|
||||
prb_rsp = &psessionEntry->probeRespFrame;
|
||||
|
|
@ -685,7 +686,7 @@ tSirRetStatus lim_update_probe_rsp_template_ie_bitmap_beacon1(tpAniSirGlobal pMa
|
|||
}
|
||||
|
||||
/* IBSS params will not be present in the Beacons transmitted by AP */
|
||||
return eSIR_SUCCESS;
|
||||
return QDF_STATUS_SUCCESS;
|
||||
}
|
||||
|
||||
void lim_update_probe_rsp_template_ie_bitmap_beacon2(tpAniSirGlobal pMac,
|
||||
|
|
@ -906,6 +907,7 @@ static void write_beacon_to_memory(tpAniSirGlobal pMac, uint16_t size,
|
|||
{
|
||||
uint16_t i;
|
||||
tpAniBeaconStruct pBeacon;
|
||||
QDF_STATUS status;
|
||||
|
||||
/* copy end of beacon only if length > 0 */
|
||||
if (length > 0) {
|
||||
|
|
@ -932,10 +934,11 @@ static void write_beacon_to_memory(tpAniSirGlobal pMac, uint16_t size,
|
|||
*/
|
||||
|
||||
size = (size + 3) & (~3);
|
||||
if (eSIR_SUCCESS != sch_send_beacon_req(pMac,
|
||||
psessionEntry->pSchBeaconFrameBegin, size, psessionEntry))
|
||||
pe_err("sch_send_beacon_req() returned an error (zsize %d)",
|
||||
size);
|
||||
status = sch_send_beacon_req(pMac, psessionEntry->pSchBeaconFrameBegin,
|
||||
size, psessionEntry);
|
||||
if (QDF_IS_STATUS_ERROR(status))
|
||||
pe_err("sch_send_beacon_req() returned an error %d, size %d",
|
||||
status, size);
|
||||
|
||||
pMac->sch.schObject.fBeaconChanged = 0;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -350,6 +350,8 @@ sch_bcn_process_sta(tpAniSirGlobal mac_ctx,
|
|||
{
|
||||
uint32_t bi;
|
||||
tpDphHashNode pStaDs = NULL;
|
||||
QDF_STATUS status;
|
||||
|
||||
/*
|
||||
* This handles two cases:
|
||||
* -- Infra STA receiving beacons from AP
|
||||
|
|
@ -367,7 +369,7 @@ sch_bcn_process_sta(tpAniSirGlobal mac_ctx,
|
|||
}
|
||||
lim_detect_change_in_ap_capabilities(mac_ctx, bcn, session);
|
||||
if (lim_get_sta_hash_bssidx(mac_ctx, DPH_STA_HASH_INDEX_PEER, bssIdx,
|
||||
session) != eSIR_SUCCESS)
|
||||
session) != QDF_STATUS_SUCCESS)
|
||||
return false;
|
||||
|
||||
beaconParams->bssIdx = *bssIdx;
|
||||
|
|
@ -425,12 +427,14 @@ sch_bcn_process_sta(tpAniSirGlobal mac_ctx,
|
|||
|
||||
pStaDs = dph_get_hash_entry(mac_ctx, DPH_STA_HASH_INDEX_PEER,
|
||||
&session->dph.dphHashTable);
|
||||
if ((bcn->wmeEdcaPresent && (session->limWmeEnabled))
|
||||
|| (bcn->edcaPresent && (session->limQosEnabled))) {
|
||||
if ((bcn->wmeEdcaPresent && session->limWmeEnabled) ||
|
||||
(bcn->edcaPresent && session->limQosEnabled)) {
|
||||
if (bcn->edcaParams.qosInfo.count !=
|
||||
session->gLimEdcaParamSetCount) {
|
||||
if (sch_beacon_edca_process(mac_ctx, &bcn->edcaParams,
|
||||
session) != eSIR_SUCCESS) {
|
||||
status = sch_beacon_edca_process(mac_ctx,
|
||||
&bcn->edcaParams,
|
||||
session);
|
||||
if (QDF_IS_STATUS_ERROR(status)) {
|
||||
pe_err("EDCA parameter processing error");
|
||||
} else if (pStaDs != NULL) {
|
||||
/* If needed, downgrade the EDCA parameters */
|
||||
|
|
@ -875,7 +879,7 @@ static void __sch_beacon_process_for_session(tpAniSirGlobal mac_ctx,
|
|||
FL("Local power constraint change, Updating new maxTx power %d from old pwr %d"),
|
||||
maxTxPower, session->maxTxPower);
|
||||
if (lim_send_set_max_tx_power_req(mac_ctx, maxTxPower, session)
|
||||
== eSIR_SUCCESS)
|
||||
== QDF_STATUS_SUCCESS)
|
||||
session->maxTxPower = maxTxPower;
|
||||
}
|
||||
|
||||
|
|
@ -1069,7 +1073,7 @@ sch_beacon_process(tpAniSirGlobal mac_ctx, uint8_t *rx_pkt_info,
|
|||
|
||||
/* 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");
|
||||
return;
|
||||
}
|
||||
|
|
@ -1095,7 +1099,7 @@ sch_beacon_process(tpAniSirGlobal mac_ctx, uint8_t *rx_pkt_info,
|
|||
*
|
||||
* @return status of operation
|
||||
*/
|
||||
tSirRetStatus
|
||||
QDF_STATUS
|
||||
sch_beacon_edca_process(tpAniSirGlobal pMac, tSirMacEdcaParamSetIE *edca,
|
||||
tpPESession session)
|
||||
{
|
||||
|
|
@ -1185,7 +1189,7 @@ sch_beacon_edca_process(tpAniSirGlobal pMac, tSirMacEdcaParamSetIE *edca,
|
|||
session->gLimEdcaParams[i].cw.max,
|
||||
session->gLimEdcaParams[i].txoplimit);
|
||||
}
|
||||
return eSIR_SUCCESS;
|
||||
return QDF_STATUS_SUCCESS;
|
||||
}
|
||||
|
||||
void lim_enable_obss_detection_config(tpAniSirGlobal mac_ctx,
|
||||
|
|
@ -1606,7 +1610,7 @@ QDF_STATUS lim_process_obss_detection_ind(tpAniSirGlobal mac_ctx,
|
|||
sch_set_fixed_beacon_fields(mac_ctx, session);
|
||||
pe_debug("Beacon for PE session: %d got changed: 0x%x",
|
||||
session->smeSessionId, bcn_prm.paramChangeBitmap);
|
||||
if (!IS_SIR_STATUS_SUCCESS(lim_send_beacon_params(
|
||||
if (!QDF_IS_STATUS_SUCCESS(lim_send_beacon_params(
|
||||
mac_ctx, &bcn_prm, session))) {
|
||||
pe_err("Failed to send beacon param, session %d",
|
||||
obss_detection->vdev_id);
|
||||
|
|
|
|||
|
|
@ -37,13 +37,13 @@
|
|||
#define GET_CW(pCw) ((uint16_t) ((*(pCw) << 8) + *((pCw) + 1)))
|
||||
|
||||
/* local functions */
|
||||
static tSirRetStatus get_wmm_local_params(tpAniSirGlobal pMac,
|
||||
uint32_t
|
||||
params[]
|
||||
[WNI_CFG_EDCA_ANI_ACBK_LOCAL_LEN]);
|
||||
static void set_sch_edca_params(tpAniSirGlobal pMac,
|
||||
uint32_t params[][WNI_CFG_EDCA_ANI_ACBK_LOCAL_LEN],
|
||||
tpPESession psessionEntry);
|
||||
static QDF_STATUS
|
||||
get_wmm_local_params(tpAniSirGlobal pMac,
|
||||
uint32_t params[][WNI_CFG_EDCA_ANI_ACBK_LOCAL_LEN]);
|
||||
static void
|
||||
set_sch_edca_params(tpAniSirGlobal pMac,
|
||||
uint32_t params[][WNI_CFG_EDCA_ANI_ACBK_LOCAL_LEN],
|
||||
tpPESession psessionEntry);
|
||||
|
||||
/* -------------------------------------------------------------------- */
|
||||
/**
|
||||
|
|
@ -165,7 +165,7 @@ void sch_process_message(tpAniSirGlobal pMac, struct scheduler_msg *pSchMsg)
|
|||
|
||||
/* get the local or broadcast parameters based on the profile sepcified in the config */
|
||||
/* params are delivered in this order: BK, BE, VI, VO */
|
||||
static tSirRetStatus
|
||||
static QDF_STATUS
|
||||
sch_get_params(tpAniSirGlobal pMac,
|
||||
uint32_t params[][WNI_CFG_EDCA_ANI_ACBK_LOCAL_LEN],
|
||||
uint8_t local)
|
||||
|
|
@ -193,16 +193,16 @@ sch_get_params(tpAniSirGlobal pMac,
|
|||
WNI_CFG_EDCA_ETSI_ACVI, WNI_CFG_EDCA_ETSI_ACVO};
|
||||
|
||||
if (wlan_cfg_get_str(pMac, WNI_CFG_COUNTRY_CODE, country_code_str,
|
||||
&country_code_len) == eSIR_SUCCESS &&
|
||||
&country_code_len) == QDF_STATUS_SUCCESS &&
|
||||
cds_is_etsi_europe_country(country_code_str)) {
|
||||
val = WNI_CFG_EDCA_PROFILE_ETSI_EUROPE;
|
||||
pe_debug("switch to ETSI EUROPE profile country code %c%c",
|
||||
country_code_str[0], country_code_str[1]);
|
||||
} else if (wlan_cfg_get_int(pMac, WNI_CFG_EDCA_PROFILE, &val) !=
|
||||
eSIR_SUCCESS) {
|
||||
QDF_STATUS_SUCCESS) {
|
||||
pe_err("failed to cfg get EDCA_PROFILE id %d",
|
||||
WNI_CFG_EDCA_PROFILE);
|
||||
return eSIR_FAILURE;
|
||||
return QDF_STATUS_E_FAILURE;
|
||||
}
|
||||
|
||||
if (val >= WNI_CFG_EDCA_PROFILE_MAX) {
|
||||
|
|
@ -248,21 +248,21 @@ sch_get_params(tpAniSirGlobal pMac,
|
|||
|
||||
if (wlan_cfg_get_str
|
||||
(pMac, (uint16_t) prf[i], (uint8_t *) &data[0],
|
||||
&len) != eSIR_SUCCESS) {
|
||||
&len) != QDF_STATUS_SUCCESS) {
|
||||
pe_err("cfgGet failed for %d", prf[i]);
|
||||
return eSIR_FAILURE;
|
||||
return QDF_STATUS_E_FAILURE;
|
||||
}
|
||||
if (len > WNI_CFG_EDCA_ANI_ACBK_LOCAL_LEN) {
|
||||
pe_err("cfgGet for %d: length is %d instead of %d",
|
||||
prf[i], len, WNI_CFG_EDCA_ANI_ACBK_LOCAL_LEN);
|
||||
return eSIR_FAILURE;
|
||||
return QDF_STATUS_E_FAILURE;
|
||||
}
|
||||
for (idx = 0; idx < len; idx++)
|
||||
params[i][idx] = (uint32_t) data[idx];
|
||||
}
|
||||
pe_debug("GetParams: local=%d, profile = %d Done", local, val);
|
||||
|
||||
return eSIR_SUCCESS;
|
||||
return QDF_STATUS_SUCCESS;
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
@ -302,8 +302,8 @@ broadcast_wmm_of_concurrent_sta_session(tpAniSirGlobal mac_ctx,
|
|||
return false;
|
||||
|
||||
if (!qdf_mem_cmp(session->gLimEdcaParamsBC,
|
||||
concurrent_session->gLimEdcaParams,
|
||||
sizeof(concurrent_session->gLimEdcaParams)))
|
||||
concurrent_session->gLimEdcaParams,
|
||||
sizeof(concurrent_session->gLimEdcaParams)))
|
||||
return false;
|
||||
|
||||
/*
|
||||
|
|
@ -338,8 +338,9 @@ void sch_qos_update_broadcast(tpAniSirGlobal pMac, tpPESession psessionEntry)
|
|||
uint32_t phyMode;
|
||||
uint8_t i;
|
||||
bool updated = false;
|
||||
QDF_STATUS status;
|
||||
|
||||
if (sch_get_params(pMac, params, false) != eSIR_SUCCESS) {
|
||||
if (sch_get_params(pMac, params, false) != QDF_STATUS_SUCCESS) {
|
||||
pe_debug("QosUpdateBroadcast: failed");
|
||||
return;
|
||||
}
|
||||
|
|
@ -403,13 +404,18 @@ void sch_qos_update_broadcast(tpAniSirGlobal pMac, tpPESession psessionEntry)
|
|||
|
||||
}
|
||||
|
||||
/* If there exists a concurrent STA-AP session, use its WMM params to broadcast in beacons. WFA Wifi Direct test plan 6.1.14 requirement */
|
||||
/*
|
||||
* If there exists a concurrent STA-AP session, use its WMM
|
||||
* params to broadcast in beacons. WFA Wifi Direct test plan
|
||||
* 6.1.14 requirement
|
||||
*/
|
||||
if (broadcast_wmm_of_concurrent_sta_session(pMac, psessionEntry))
|
||||
updated = true;
|
||||
if (updated)
|
||||
psessionEntry->gLimEdcaParamSetCount++;
|
||||
|
||||
if (sch_set_fixed_beacon_fields(pMac, psessionEntry) != eSIR_SUCCESS)
|
||||
status = sch_set_fixed_beacon_fields(pMac, psessionEntry);
|
||||
if (QDF_IS_STATUS_ERROR(status))
|
||||
pe_err("Unable to set beacon fields!");
|
||||
}
|
||||
|
||||
|
|
@ -417,8 +423,10 @@ void sch_qos_update_local(tpAniSirGlobal pMac, tpPESession psessionEntry)
|
|||
{
|
||||
|
||||
uint32_t params[4][WNI_CFG_EDCA_ANI_ACBK_LOCAL_LEN];
|
||||
QDF_STATUS status;
|
||||
|
||||
if (sch_get_params(pMac, params, true /*local */) != eSIR_SUCCESS) {
|
||||
status = sch_get_params(pMac, params, true /*local */);
|
||||
if (QDF_IS_STATUS_ERROR(status)) {
|
||||
pe_err("sch_get_params(local) failed");
|
||||
return;
|
||||
}
|
||||
|
|
@ -441,7 +449,7 @@ void sch_set_default_edca_params(tpAniSirGlobal pMac, tpPESession psessionEntry)
|
|||
{
|
||||
uint32_t params[4][WNI_CFG_EDCA_ANI_ACBK_LOCAL_LEN];
|
||||
|
||||
if (get_wmm_local_params(pMac, params) != eSIR_SUCCESS) {
|
||||
if (get_wmm_local_params(pMac, params) != QDF_STATUS_SUCCESS) {
|
||||
pe_err("get_wmm_local_params() failed");
|
||||
return;
|
||||
}
|
||||
|
|
@ -517,7 +525,7 @@ set_sch_edca_params(tpAniSirGlobal pMac,
|
|||
\param uint32_t params[][WNI_CFG_EDCA_ANI_ACBK_LOCAL_LEN]
|
||||
\return none
|
||||
\ ------------------------------------------------------------ */
|
||||
static tSirRetStatus
|
||||
static QDF_STATUS
|
||||
get_wmm_local_params(tpAniSirGlobal pMac,
|
||||
uint32_t params[][WNI_CFG_EDCA_ANI_ACBK_LOCAL_LEN])
|
||||
{
|
||||
|
|
@ -534,19 +542,19 @@ get_wmm_local_params(tpAniSirGlobal pMac,
|
|||
|
||||
if (wlan_cfg_get_str
|
||||
(pMac, (uint16_t) prf[i], (uint8_t *) &data[0],
|
||||
&len) != eSIR_SUCCESS) {
|
||||
&len) != QDF_STATUS_SUCCESS) {
|
||||
pe_err("cfgGet failed for %d", prf[i]);
|
||||
return eSIR_FAILURE;
|
||||
return QDF_STATUS_E_FAILURE;
|
||||
}
|
||||
if (len > WNI_CFG_EDCA_ANI_ACBK_LOCAL_LEN) {
|
||||
pe_err("cfgGet for %d: length is %d instead of %d",
|
||||
prf[i], len, WNI_CFG_EDCA_ANI_ACBK_LOCAL_LEN);
|
||||
return eSIR_FAILURE;
|
||||
return QDF_STATUS_E_FAILURE;
|
||||
}
|
||||
for (idx = 0; idx < len; idx++)
|
||||
params[i][idx] = (uint32_t) data[idx];
|
||||
}
|
||||
return eSIR_SUCCESS;
|
||||
return QDF_STATUS_SUCCESS;
|
||||
}
|
||||
|
||||
/** ----------------------------------------------------------
|
||||
|
|
|
|||
Loading…
Reference in a new issue