Skip to content

Commit 2df9d58

Browse files
Jisheng Zhangstorulf
authored andcommitted
mmc: sdhci-of-at91: fix pm runtime unbalanced issue in error path
The device power usage counter is increased by pm_runtime_get_noresume but isn't decreased in err_add_host error path. Fix this issue by calling pm_runtime_put_noidle() in the error path to restore the device's power usage counter. Signed-off-by: Jisheng Zhang <jszhang@marvell.com> Acked-by: Ludovic Desroches <ludovic.desroches@atmel.com> Fixes: f5f1781 ("mmc: sdhci-of-at91: add PM support) Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
1 parent 41c8915 commit 2df9d58

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

drivers/mmc/host/sdhci-of-at91.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -217,6 +217,7 @@ static int sdhci_at91_probe(struct platform_device *pdev)
217217
pm_runtime_disable:
218218
pm_runtime_disable(&pdev->dev);
219219
pm_runtime_set_suspended(&pdev->dev);
220+
pm_runtime_put_noidle(&pdev->dev);
220221
clocks_disable_unprepare:
221222
clk_disable_unprepare(priv->gck);
222223
clk_disable_unprepare(priv->mainck);

0 commit comments

Comments
 (0)