On 9/8/26 9:10 AM, Krzysztof Kozlowski wrote: > If msm_hdmi_phy_resource_enable() fails, e.g. when enabling regulators, > it should reverse the state of things already changed. > msm_hdmi_phy_resource_enable() is used also in probe path, thus such > failure, which could be simple deferred probe, would leave these > resources permanently enabled for the rest of the runtime. > > Cc: <[email protected]> > Fixes: 15b4a4523859 ("drm/msm/hdmi: Create a separate HDMI PHY driver") > Signed-off-by: Krzysztof Kozlowski <[email protected]> > --- > drivers/gpu/drm/msm/hdmi/hdmi_phy.c | 16 ++++++++++++++-- > 1 file changed, 14 insertions(+), 2 deletions(-) > > diff --git a/drivers/gpu/drm/msm/hdmi/hdmi_phy.c > b/drivers/gpu/drm/msm/hdmi/hdmi_phy.c > index eb1088755cb3..15e37596bdb1 100644 > --- a/drivers/gpu/drm/msm/hdmi/hdmi_phy.c > +++ b/drivers/gpu/drm/msm/hdmi/hdmi_phy.c > @@ -67,16 +67,28 @@ int msm_hdmi_phy_resource_enable(struct hdmi_phy *phy) > ret = regulator_bulk_enable(cfg->num_regs, phy->regs); > if (ret) { > DRM_DEV_ERROR(dev, "failed to enable regulators: (%d)\n", ret); > - return ret; > + goto err_pm_put;
If you're a fan, there's PM_RUNTIME_ACQUIRE_xxx in cleanup.h Konrad
