Re: [PATCH v4 2/2] leds: bd2606mvv: Driver for the Rohm 6 Channel i2c LED driver
From: Pavel Machek
Date: Sat Apr 15 2023 - 04:01:13 EST
Hi!
> > > The device provides 6 channels which can be individually
> > > turned off and on but groups of two channels share a common brightness
> > > register.
> >
> > Yeah, well.. Turn it into 3-channel controller with brightness or
> > 6-channel on/off one... You can't really share brightness.
> >
> No, I cannot change the hardware, so it is a 6-channel with limitations.
> And the devicetree has to describe the hardware and not the driver.
Device tree is okay, I commented on the driver.
> What is discussable is just how the driver should deal with that:
>
> I see 5 possibilities.
> a) ignore the shared brightness problem (status quo)
> b) never set a brightness other than full on/off
> c) ignore one led of each pair (not register it at all{
> d) couple also the on/off of the pairs, so present to
> userspace only max. 3 leds.
> e) allow full brightness control where independently possible,
> if LEDs are defined where that leads to conflicts,
> register them with max_brightness=1 and use them
> in on/off mode.
>
> My preference were a) or e), the most possible usages.
> e) has a cleaner interface to the userspace.
b) c) e) are acceptable to me. So I guess e) is preffered.
BR, Pavel
--
People of Russia, stop Putin before his war on Ukraine escalates.
Attachment:
signature.asc
Description: PGP signature