qcacld-3.0: Fix non-scan active queue stuck issue
1\ The command content is wrongly reset and cause the corresponding command could not find from the active queue. 2\ It should release the command in time before issue the next command. Change-Id: I094a6ce0e34f4698222d85a785cb6424852e25f8 CRs-Fixed: 2144630
This commit is contained in:
@@ -8257,7 +8257,7 @@ QDF_STATUS csr_dequeue_roam_command(tpAniSirGlobal pMac,
|
|||||||
pCommand->u.roamCmd.roamReason);
|
pCommand->u.roamCmd.roamReason);
|
||||||
if (csr_nonscan_active_ll_remove_entry(pMac, pEntry,
|
if (csr_nonscan_active_ll_remove_entry(pMac, pEntry,
|
||||||
LL_ACCESS_LOCK)) {
|
LL_ACCESS_LOCK)) {
|
||||||
csr_release_command_preauth(pMac, pCommand);
|
csr_release_command(pMac, pCommand);
|
||||||
}
|
}
|
||||||
} else if ((eSmeCommandRoam == pCommand->command) &&
|
} else if ((eSmeCommandRoam == pCommand->command) &&
|
||||||
(eCsrSmeIssuedFTReassoc == reason)) {
|
(eCsrSmeIssuedFTReassoc == reason)) {
|
||||||
|
@@ -76,6 +76,7 @@ QDF_STATUS csr_roam_issue_reassociate_cmd(tpAniSirGlobal pMac,
|
|||||||
bool fHighPriority = true;
|
bool fHighPriority = true;
|
||||||
bool fRemoveCmd = false;
|
bool fRemoveCmd = false;
|
||||||
tListElem *pEntry;
|
tListElem *pEntry;
|
||||||
|
tSmeCmd *tmp_command;
|
||||||
|
|
||||||
pEntry = csr_nonscan_active_ll_peek_head(pMac, LL_ACCESS_LOCK);
|
pEntry = csr_nonscan_active_ll_peek_head(pMac, LL_ACCESS_LOCK);
|
||||||
if (pEntry) {
|
if (pEntry) {
|
||||||
@@ -102,6 +103,31 @@ QDF_STATUS csr_roam_issue_reassociate_cmd(tpAniSirGlobal pMac,
|
|||||||
return QDF_STATUS_E_RESOURCES;
|
return QDF_STATUS_E_RESOURCES;
|
||||||
}
|
}
|
||||||
do {
|
do {
|
||||||
|
/*
|
||||||
|
* Get a new sme command to save the necessary info for
|
||||||
|
* the following roaming process, such as BSS list and
|
||||||
|
* roam profile. Or those info will be freed in function
|
||||||
|
* csr_reinit_roam_cmd when releasing the current command.
|
||||||
|
*/
|
||||||
|
tmp_command = csr_get_command_buffer(pMac);
|
||||||
|
if (tmp_command == NULL) {
|
||||||
|
sme_err("fail to get cmd buf!");
|
||||||
|
csr_release_command(pMac, pCommand);
|
||||||
|
return QDF_STATUS_E_RESOURCES;
|
||||||
|
}
|
||||||
|
qdf_mem_copy(tmp_command, pCommand, sizeof(*pCommand));
|
||||||
|
pCommand->u.roamCmd.fReleaseBssList = false;
|
||||||
|
pCommand->u.roamCmd.hBSSList = CSR_INVALID_SCANRESULT_HANDLE;
|
||||||
|
pCommand->u.roamCmd.fReleaseProfile = false;
|
||||||
|
/*
|
||||||
|
* Invoking csr_release_command to release the current command
|
||||||
|
* or the following command will be stuck in pending queue.
|
||||||
|
* Because the API csr_nonscan_active_ll_remove_entry does
|
||||||
|
* not remove the current command from active queue.
|
||||||
|
*/
|
||||||
|
csr_release_command(pMac, pCommand);
|
||||||
|
|
||||||
|
pCommand = tmp_command;
|
||||||
/* Change the substate in case it is wait-for-key */
|
/* Change the substate in case it is wait-for-key */
|
||||||
if (CSR_IS_WAIT_FOR_KEY(pMac, sessionId)) {
|
if (CSR_IS_WAIT_FOR_KEY(pMac, sessionId)) {
|
||||||
csr_roam_stop_wait_for_key_timer(pMac);
|
csr_roam_stop_wait_for_key_timer(pMac);
|
||||||
|
@@ -1033,14 +1033,10 @@ csr_send_chng_mcc_beacon_interval(tpAniSirGlobal pMac, uint32_t sessionId);
|
|||||||
#ifdef WLAN_FEATURE_HOST_ROAM
|
#ifdef WLAN_FEATURE_HOST_ROAM
|
||||||
void csr_roam_ft_pre_auth_rsp_processor(tHalHandle hHal,
|
void csr_roam_ft_pre_auth_rsp_processor(tHalHandle hHal,
|
||||||
tpSirFTPreAuthRsp pFTPreAuthRsp);
|
tpSirFTPreAuthRsp pFTPreAuthRsp);
|
||||||
void csr_release_command_preauth(tpAniSirGlobal mac_ctx, tSmeCmd *command);
|
|
||||||
#else
|
#else
|
||||||
static inline void csr_roam_ft_pre_auth_rsp_processor(tHalHandle hHal,
|
static inline void csr_roam_ft_pre_auth_rsp_processor(tHalHandle hHal,
|
||||||
tpSirFTPreAuthRsp pFTPreAuthRsp)
|
tpSirFTPreAuthRsp pFTPreAuthRsp)
|
||||||
{}
|
{}
|
||||||
static inline void csr_release_command_preauth(tpAniSirGlobal mac_ctx,
|
|
||||||
tSmeCmd *command)
|
|
||||||
{}
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if defined(FEATURE_WLAN_ESE)
|
#if defined(FEATURE_WLAN_ESE)
|
||||||
|
@@ -119,19 +119,6 @@ static void csr_reinit_preauth_cmd(tpAniSirGlobal mac_ctx, tSmeCmd *command)
|
|||||||
qdf_mem_set(&command->u.roamCmd, sizeof(struct roam_cmd), 0);
|
qdf_mem_set(&command->u.roamCmd, sizeof(struct roam_cmd), 0);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
* csr_release_command_preauth() - Release the preauth command
|
|
||||||
* @mac_ctx: Global MAC context
|
|
||||||
* @command: Command to be released
|
|
||||||
*
|
|
||||||
* Return: None
|
|
||||||
*/
|
|
||||||
void csr_release_command_preauth(tpAniSirGlobal mac_ctx, tSmeCmd *command)
|
|
||||||
{
|
|
||||||
csr_reinit_preauth_cmd(mac_ctx, command);
|
|
||||||
csr_release_command(mac_ctx, command);
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* csr_roam_enqueue_preauth() - Put the preauth command in the queue
|
* csr_roam_enqueue_preauth() - Put the preauth command in the queue
|
||||||
* @mac_ctx: Global MAC Context
|
* @mac_ctx: Global MAC Context
|
||||||
@@ -161,10 +148,11 @@ QDF_STATUS csr_roam_enqueue_preauth(tpAniSirGlobal mac_ctx,
|
|||||||
command->u.roamCmd.pLastRoamBss = bss_desc;
|
command->u.roamCmd.pLastRoamBss = bss_desc;
|
||||||
status = csr_queue_sme_command(mac_ctx, command,
|
status = csr_queue_sme_command(mac_ctx, command,
|
||||||
immediate);
|
immediate);
|
||||||
if (!QDF_IS_STATUS_SUCCESS(status))
|
if (!QDF_IS_STATUS_SUCCESS(status)) {
|
||||||
sme_err("fail to queue preauth,status: %d",
|
sme_err("fail to queue preauth,status: %d",
|
||||||
status);
|
status);
|
||||||
csr_reinit_preauth_cmd(mac_ctx, command);
|
csr_reinit_preauth_cmd(mac_ctx, command);
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
status = QDF_STATUS_E_RESOURCES;
|
status = QDF_STATUS_E_RESOURCES;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user