* [PATCH] drm/bridge: ti-sn65dsi86: fail PWM probe if runtime PM setup fails
@ 2026-11-29 13:43 Jiawen Liu
0 siblings, 0 replies; only message in thread
From: Jiawen Liu @ 2026-11-29 13:43 UTC (permalink / raw)
To: Andrzej Hajda, Neil Armstrong, Robert Foss, Maarten Lankhorst,
Maxime Ripard, Thomas Zimmermann, David Airlie, Simona Vetter
Cc: Douglas Anderson, Laurent Pinchart, Jonas Karlman,
Jernej Skrabec, Luca Ceresoli, dri-devel, linux-kernel
ti_sn_pwm_probe() ignored a failure from devm_pm_runtime_enable(). The
helper rolls runtime PM back when action registration fails, but the
probe could then successfully register the PWM chip. A later PWM apply
operation would be unable to resume the auxiliary device.
Propagate the runtime PM setup error before registering the PWM chip.
Fixes: eb3f7cbee294 ("drm/bridge: ti-sn65dsi86: Associate PWM device to auxiliary device")
Signed-off-by: Jiawen Liu <1298662399@qq.com>
---
drivers/gpu/drm/bridge/ti-sn65dsi86.c | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/bridge/ti-sn65dsi86.c b/drivers/gpu/drm/bridge/ti-sn65dsi86.c
index 48b83df9aed61..bbf9491059375 100644
--- a/drivers/gpu/drm/bridge/ti-sn65dsi86.c
+++ b/drivers/gpu/drm/bridge/ti-sn65dsi86.c
@@ -1721,6 +1721,7 @@ static int ti_sn_pwm_probe(struct auxiliary_device *adev,
{
struct pwm_chip *chip;
struct ti_sn65dsi86 *pdata = dev_get_drvdata(adev->dev.parent);
+ int ret;
pdata->pchip = chip = devm_pwmchip_alloc(&adev->dev, 1, 0);
if (IS_ERR(chip))
@@ -1731,7 +1732,9 @@ static int ti_sn_pwm_probe(struct auxiliary_device *adev,
chip->ops = &ti_sn_pwm_ops;
chip->of_xlate = of_pwm_single_xlate;
- devm_pm_runtime_enable(&adev->dev);
+ ret = devm_pm_runtime_enable(&adev->dev);
+ if (ret)
+ return ret;
return pwmchip_add(chip);
}
--
2.34.1
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2026-11-29 13:44 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-11-29 13:43 [PATCH] drm/bridge: ti-sn65dsi86: fail PWM probe if runtime PM setup fails Jiawen Liu
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®