qcacld-3.0: Replace tSirMacAddr with cdf_mac_addr in tSirSmeDisassocRsp

Replace tSirMacAddr with cdf_mac_addr in tSirSmeDisassocRsp.

Change-Id: Ia196615e99506b4fa80a7d611cdefd2e7d2150fa
CRs-Fixed: 898864
This commit is contained in:
Srinivas Girigowda
2016-01-05 19:41:27 -08:00
committed by Akash Patel
parent 70a196142e
commit f06a5cf8c8
7 changed files with 39 additions and 41 deletions

View File

@@ -1377,7 +1377,7 @@ typedef struct sSirSmeDisassocRsp {
uint8_t sessionId; /* Session ID */
uint16_t transactionId; /* Transaction ID for cmd */
tSirResultCodes statusCode;
tSirMacAddr peerMacAddr;
struct cdf_mac_addr peer_macaddr;
tAniStaStatStruct perStaStats; /* STA stats */
uint16_t staId;
} cdf_packed tSirSmeDisassocRsp, *tpSirSmeDisassocRsp;

View File

@@ -508,16 +508,14 @@ lim_process_auth_frame(tpAniSirGlobal pMac, uint8_t *pRxPacketInfo,
&&
(cdf_mem_compare
((uint8_t *) pHdr->sa,
(uint8_t *) &pMlmDisassocReq->peerMacAddr,
sizeof(tSirMacAddr)))) {
&pMlmDisassocReq->peer_macaddr.bytes,
CDF_MAC_ADDR_SIZE))) {
PELOGE(lim_log
(pMac, LOGE,
FL("TODO:Ack for disassoc "
"frame is pending Issue delsta for "
FL("TODO:Ack for disassoc frame is pending Issue delsta for "
MAC_ADDRESS_STR),
MAC_ADDR_ARRAY(pMlmDisassocReq->
peerMacAddr));
)
peer_macaddr.bytes));)
lim_process_disassoc_ack_timeout(pMac);
isConnected = eSIR_FALSE;
}

View File

