mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-15 01:01:56 -04:00
qcacld-3.0: Do not send DEL BSS to FW if ADD BSS fails
qcacld-2.0 to qcacld-3.0 propagation Even though ADD_BSS fails the driver tries to send DEL BSS to firmware which will crash upon receiving DEL BSS. To avoid this crash do not send DEL BSS to Firmware if ADD BSS fails and just do cleanup. Change-Id: Ieabf241c8277ae76bb5f491f9d8a2b783d8ea47e CRs-Fixed: 929249
This commit is contained in:
parent
52249826fc
commit
1ae6563822
3 changed files with 28 additions and 8 deletions
|
|
@ -483,6 +483,7 @@ typedef struct sPESession /* Added to Support BT-AMP */
|
|||
/* flag to indicate country code in beacon */
|
||||
uint8_t country_info_present;
|
||||
uint8_t nss;
|
||||
bool add_bss_failed;
|
||||
} tPESession, *tpPESession;
|
||||
|
||||
/*-------------------------------------------------------------------------
|
||||
|
|
|
|||
|
|
@ -671,13 +671,16 @@ lim_cleanup_rx_path(tpAniSirGlobal pMac, tpDphHashNode pStaDs,
|
|||
/* increment a debug count */
|
||||
pMac->lim.gLimNumRxCleanup++;
|
||||
#endif
|
||||
|
||||
if (psessionEntry->limSmeState == eLIM_SME_JOIN_FAILURE_STATE) {
|
||||
retCode =
|
||||
lim_del_bss(pMac, pStaDs, psessionEntry->bssIdx,
|
||||
psessionEntry);
|
||||
} else
|
||||
retCode = lim_del_sta(pMac, pStaDs, true, psessionEntry);
|
||||
/* Do DEL BSS or DEL STA only if ADD BSS was success */
|
||||
if (!psessionEntry->add_bss_failed) {
|
||||
if (psessionEntry->limSmeState == eLIM_SME_JOIN_FAILURE_STATE) {
|
||||
retCode =
|
||||
lim_del_bss(pMac, pStaDs, psessionEntry->bssIdx,
|
||||
psessionEntry);
|
||||
} else
|
||||
retCode = lim_del_sta(pMac,
|
||||
pStaDs, true, psessionEntry);
|
||||
}
|
||||
|
||||
return retCode;
|
||||
|
||||
|
|
|
|||
|
|
@ -1546,12 +1546,19 @@ lim_handle_sme_join_result(tpAniSirGlobal mac_ctx,
|
|||
* to SME
|
||||
*/
|
||||
lim_cleanup_rx_path(mac_ctx, sta_ds, session_entry);
|
||||
/* Cleanup if add bss failed */
|
||||
if (session_entry->add_bss_failed) {
|
||||
dph_delete_hash_entry(mac_ctx,
|
||||
sta_ds->staAddr, sta_ds->assocId,
|
||||
&session_entry->dph.dphHashTable);
|
||||
goto error;
|
||||
}
|
||||
cdf_mem_free(session_entry->pLimJoinReq);
|
||||
session_entry->pLimJoinReq = NULL;
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
error:
|
||||
cdf_mem_free(session_entry->pLimJoinReq);
|
||||
session_entry->pLimJoinReq = NULL;
|
||||
/* Delete teh session if JOIN failure occurred. */
|
||||
|
|
@ -1624,9 +1631,17 @@ lim_handle_sme_reaasoc_result(tpAniSirGlobal pMac, tSirResultCodes resultCode,
|
|||
pStaDs->mlmStaContext.resultCode = resultCode;
|
||||
pStaDs->mlmStaContext.protStatusCode = protStatusCode;
|
||||
lim_cleanup_rx_path(pMac, pStaDs, psessionEntry);
|
||||
/* Cleanup if add bss failed */
|
||||
if (psessionEntry->add_bss_failed) {
|
||||
dph_delete_hash_entry(pMac,
|
||||
pStaDs->staAddr, pStaDs->assocId,
|
||||
&psessionEntry->dph.dphHashTable);
|
||||
goto error;
|
||||
}
|
||||
return;
|
||||
}
|
||||
}
|
||||
error:
|
||||
/* Delete teh session if REASSOC failure occurred. */
|
||||
if (resultCode != eSIR_SME_SUCCESS) {
|
||||
if (NULL != psessionEntry) {
|
||||
|
|
@ -3056,6 +3071,7 @@ lim_process_sta_mlm_add_bss_rsp(tpAniSirGlobal mac_ctx,
|
|||
else
|
||||
mlm_assoc_cnf.resultCode =
|
||||
(tSirResultCodes) eSIR_SME_REFUSED;
|
||||
session_entry->add_bss_failed = true;
|
||||
}
|
||||
|
||||
if (mlm_assoc_cnf.resultCode != eSIR_SME_SUCCESS) {
|
||||
|
|
|
|||
Loading…
Reference in a new issue