mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-11 23:24:22 -04:00
qcacld-3.0: Fill wma req before pdev_set_dual_mac cmd sent to fw
Presently host prepares and fills wma req in wma_hold_req_queue after sending pdev_set_dual_mac command to FW. Host uses same wma request to process response from firmware. If host gets FW response before filling wma request to wma_hold_req_queue, host fails to process pdev_set_dual_mac cmd response. And thus the wma request queued after sending pdev_set_dual_mac command gets timeout. Hence prepare and fill wma req in wma_hold_req_queue before sending pdev_set_dual_mac command to firmware. Problem scenario: 1) Host send pdev_set_dual_mac cmd to fw in kworker thread and then gets suspend before filling wma req into wma_hold_req_queue. 2) Host gets pdev_set_dual_mac cmd response from fw and schedular thread runs to process response where it doesn't get wma request. 3) Now kworker thread gets scheduled and fill wma req and gets timed out. Change-Id: I4d32e4459c32843c8fdb9a48262b5a55eecf2cbd CRs-Fixed: 2902212
This commit is contained in:
parent
5821833f15
commit
95b20719d9
1 changed files with 11 additions and 10 deletions
|
|
@ -9303,6 +9303,15 @@ QDF_STATUS wma_send_pdev_set_dual_mac_config(tp_wma_handle wma_handle,
|
|||
return QDF_STATUS_E_NULL_VALUE;
|
||||
}
|
||||
|
||||
req_msg = wma_fill_hold_req(wma_handle, 0,
|
||||
SIR_HAL_PDEV_DUAL_MAC_CFG_REQ,
|
||||
WMA_PDEV_MAC_CFG_RESP, NULL,
|
||||
WMA_VDEV_DUAL_MAC_CFG_TIMEOUT);
|
||||
if (!req_msg) {
|
||||
wma_err("Failed to allocate request for SIR_HAL_PDEV_DUAL_MAC_CFG_REQ");
|
||||
return QDF_STATUS_E_FAILURE;
|
||||
}
|
||||
|
||||
/*
|
||||
* aquire the wake lock here and release it in response handler function
|
||||
* In error condition, release the wake lock right away
|
||||
|
|
@ -9316,20 +9325,12 @@ QDF_STATUS wma_send_pdev_set_dual_mac_config(tp_wma_handle wma_handle,
|
|||
wma_err("Failed to send WMI_PDEV_SET_DUAL_MAC_CONFIG_CMDID: %d",
|
||||
status);
|
||||
wma_release_wakelock(&wma_handle->wmi_cmd_rsp_wake_lock);
|
||||
wma_remove_req(wma_handle, 0, WMA_PDEV_MAC_CFG_RESP);
|
||||
goto fail;
|
||||
}
|
||||
policy_mgr_update_dbs_req_config(wma_handle->psoc,
|
||||
msg->scan_config, msg->fw_mode_config);
|
||||
|
||||
req_msg = wma_fill_hold_req(wma_handle, 0,
|
||||
SIR_HAL_PDEV_DUAL_MAC_CFG_REQ,
|
||||
WMA_PDEV_MAC_CFG_RESP, NULL,
|
||||
WMA_VDEV_DUAL_MAC_CFG_TIMEOUT);
|
||||
if (!req_msg) {
|
||||
wma_err("Failed to allocate request for SIR_HAL_PDEV_DUAL_MAC_CFG_REQ");
|
||||
wma_remove_req(wma_handle, 0, WMA_PDEV_MAC_CFG_RESP);
|
||||
}
|
||||
|
||||
return QDF_STATUS_SUCCESS;
|
||||
|
||||
fail:
|
||||
|
|
@ -9340,8 +9341,8 @@ fail:
|
|||
resp->status = SET_HW_MODE_STATUS_ECANCELED;
|
||||
wma_debug("Sending failure response to LIM");
|
||||
wma_send_msg(wma_handle, SIR_HAL_PDEV_MAC_CFG_RESP, (void *) resp, 0);
|
||||
return QDF_STATUS_E_FAILURE;
|
||||
|
||||
return QDF_STATUS_E_FAILURE;
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
Loading…
Reference in a new issue