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

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

Merge "spi: spi_qsd: Prevent deadlock while runtime pm is disabled"

parents 4c891b95 10ae2ac0
Loading
Loading
Loading
Loading
+7 −5
Original line number Diff line number Diff line
@@ -1816,14 +1816,16 @@ static int msm_spi_setup(struct spi_device *spi)
	mb();
	if (dd->pdata->is_shared)
		put_local_resources(dd);
	/* Counter-part of system-resume when runtime-pm is not enabled. */
	if (!pm_runtime_enabled(dd->dev))
		msm_spi_pm_suspend_runtime(dd->dev);

no_resources:
	mutex_unlock(&dd->core_lock);
	/* Counter-part of system-resume when runtime-pm is not enabled. */
	if (!pm_runtime_enabled(dd->dev)) {
		msm_spi_pm_suspend_runtime(dd->dev);
	} else {
		pm_runtime_mark_last_busy(dd->dev);
		pm_runtime_put_autosuspend(dd->dev);
	}

err_setup_exit:
	return rc;