[PATCH v5] backlight: led-backlight: add devlink to supplier LEDs
Luca Ceresoli
luca.ceresoli at bootlin.com
Mon May 19 20:15:00 UTC 2025
Hi Hervé,
On Mon, 19 May 2025 17:47:29 +0200
Herve Codina <herve.codina at bootlin.com> wrote:
> Hi Luca,
>
> On Mon, 19 May 2025 17:16:39 +0200
> Luca Ceresoli <luca.ceresoli at bootlin.com> wrote:
>
> ...
>
> > diff --git a/drivers/video/backlight/led_bl.c b/drivers/video/backlight/led_bl.c
> > index d2db157b2c290adc3a159023e9e2394fc877388c..8fe645b5b75447d009e1045dcf0c62d3bbc5425e 100644
> > --- a/drivers/video/backlight/led_bl.c
> > +++ b/drivers/video/backlight/led_bl.c
> > @@ -209,6 +209,19 @@ static int led_bl_probe(struct platform_device *pdev)
> > return PTR_ERR(priv->bl_dev);
> > }
> >
> > + for (i = 0; i < priv->nb_leds; i++) {
> > + struct device_link *link;
> > +
> > + link = device_link_add(&pdev->dev, priv->leds[0]->dev->parent,
>
> It should be priv->leds[i]->dev->parent instead of leds[0], shouldn't it?
Ah, well spotted, thanks!
My led-backlight device only uses one LED, so I hadn't noticed during
testing.
v6 on its way.
Luca
--
Luca Ceresoli, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
More information about the dri-devel
mailing list