qcacld-3.0: Fix error handling of the vdev destroy timeout
When vdev destroy event timeout, function wait_for_completion_timeout() will return zero. Zero means completion event timeout. But our code uses last status to check timeout or not timeout. SME will not be clean at this case. So, correct code to ensure sme can be clean. Change-Id: I4c0366a9d0f89d374f0e6aa50e0aa32f67fac03e CRs-Fixed: 2705855
This commit is contained in:
parent
1d5015befb
commit
fe30ea50e7
@ -5037,13 +5037,10 @@ int hdd_vdev_destroy(struct hdd_adapter *adapter)
|
||||
rc = wait_for_completion_timeout(
|
||||
&adapter->vdev_destroy_event,
|
||||
msecs_to_jiffies(SME_CMD_VDEV_CREATE_DELETE_TIMEOUT));
|
||||
if (rc) {
|
||||
if (!rc) {
|
||||
hdd_err("timed out waiting for sme vdev delete");
|
||||
clear_bit(SME_SESSION_OPENED, &adapter->event_flags);
|
||||
|
||||
if (status == QDF_STATUS_E_TIMEOUT) {
|
||||
hdd_err("timed out waiting for sme vdev delete");
|
||||
sme_cleanup_session(hdd_ctx->mac_handle, vdev_id);
|
||||
}
|
||||
sme_cleanup_session(hdd_ctx->mac_handle, vdev_id);
|
||||
}
|
||||
|
||||
hdd_nofl_debug("vdev %d destroyed successfully", vdev_id);
|
||||
|
Loading…
Reference in New Issue
Block a user