Skip to content

Commit 7196061

Browse files
tmlindvinodkoul
authored andcommitted
phy: mapphone-mdm6600: Fix runtime disable on probe
Commit d644e0d ("phy: mapphone-mdm6600: Fix PM error handling in phy_mdm6600_probe") caused a regression where we now unconditionally disable runtime PM at the end of the probe while it is only needed on errors. Cc: Ivaylo Dimitrov <ivo.g.dimitrov.75@gmail.com> Cc: Merlijn Wajer <merlijn@wizzup.org> Cc: Miaoqian Lin <linmq006@gmail.com> Cc: Pavel Machek <pavel@ucw.cz> Reviewed-by: Sebastian Reichel <sebastian.reichel@collabora.com> Fixes: d644e0d ("phy: mapphone-mdm6600: Fix PM error handling in phy_mdm6600_probe") Signed-off-by: Tony Lindgren <tony@atomide.com> Link: https://lore.kernel.org/r/20230913060433.48373-1-tony@atomide.com Signed-off-by: Vinod Koul <vkoul@kernel.org>
1 parent 0bb80ec commit 7196061

1 file changed

Lines changed: 5 additions & 3 deletions

File tree

drivers/phy/motorola/phy-mapphone-mdm6600.c

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -627,10 +627,12 @@ static int phy_mdm6600_probe(struct platform_device *pdev)
627627
pm_runtime_put_autosuspend(ddata->dev);
628628

629629
cleanup:
630-
if (error < 0)
630+
if (error < 0) {
631631
phy_mdm6600_device_power_off(ddata);
632-
pm_runtime_disable(ddata->dev);
633-
pm_runtime_dont_use_autosuspend(ddata->dev);
632+
pm_runtime_disable(ddata->dev);
633+
pm_runtime_dont_use_autosuspend(ddata->dev);
634+
}
635+
634636
return error;
635637
}
636638

0 commit comments

Comments
 (0)