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

Commit 55805884 authored by Linux Build Service Account's avatar Linux Build Service Account Committed by Gerrit - the friendly Code Review server
Browse files

Merge "USB: phy-msm: Enable core/async irq only for host/device bus suspend"

parents afb688ee 32d2a1d5
Loading
Loading
Loading
Loading
+11 −6
Original line number Diff line number Diff line
@@ -1638,12 +1638,14 @@ static int msm_otg_suspend(struct msm_otg *motg)

	atomic_set(&motg->in_lpm, 1);

	if (host_bus_suspend || device_bus_suspend) {
		/* Enable ASYNC IRQ during LPM */
		enable_irq(motg->async_irq);
		enable_irq(motg->irq);
	}
	if (motg->phy_irq)
		enable_irq(motg->phy_irq);

	enable_irq(motg->irq);
	pm_relax(&motg->pdev->dev);

	dev_dbg(phy->dev, "LPM caps = %lu flags = %lu\n",
@@ -1688,10 +1690,12 @@ static int msm_otg_resume(struct msm_otg *motg)
		return 0;
	}

	disable_irq(motg->irq);
	pm_stay_awake(&motg->pdev->dev);
	if (motg->phy_irq)
		disable_irq(motg->phy_irq);
	pm_stay_awake(&motg->pdev->dev);

	if (motg->host_bus_suspend || motg->device_bus_suspend)
		disable_irq(motg->irq);

	/*
	 * If we are resuming from the device bus suspend, restore
@@ -1814,6 +1818,7 @@ static int msm_otg_resume(struct msm_otg *motg)
	enable_irq(motg->irq);

	/* Enable ASYNC_IRQ only during LPM */
	if (motg->host_bus_suspend || motg->device_bus_suspend)
		disable_irq(motg->async_irq);

	if (motg->phy_irq_pending) {