Re: [PATCH v8 07/11] drm/panel: panel-simple: Stash DP AUX bus; allow using it for DDC

From: Doug Anderson
Date: Mon Jun 07 2021 - 13:07:44 EST


Hi,

On Fri, Jun 4, 2021 at 9:10 AM <rajeevny@xxxxxxxxxxxxxx> wrote:
>
> Hi Doug,
>
> > panel->no_hpd = of_property_read_bool(dev->of_node, "no-hpd");
> > if (!panel->no_hpd) {
> > @@ -708,6 +712,8 @@ static int panel_simple_probe(struct device *dev,
> > const struct panel_desc *desc)
> >
> > if (!panel->ddc)
> > return -EPROBE_DEFER;
> > + } else if (aux) {
> > + panel->ddc = &aux->ddc;
> > }
>
> In panel_simple_probe(), the put_device(&panel->ddc->dev) call is
> causing issue when the aux->ddc is used to assign panel->ddc
> It works well when "ddc-i2c-bus" is used to assign panel->ddc
>
> static int panel_simple_probe(...)
> {
> ...
>
> free_ddc:
> if (panel->ddc)
> put_device(&panel->ddc->dev);
>
> return err;
> }

Thanks for catching! Fixed in v9.


-Doug