Thank you for your contribution! Sashiko AI review found 1 potential
issue to consider:
- [High] drm/panel: lg-sw43408: missing resume callback in
  sw43408_pm_ops
--

commit 503ce47692b3c0852447cd397b0dd17406adf4a7
Author: David Heidelberg <[email protected]>

drm/panel: lg-sw43408: keep VPNL paired with VDDI and reset deasserted

This commit leaves reset_gpio deasserted across unprepare and keeps VPNL
enabled until VDDI is fully powered down, checking VDDI both in
sw43408_power_off() and from a late system sleep callback.

> diff --git a/drivers/gpu/drm/panel/panel-lg-sw43408.c 
> b/drivers/gpu/drm/panel/panel-lg-sw43408.c
> index 7123ad18744cf..6854292bd99ca 100644
> --- a/drivers/gpu/drm/panel/panel-lg-sw43408.c
> +++ b/drivers/gpu/drm/panel/panel-lg-sw43408.c
[ ... ]
> @@ -57,14 +67,80 @@ static int sw43408_disable(struct drm_panel *panel)
[ ... ]
> +static int sw43408_suspend_late(struct device *dev)
> +{
> +     struct sw43408_panel *ctx = dev_get_drvdata(dev);
> +     int ret;
> +
> +     if (ctx->base.prepared)
> +             return 0;
> +
> +     ret = sw43408_maybe_disable_vpnl(ctx);
> +     if (ret)
> +             return ret;
> +
> +     return 0;
> +}
[ ... ]
> @@ -318,10 +408,15 @@ static int sw43408_probe(struct mipi_dsi_device *dsi)
>       return devm_mipi_dsi_attach(&dsi->dev, dsi);
>  }
>  
> +static const struct dev_pm_ops sw43408_pm_ops = {
> +     LATE_SYSTEM_SLEEP_PM_OPS(sw43408_suspend_late, NULL)
> +};

[Severity: High]
Does sw43408_pm_ops also need an early resume callback to re-enable vpnl
when vddi turns back on during system resume?

During system suspend, DRM unprepares the panel in .prepare
(dpu_pm_ops.prepare -> msm_kms_pm_prepare()), stmfts_suspend() drops the
touchscreen's vddi vote in .suspend, and sw43408_suspend_late() then sees
regulator_is_enabled(vddi) == 0 and disables vpnl.

On resume, stmfts_resume() unconditionally re-enables vddi during the
.resume phase, while DRM does not resume the panel until .complete (or not
at all during resume if the display was blanked before suspend).  That
leaves the panel in the vddi-on, vpnl-off state across .resume, and when
sw43408_prepare() later runs, vddi is already held enabled by stmfts so
regulator_enable(vddi) does not power-cycle vddi to recover the DDIC.

-- 
Sashiko AI review ยท 
https://sashiko.dev/#/patchset/[email protected]?part=4

Reply via email to