пт, 29 трав. 2026 р. о 14:00 Daniel Thompson <[email protected]> пише: > > On Thu, May 28, 2026 at 04:51:19PM +0300, Svyatoslav Ryhel wrote: > > Since there are no users of this driver via platform data, remove the > > platform data support and switch to using Device Tree bindings. > > Additionally, optimize functions used only by platform data. > > The last sentence is a little vague and makes us have to hunt for the > changes in a relatively large patch. If it is referring to the change to > common up the init and update code then it's would better to say that > explicitly! >
If I understood Jonathan properly, the last sentence will get its own patch. > > Signed-off-by: Svyatoslav Ryhel <[email protected]> > > --- > > drivers/iio/light/lm3533-als.c | 95 ++++------ > > drivers/leds/leds-lm3533.c | 51 ++++-- > > drivers/mfd/lm3533-core.c | 268 ++++++++++------------------ > > drivers/video/backlight/lm3533_bl.c | 52 ++++-- > > include/linux/mfd/lm3533.h | 51 +----- > > Just one comment for backlight, below: > > > diff --git a/drivers/video/backlight/lm3533_bl.c > > b/drivers/video/backlight/lm3533_bl.c > > index babfd3ceec86..42da652df58d 100644 > > --- a/drivers/video/backlight/lm3533_bl.c > > +++ b/drivers/video/backlight/lm3533_bl.c > > @@ -295,13 +293,20 @@ static int lm3533_bl_probe(struct platform_device > > *pdev) > > bl->cb.id = lm3533_bl_get_ctrlbank_id(bl); > > bl->cb.dev = NULL; /* until registered */ > > > > + name = devm_kasprintf(&pdev->dev, GFP_KERNEL, "%s-%d", > > + pdev->name, pdev->id); > > + if (!name) > > + return -ENOMEM; > > + > > memset(&props, 0, sizeof(props)); > > props.type = BACKLIGHT_RAW; > > props.max_brightness = LM3533_BL_MAX_BRIGHTNESS; > > - props.brightness = pdata->default_brightness; > > Given the big changes to the driver is there any chance of putting a > good value in props.scale (BACKLIGHT_SCALE_LINEAR or > BACKLIGHT_SCALE_NON_LINEAR)? > > If the difference between 50% and 100% *looks* like 50% then the scale is > non-linear (since humn perception of brightness is not linear). > Yes! But not in this patch. This patchset has a dedicated patch implementing linear and non-linear configuration from tree which may include this configuration as well. No guarantees though, but I will keep in mind this request. Thanks! > > Daniel.
