Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 7609d9e2 authored by Sujeev Dias's avatar Sujeev Dias Committed by Gerrit - the friendly Code Review server
Browse files

mhi: cntrl: qcom: temporarily disable MHI suspend



Reject all suspends temporarily until all dependent changes to
support suspend is available on builds.

CRs-Fixed: 2418347
Change-Id: I06a219353ea30d672f2c50441534fe8f2737c7a5
Signed-off-by: default avatarSujeev Dias <sdias@codeaurora.org>
parent 2000f19d
Loading
Loading
Loading
Loading
+1 −29
Original line number Diff line number Diff line
@@ -195,35 +195,7 @@ static int mhi_init_pci_dev(struct mhi_controller *mhi_cntrl)

static int mhi_runtime_suspend(struct device *dev)
{
	int ret = 0;
	struct mhi_controller *mhi_cntrl = dev_get_drvdata(dev);
	struct mhi_dev *mhi_dev = mhi_controller_get_devdata(mhi_cntrl);

	MHI_LOG("Enter\n");

	mutex_lock(&mhi_cntrl->pm_mutex);

	if (!mhi_dev->powered_on) {
		MHI_LOG("Not fully powered, return success\n");
		mutex_unlock(&mhi_cntrl->pm_mutex);
		return 0;
	}

	ret = mhi_pm_suspend(mhi_cntrl);
	if (ret) {
		MHI_LOG("Abort due to ret:%d\n", ret);
		goto exit_runtime_suspend;
	}

	ret = mhi_arch_link_off(mhi_cntrl, true);
	if (ret)
		MHI_ERR("Failed to Turn off link ret:%d\n", ret);

exit_runtime_suspend:
	mutex_unlock(&mhi_cntrl->pm_mutex);
	MHI_LOG("Exited with ret:%d\n", ret);

	return ret;
	return -EBUSY;
}

static int mhi_runtime_idle(struct device *dev)