Commit 3882917d authored by Samuel Holland's avatar Samuel Holland Committed by Ulf Hansson
Browse files

mmc: sunxi-mmc: Ensure host is suspended during system sleep



If the device suspend process begins before the mmc host's autosuspend
timeout, the host will continue running during system sleep. Avoid
this by forcing runtime suspend during a global suspend transition.

Signed-off-by: default avatarSamuel Holland <samuel@sholland.org>
Acked-by: default avatarMaxime Ripard <mripard@kernel.org>
Link: https://lore.kernel.org/r/20210113052421.36553-1-samuel@sholland.org


Signed-off-by: default avatarUlf Hansson <ulf.hansson@linaro.org>
parent 7214d792
Loading
Loading
Loading
Loading
+2 −0
Original line number Original line Diff line number Diff line
@@ -1529,6 +1529,8 @@ static int sunxi_mmc_runtime_suspend(struct device *dev)
#endif
#endif


static const struct dev_pm_ops sunxi_mmc_pm_ops = {
static const struct dev_pm_ops sunxi_mmc_pm_ops = {
	SET_SYSTEM_SLEEP_PM_OPS(pm_runtime_force_suspend,
				pm_runtime_force_resume)
	SET_RUNTIME_PM_OPS(sunxi_mmc_runtime_suspend,
	SET_RUNTIME_PM_OPS(sunxi_mmc_runtime_suspend,
			   sunxi_mmc_runtime_resume,
			   sunxi_mmc_runtime_resume,
			   NULL)
			   NULL)