Skip to content

Commit ecd1417

Browse files
jhovoldgregkh
authored andcommitted
spi: imx: fix runtime pm leak on probe deferral
commit a1d50a3 upstream. Make sure to balance the runtime PM usage count before returning on probe failure (e.g. probe deferral) so that the controller can be suspended when a driver is later bound. Fixes: 43b6bf4 ("spi: imx: fix runtime pm support for !CONFIG_PM") Cc: stable@vger.kernel.org # 5.10 Cc: Sascha Hauer <s.hauer@pengutronix.de> Signed-off-by: Johan Hovold <johan@kernel.org> Link: https://patch.msgid.link/20260421125632.1537235-1-johan@kernel.org Signed-off-by: Mark Brown <broonie@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
1 parent a63a704 commit ecd1417

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

drivers/spi/spi-imx.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1876,6 +1876,7 @@ static int spi_imx_probe(struct platform_device *pdev)
18761876
out_runtime_pm_put:
18771877
pm_runtime_dont_use_autosuspend(spi_imx->dev);
18781878
pm_runtime_disable(spi_imx->dev);
1879+
pm_runtime_put_noidle(spi_imx->dev);
18791880
pm_runtime_set_suspended(&pdev->dev);
18801881

18811882
clk_disable_unprepare(spi_imx->clk_ipg);

0 commit comments

Comments
 (0)