@@ -1584,7 +1584,7 @@ lim_process_mlm_disassoc_req_ntf(tpAniSirGlobal mac_ctx,
CDF_STATUS suspend_status, uint32_t *msg)
{
uint16_t aid;
tSirMacAddr curr_bssid;
struct cdf_mac_addr curr_bssid;
tpDphHashNode stads;
tLimMlmDisassocReq *mlm_disassocreq;
tLimMlmDisassocCnf mlm_disassoccnf;
@@ -1614,19 +1614,19 @@ lim_process_mlm_disassoc_req_ntf(tpAniSirGlobal mac_ctx,
"mlmstate %d from: " MAC_ADDRESS_STR),
mlm_disassocreq->sessionId, GET_LIM_SYSTEM_ROLE(session),
session->limMlmState,
MAC_ADDR_ARRAY(mlm_disassocreq->peerMacAddr));
MAC_ADDR_ARRAY(mlm_disassocreq->peer_macaddr.bytes));
sir_copy_mac_addr(curr_bssid, session->bssId);
cdf_mem_copy(curr_bssid.bytes, session->bssId, CDF_MAC_ADDR_SIZE);
switch (GET_LIM_SYSTEM_ROLE(session)) {
case eLIM_STA_ROLE:
case eLIM_BT_AMP_STA_ROLE:
if (!cdf_mem_compare(mlm_disassocreq->peerMacAddr,
curr_bssid, sizeof(tSirMacAddr))) {
if (!cdf_is_macaddr_equal(&mlm_disassocreq->peer_macaddr,
&curr_bssid)) {
lim_log(mac_ctx, LOGW,
FL("received MLM_DISASSOC_REQ with invalid BSS id"));
lim_print_mac_addr(mac_ctx,
mlm_disassocreq->peerMacAddr, LOGW);
mlm_disassocreq->peer_macaddr.bytes, LOGW);
/*
* Disassociation response due to host triggered
@@ -1643,7 +1643,8 @@ lim_process_mlm_disassoc_req_ntf(tpAniSirGlobal mac_ctx,
lim_log(mac_ctx, LOG1,
FL("send disassoc rsp with ret code %d for" MAC_ADDRESS_STR),
eSIR_SME_DEAUTH_STATUS,
MAC_ADDR_ARRAY(mlm_disassocreq->peerMacAddr));
MAC_ADDR_ARRAY(
mlm_disassocreq->peer_macaddr.bytes));
sme_disassoc_rsp->messageType = eWNI_SME_DISASSOC_RSP;
sme_disassoc_rsp->length = sizeof(tSirSmeDisassocRsp);
@@ -1652,9 +1653,8 @@ lim_process_mlm_disassoc_req_ntf(tpAniSirGlobal mac_ctx,
sme_disassoc_rsp->transactionId = 0;
sme_disassoc_rsp->statusCode = eSIR_SME_DEAUTH_STATUS;
cdf_mem_copy(sme_disassoc_rsp->peerMacAddr,
mlm_disassocreq->peerMacAddr,
sizeof(tSirMacAddr));
cdf_copy_macaddr(&sme_disassoc_rsp->peer_macaddr,
&mlm_disassocreq->peer_macaddr);
msg = (uint32_t *)sme_disassoc_rsp;
lim_send_sme_disassoc_deauth_ntf(mac_ctx,
@@ -1683,7 +1683,8 @@ lim_process_mlm_disassoc_req_ntf(tpAniSirGlobal mac_ctx,
* Check if there exists a context for the peer entity
* to be disassociated with.
*/
stads = dph_lookup_hash_entry(mac_ctx, mlm_disassocreq->peerMacAddr,
stads = dph_lookup_hash_entry(mac_ctx,
mlm_disassocreq->peer_macaddr.bytes,
&aid, &session->dph.dphHashTable);
if (stads)
mlm_state = stads->mlmStaContext.mlmState;
@@ -1699,7 +1700,7 @@ lim_process_mlm_disassoc_req_ntf(tpAniSirGlobal mac_ctx,
*/
lim_log(mac_ctx, LOGW,
FL("Invalid MLM_DISASSOC_REQ, Addr= " MAC_ADDRESS_STR),
MAC_ADDR_ARRAY(mlm_disassocreq->peerMacAddr));
MAC_ADDR_ARRAY(mlm_disassocreq->peer_macaddr.bytes));
if (stads != NULL)
lim_log(mac_ctx, LOGE, FL("Sta MlmState : %d"),
stads->mlmStaContext.mlmState);
@@ -1735,7 +1736,7 @@ lim_process_mlm_disassoc_req_ntf(tpAniSirGlobal mac_ctx,
lim_send_disassoc_mgmt_frame(mac_ctx,
mlm_disassocreq->reasonCode,
mlm_disassocreq->peerMacAddr, session, true);
mlm_disassocreq->peer_macaddr.bytes, session, true);
/*
* Abort Tx so that data frames won't be sent to the AP
* after sending Disassoc.
@@ -1760,8 +1761,8 @@ lim_process_mlm_disassoc_req_ntf(tpAniSirGlobal mac_ctx,
end:
cdf_mem_copy((uint8_t *) &mlm_disassoccnf.peerMacAddr,
(uint8_t *) mlm_disassocreq->peerMacAddr,
sizeof(tSirMacAddr));
(uint8_t *) mlm_disassocreq->peer_macaddr.bytes,
CDF_MAC_ADDR_SIZE);
mlm_disassoccnf.aid = mlm_disassocreq->aid;
mlm_disassoccnf.disassocTrigger = mlm_disassocreq->disassocTrigger;
@@ -1795,8 +1796,8 @@ bool lim_check_disassoc_deauth_ack_pending(tpAniSirGlobal mac_ctx,
disassoc_req = mac_ctx->lim.limDisassocDeauthCnfReq.pMlmDisassocReq;
deauth_req = mac_ctx->lim.limDisassocDeauthCnfReq.pMlmDeauthReq;
if ((disassoc_req && (cdf_mem_compare((uint8_t *) sta_mac,
(uint8_t *) &disassoc_req->peerMacAddr,
sizeof(tSirMacAddr)))) ||
(uint8_t *) &disassoc_req->peer_macaddr.bytes,
CDF_MAC_ADDR_SIZE))) ||
(deauth_req && (cdf_mem_compare((uint8_t *) sta_mac,
(uint8_t *) &deauth_req->peer_macaddr.bytes,
CDF_MAC_ADDR_SIZE)))) {
@@ -1829,8 +1830,8 @@ void lim_clean_up_disassoc_deauth_req(tpAniSirGlobal mac_ctx,
mlm_disassoc_req = mac_ctx->lim.limDisassocDeauthCnfReq.pMlmDisassocReq;
if (mlm_disassoc_req &&
(cdf_mem_compare((uint8_t *) sta_mac,
(uint8_t *) &mlm_disassoc_req->peerMacAddr,
sizeof(tSirMacAddr)))) {
(uint8_t *) &mlm_disassoc_req->peer_macaddr.bytes,
CDF_MAC_ADDR_SIZE))) {
if (clean_rx_path) {
lim_process_disassoc_ack_timeout(mac_ctx);
} else {
@@ -1907,7 +1908,7 @@ lim_process_mlm_disassoc_req(tpAniSirGlobal mac_ctx, uint32_t *msg_buf)
lim_log(mac_ctx, LOG1,
FL("Process disassoc req, sessionID %d from: "MAC_ADDRESS_STR),
mlm_disassoc_req->sessionId,
MAC_ADDR_ARRAY(mlm_disassoc_req->peerMacAddr));
MAC_ADDR_ARRAY(mlm_disassoc_req->peer_macaddr.bytes));
lim_process_mlm_disassoc_req_ntf(mac_ctx, CDF_STATUS_SUCCESS,
(uint32_t *) msg_buf);

View File

@@ -2549,7 +2549,7 @@ static void __lim_process_sme_disassoc_req(tpAniSirGlobal pMac, uint32_t *pMsgBu
return;
}
cdf_mem_copy((uint8_t *) &pMlmDisassocReq->peerMacAddr,
cdf_mem_copy((uint8_t *) &pMlmDisassocReq->peer_macaddr,
(uint8_t *) &smeDisassocReq.peerMacAddr,
sizeof(tSirMacAddr));

View File

@@ -3186,7 +3186,7 @@ CDF_STATUS lim_send_disassoc_cnf(tpAniSirGlobal mac_ctx)
}
sta_ds = dph_lookup_hash_entry(mac_ctx,
disassoc_req->peerMacAddr, &aid,
disassoc_req->peer_macaddr.bytes, &aid,
&pe_session->dph.dphHashTable);
if (sta_ds == NULL) {
lim_log(mac_ctx, LOGE, FL("StaDs Null"));
@@ -3250,8 +3250,8 @@ CDF_STATUS lim_send_disassoc_cnf(tpAniSirGlobal mac_ctx)
}
end:
cdf_mem_copy((uint8_t *) &disassoc_cnf.peerMacAddr,
(uint8_t *) disassoc_req->peerMacAddr,
sizeof(tSirMacAddr));
(uint8_t *) disassoc_req->peer_macaddr.bytes,
CDF_MAC_ADDR_SIZE);
disassoc_cnf.aid = disassoc_req->aid;
disassoc_cnf.disassocTrigger = disassoc_req->disassocTrigger;

View File

@@ -1,5 +1,5 @@
/*
* Copyright (c) 2012-2015 The Linux Foundation. All rights reserved.
* Copyright (c) 2012-2016 The Linux Foundation. All rights reserved.
*
* Previously licensed under the ISC license by Qualcomm Atheros, Inc.
*
@@ -333,7 +333,7 @@ typedef struct sLimMlmDeauthInd {
} tLimMlmDeauthInd, *tpLimMlmDeauthInd;
typedef struct sLimMlmDisassocReq {
tSirMacAddr peerMacAddr;
struct cdf_mac_addr peer_macaddr;
uint16_t reasonCode;
uint16_t disassocTrigger;
uint16_t aid;

View File

@@ -10335,9 +10335,8 @@ csr_roam_chk_lnk_disassoc_rsp(tpAniSirGlobal mac_ctx, tSirSmeRsp *msg_ptr)
if (CSR_IS_INFRA_AP(&session->connectedProfile)) {
roam_info_ptr = &roam_info;
roam_info_ptr->u.pConnectedProfile = &session->connectedProfile;
cdf_mem_copy(roam_info_ptr->peerMac.bytes,
pDisassocRsp->peerMacAddr,
sizeof(tSirMacAddr));
cdf_copy_macaddr(&roam_info_ptr->peerMac,
&pDisassocRsp->peer_macaddr);
roam_info_ptr->reasonCode = eCSR_ROAM_RESULT_FORCED;
roam_info_ptr->statusCode = pDisassocRsp->statusCode;
status = csr_roam_call_callback(mac_ctx, sessionId,
@@ -17885,7 +17884,7 @@ static void csr_ser_des_unpack_diassoc_rsp(uint8_t *pBuf, tSirSmeDisassocRsp *pR
pBuf += 2;
cdf_get_u32(pBuf, (uint32_t *) &pRsp->statusCode);
pBuf += 4;
cdf_mem_copy(pRsp->peerMacAddr, pBuf, 6);
cdf_mem_copy(pRsp->peer_macaddr.bytes, pBuf, CDF_MAC_ADDR_SIZE);
}
}