qcacld-3.0: Improve suspend/resume logging
Ensure logging messages in the suspend/resume paths use hdd_err() for failure and hdd_info() for success. Also, evaluate existing messages, and polish if appropriate. Change-Id: I8b9509cf631058602ad6e8cd06a013af63624f00 CRs-Fixed: 1070223
This commit is contained in:
@@ -541,8 +541,7 @@ static int __wlan_hdd_bus_suspend(pm_message_t state)
|
|||||||
goto done;
|
goto done;
|
||||||
}
|
}
|
||||||
|
|
||||||
err = qdf_status_to_os_return(
|
err = qdf_status_to_os_return(ol_txrx_bus_suspend());
|
||||||
ol_txrx_bus_suspend());
|
|
||||||
if (err)
|
if (err)
|
||||||
goto done;
|
goto done;
|
||||||
|
|
||||||
@@ -554,8 +553,8 @@ static int __wlan_hdd_bus_suspend(pm_message_t state)
|
|||||||
if (err)
|
if (err)
|
||||||
goto resume_wma;
|
goto resume_wma;
|
||||||
|
|
||||||
hdd_err("suspend done");
|
hdd_info("suspend done");
|
||||||
return err;
|
return 0;
|
||||||
|
|
||||||
resume_wma:
|
resume_wma:
|
||||||
status = wma_bus_resume();
|
status = wma_bus_resume();
|
||||||
@@ -632,14 +631,14 @@ int __wlan_hdd_bus_suspend_noirq(void)
|
|||||||
goto resume_hif_noirq;
|
goto resume_hif_noirq;
|
||||||
|
|
||||||
hdd_info("suspend_noirq done");
|
hdd_info("suspend_noirq done");
|
||||||
return err;
|
return 0;
|
||||||
|
|
||||||
resume_hif_noirq:
|
resume_hif_noirq:
|
||||||
status = hif_bus_resume_noirq(hif_ctx);
|
status = hif_bus_resume_noirq(hif_ctx);
|
||||||
QDF_BUG(!status);
|
QDF_BUG(!status);
|
||||||
done:
|
done:
|
||||||
if (err == -EAGAIN)
|
if (err == -EAGAIN)
|
||||||
hdd_err("firmware not ready for suspend, try again");
|
hdd_err("Firmware attempting wakeup, try again");
|
||||||
else
|
else
|
||||||
hdd_err("suspend_noirq failed, status = %d", err);
|
hdd_err("suspend_noirq failed, status = %d", err);
|
||||||
return err;
|
return err;
|
||||||
@@ -706,7 +705,7 @@ static int __wlan_hdd_bus_resume(void)
|
|||||||
status = ol_txrx_bus_resume();
|
status = ol_txrx_bus_resume();
|
||||||
QDF_BUG(!status);
|
QDF_BUG(!status);
|
||||||
|
|
||||||
hdd_err("resume done");
|
hdd_info("resume done");
|
||||||
return status;
|
return status;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -1285,16 +1285,16 @@ static void hdd_resume_wlan(void)
|
|||||||
hdd_adapter_list_node_t *pAdapterNode = NULL, *pNext = NULL;
|
hdd_adapter_list_node_t *pAdapterNode = NULL, *pNext = NULL;
|
||||||
QDF_STATUS status;
|
QDF_STATUS status;
|
||||||
|
|
||||||
hdd_notice("WLAN being resumed by OS");
|
hdd_info("WLAN being resumed by OS");
|
||||||
|
|
||||||
pHddCtx = cds_get_context(QDF_MODULE_ID_HDD);
|
pHddCtx = cds_get_context(QDF_MODULE_ID_HDD);
|
||||||
if (!pHddCtx) {
|
if (!pHddCtx) {
|
||||||
hdd_alert("HDD context is Null");
|
hdd_err("HDD context is Null");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (cds_is_driver_recovering()) {
|
if (cds_is_driver_recovering()) {
|
||||||
hdd_warn("Recovery in Progress. State: 0x%x Ignore resume!!!",
|
hdd_err("Recovery in Progress. State: 0x%x Ignore resume!!!",
|
||||||
cds_get_driver_state());
|
cds_get_driver_state());
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@@ -1309,7 +1309,7 @@ static void hdd_resume_wlan(void)
|
|||||||
pAdapter = pAdapterNode->pAdapter;
|
pAdapter = pAdapterNode->pAdapter;
|
||||||
|
|
||||||
/* wake the tx queues */
|
/* wake the tx queues */
|
||||||
hdd_notice("Enabling queues");
|
hdd_info("Enabling queues");
|
||||||
wlan_hdd_netif_queue_control(pAdapter,
|
wlan_hdd_netif_queue_control(pAdapter,
|
||||||
WLAN_WAKE_ALL_NETIF_QUEUE,
|
WLAN_WAKE_ALL_NETIF_QUEUE,
|
||||||
WLAN_CONTROL_PATH);
|
WLAN_CONTROL_PATH);
|
||||||
@@ -1698,7 +1698,7 @@ static int __wlan_hdd_cfg80211_resume_wlan(struct wiphy *wiphy)
|
|||||||
pHddCtx->isWiphySuspended = false;
|
pHddCtx->isWiphySuspended = false;
|
||||||
if (true != pHddCtx->isSchedScanUpdatePending) {
|
if (true != pHddCtx->isSchedScanUpdatePending) {
|
||||||
qdf_spin_unlock(&pHddCtx->sched_scan_lock);
|
qdf_spin_unlock(&pHddCtx->sched_scan_lock);
|
||||||
hdd_notice("Return resume is not due to PNO indication");
|
hdd_info("Return resume is not due to PNO indication");
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
/* Reset flag to avoid updatating cfg80211 data old results again */
|
/* Reset flag to avoid updatating cfg80211 data old results again */
|
||||||
@@ -1728,7 +1728,7 @@ static int __wlan_hdd_cfg80211_resume_wlan(struct wiphy *wiphy)
|
|||||||
cfg80211_sched_scan_results(pHddCtx->wiphy);
|
cfg80211_sched_scan_results(pHddCtx->wiphy);
|
||||||
}
|
}
|
||||||
|
|
||||||
hdd_notice("cfg80211 scan result database updated");
|
hdd_info("cfg80211 scan result database updated");
|
||||||
EXIT();
|
EXIT();
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
@@ -1736,7 +1736,6 @@ static int __wlan_hdd_cfg80211_resume_wlan(struct wiphy *wiphy)
|
|||||||
pAdapterNode = pNext;
|
pAdapterNode = pNext;
|
||||||
}
|
}
|
||||||
|
|
||||||
hdd_notice("Failed to find Adapter");
|
|
||||||
EXIT();
|
EXIT();
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
@@ -1831,7 +1830,7 @@ static int __wlan_hdd_cfg80211_suspend_wlan(struct wiphy *wiphy,
|
|||||||
true ==
|
true ==
|
||||||
WLAN_HDD_GET_AP_CTX_PTR(pAdapter)->
|
WLAN_HDD_GET_AP_CTX_PTR(pAdapter)->
|
||||||
dfs_cac_block_tx) {
|
dfs_cac_block_tx) {
|
||||||
hdd_notice("RADAR detection in progress, do not allow suspend");
|
hdd_err("RADAR detection in progress, do not allow suspend");
|
||||||
return -EAGAIN;
|
return -EAGAIN;
|
||||||
} else if (!pHddCtx->config->enableSapSuspend) {
|
} else if (!pHddCtx->config->enableSapSuspend) {
|
||||||
/* return -EOPNOTSUPP if SAP does not support
|
/* return -EOPNOTSUPP if SAP does not support
|
||||||
@@ -1863,7 +1862,7 @@ static int __wlan_hdd_cfg80211_suspend_wlan(struct wiphy *wiphy,
|
|||||||
|
|
||||||
if (sme_sta_in_middle_of_roaming
|
if (sme_sta_in_middle_of_roaming
|
||||||
(pHddCtx->hHal, pAdapter->sessionId)) {
|
(pHddCtx->hHal, pAdapter->sessionId)) {
|
||||||
hdd_notice("Roaming in progress, do not allow suspend");
|
hdd_err("Roaming in progress, do not allow suspend");
|
||||||
return -EAGAIN;
|
return -EAGAIN;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1890,7 +1889,7 @@ static int __wlan_hdd_cfg80211_suspend_wlan(struct wiphy *wiphy,
|
|||||||
* firmware to avoid any race conditions.
|
* firmware to avoid any race conditions.
|
||||||
*/
|
*/
|
||||||
if (hdd_ipa_suspend(pHddCtx)) {
|
if (hdd_ipa_suspend(pHddCtx)) {
|
||||||
hdd_notice("IPA not ready to suspend!");
|
hdd_err("IPA not ready to suspend!");
|
||||||
return -EAGAIN;
|
return -EAGAIN;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -4562,7 +4562,7 @@ QDF_STATUS wma_suspend_req(tp_wma_handle wma, enum qdf_suspend_type type)
|
|||||||
wmi_set_runtime_pm_inprogress(wma->wmi_handle, true);
|
wmi_set_runtime_pm_inprogress(wma->wmi_handle, true);
|
||||||
|
|
||||||
if (wma_is_wow_applicable(wma)) {
|
if (wma_is_wow_applicable(wma)) {
|
||||||
WMA_LOGE("WOW Suspend");
|
WMA_LOGI("WOW Suspend");
|
||||||
wma_apply_lphb(wma);
|
wma_apply_lphb(wma);
|
||||||
|
|
||||||
wma_configure_dynamic_wake_events(wma);
|
wma_configure_dynamic_wake_events(wma);
|
||||||
@@ -6414,7 +6414,7 @@ static int __wma_bus_suspend(enum qdf_suspend_type type)
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (type == QDF_SYSTEM_SUSPEND)
|
if (type == QDF_SYSTEM_SUSPEND)
|
||||||
WMA_LOGE("%s: wow mode selected %d", __func__,
|
WMA_LOGI("%s: wow mode selected %d", __func__,
|
||||||
wma_is_wow_mode_selected(handle));
|
wma_is_wow_mode_selected(handle));
|
||||||
|
|
||||||
if (wma_is_wow_mode_selected(handle)) {
|
if (wma_is_wow_mode_selected(handle)) {
|
||||||
@@ -6469,7 +6469,7 @@ int __wma_bus_resume(WMA_HANDLE handle)
|
|||||||
tp_wma_handle wma = handle;
|
tp_wma_handle wma = handle;
|
||||||
QDF_STATUS status;
|
QDF_STATUS status;
|
||||||
|
|
||||||
WMA_LOGE("%s: wow mode %d", __func__, wow_mode);
|
WMA_LOGI("%s: wow mode %d", __func__, wow_mode);
|
||||||
|
|
||||||
wma->wow_initial_wake_up = false;
|
wma->wow_initial_wake_up = false;
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user