mirror of
https://github.com/rd-stuffs/msm-4.14.git
synced 2025-02-20 11:45:48 +08:00
mhi: controller: qcom: fix unbalance runtime enable counts
A bug in MHI system suspend function caused the function to exit prematurely without disabling runtime suspend. The subsequent runtime resume caused unbalance enable count. CRs-Fixed: 2291885 Change-Id: I9f45a86fff2caf4ba13236677d1325e7093a1947 Signed-off-by: Sujeev Dias <sdias@codeaurora.org>
This commit is contained in:
parent
bdd63def94
commit
a89cab3e3c
@ -257,12 +257,18 @@ static int mhi_system_resume(struct device *dev)
|
||||
int mhi_system_suspend(struct device *dev)
|
||||
{
|
||||
struct mhi_controller *mhi_cntrl = dev_get_drvdata(dev);
|
||||
int ret;
|
||||
|
||||
MHI_LOG("Entered\n");
|
||||
|
||||
/* if rpm status still active then force suspend */
|
||||
if (!pm_runtime_status_suspended(dev))
|
||||
return mhi_runtime_suspend(dev);
|
||||
if (!pm_runtime_status_suspended(dev)) {
|
||||
ret = mhi_runtime_suspend(dev);
|
||||
if (ret) {
|
||||
MHI_LOG("suspend failed ret:%d\n", ret);
|
||||
return ret;
|
||||
}
|
||||
}
|
||||
|
||||
pm_runtime_set_suspended(dev);
|
||||
pm_runtime_disable(dev);
|
||||
|
Loading…
x
Reference in New Issue
Block a user