qcacld-3.0: Remove e_sme_delete_sta_session from active command list

The command e_sme_delete_sta_session command is serialized and
is not removed from the active command list in the response path
at csr_process_del_sta_session_rsp().

Remove the command e_sme_delete_sta_session from active command
list in csr_process_del_sta_session_rsp

Change-Id: Iff36460055bd73705575110d88c3eb75c8052afa
CRs-Fixed: 2292607
This commit is contained in:
Pragaspathi Thilagaraj 2018-08-08 14:02:35 +05:30 • committed by nshrivas
commit ad7a5f5b3c

View file

@ -17506,28 +17506,44 @@ QDF_STATUS csr_roam_open_session(tpAniSirGlobal mac_ctx,
session_param->subtype_of_persona);
}
QDF_STATUS csr_process_del_sta_session_rsp(tpAniSirGlobal pMac, uint8_t *pMsg)
QDF_STATUS csr_process_del_sta_session_rsp(tpAniSirGlobal mac_ctx,
uint8_t *pMsg)
{
QDF_STATUS status = QDF_STATUS_E_FAILURE;
struct del_sta_self_params *rsp;
uint8_t sessionId;
tListElem *entry;
tSmeCmd *sme_command;
if (pMsg == NULL) {
sme_err("msg ptr is NULL");
return status;
}
entry = csr_nonscan_active_ll_peek_head(mac_ctx, LL_ACCESS_LOCK);
if (!entry) {
sme_err("NO commands are ACTIVE");
return status;
}
sme_command = GET_BASE_ADDR(entry, tSmeCmd, Link);
if (e_sme_command_del_sta_session != sme_command->command) {
sme_err("No Del sta session command ACTIVE");
return status;
}
rsp = (struct del_sta_self_params *) pMsg;
sessionId = rsp->session_id;
sme_debug("Del Sta rsp status = %d", rsp->status);
/* This session is done. */
csr_cleanup_session(pMac, sessionId);
csr_cleanup_session(mac_ctx, sessionId);
if (rsp->sme_callback) {
status = sme_release_global_lock(&pMac->sme);
status = sme_release_global_lock(&mac_ctx->sme);
if (!QDF_IS_STATUS_SUCCESS(status))
sme_debug("Failed to Release Lock");
else {
rsp->sme_callback(rsp->session_id);
status = sme_acquire_global_lock(&pMac->sme);
status = sme_acquire_global_lock(&mac_ctx->sme);
if (!QDF_IS_STATUS_SUCCESS(status)) {
sme_debug("Failed to get Lock");
return status;
@ -17535,6 +17551,12 @@ QDF_STATUS csr_process_del_sta_session_rsp(tpAniSirGlobal pMac, uint8_t *pMsg)
}
}
/* Remove this command out of the non scan active list */
if (csr_nonscan_active_ll_remove_entry(mac_ctx, entry,
LL_ACCESS_LOCK)) {
csr_release_command(mac_ctx, sme_command);
}
return QDF_STATUS_SUCCESS;
}