Re: [PATCH RFC leds-next] leds: initial support for Turris Omnia LEDs

Jacek Anaszewski
2020-04-02T21:00:45Z

On 4/2/20 10:57 PM, Marek Behun wrote:
> On Thu, 2 Apr 2020 22:19:50 +0200
> Jacek Anaszewski <jacek.anaszewski@gmail.com> wrote:
>
>> On 4/2/20 4:29 PM, Marek Behun wrote:
>>> On Sun, 29 Mar 2020 14:53:57 +0200
>>> Jacek Anaszewski <jacek.anaszewski@gmail.com> wrote:
>>>
>>>>> in the case you mentioned there is a one "global" brightness setting per
>>>>> each RGB LED. On Omnia, all 12 RGB LEDs have just one "global"
>>>>> brightness property. Ie. I press the button, and all 12 LEDs glow get
>>>>> dimmer. So there could be a 13th LED device with color LUMA, but what
>>>>> function should it be given in DTS?
>>>>
>>>> Then, in this particular case, adding devicename prefix for the whole
>>>> family of LEDs would be justified. The question is whether it should be
>>>> hardware related name or rather something different.
>>>
>>> Hi Jacek,
>>>
>>> so now we have
>>> device:color:function
>>> what if we made it so that there was a 4th part of LED name, ie
>>> group:device:color:function
>>> ?
>>>
>>> Would this be a problem?
>>
>> Indeed, the device alone would not be a sufficient differentiator
>> since it is possible to have more than one LED controller of the
>> same type on the board.
>>
>> Nonetheless, I'd rather avoid the addition of a new generic section.
>> Probably we would have to make it specific to this device.
>>
>
> Ok, in that case I will do it so that devicename is "omnia".
> devicename_mandatory should be set to true, yes?

If you want to have four sections then you must compose LED
name yourself and not use new *ext() API. But please hold on,
since I suppose Pavel will have something to add to that.

--
Best regards,
Jacek Anaszewski