Skip to content

Commit 438efb2

Browse files
Jinjie Ruanbroonie
authored andcommitted
spi: atmel-quadspi: Undo runtime PM changes at driver exit time
It's important to undo pm_runtime_use_autosuspend() with pm_runtime_dont_use_autosuspend() at driver exit time unless driver initially enabled pm_runtime with devm_pm_runtime_enable() (which handles it for you). Hence, call pm_runtime_dont_use_autosuspend() at driver exit time to fix it. Fixes: 4a2f83b ("spi: atmel-quadspi: add runtime pm support") Signed-off-by: Jinjie Ruan <ruanjinjie@huawei.com> Link: https://patch.msgid.link/20240906023956.1004440-1-ruanjinjie@huawei.com Signed-off-by: Mark Brown <broonie@kernel.org>
1 parent 0e58637 commit 438efb2

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

drivers/spi/atmel-quadspi.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -721,6 +721,7 @@ static void atmel_qspi_remove(struct platform_device *pdev)
721721
clk_unprepare(aq->pclk);
722722

723723
pm_runtime_disable(&pdev->dev);
724+
pm_runtime_dont_use_autosuspend(&pdev->dev);
724725
pm_runtime_put_noidle(&pdev->dev);
725726
}
726727

0 commit comments

Comments
 (0)