All of lore.kernel.org
 help / color / mirror / Atom feed
From: Hans de Goede <hdegoede@redhat.com>
To: Pavel Machek <pavel@ucw.cz>
Cc: Jafar Akhondali <gigelaknak@gmail.com>,
	Andy Shevchenko <andy.shevchenko@gmail.com>,
	Mauro Carvalho Chehab <mchehab+huawei@kernel.org>,
	mauro.chehab@huawei.com,
	Linux LED Subsystem <linux-leds@vger.kernel.org>,
	Linux Kernel Mailing List <linux-kernel@vger.kernel.org>
Subject: Re: LEDs with hardware-accelerated patterns, suspend indication
Date: Fri, 25 Jun 2021 11:18:35 +0200	[thread overview]
Message-ID: <59ac4a5b-7dc5-bb9d-e161-c0a7ceb9f399@redhat.com> (raw)
In-Reply-To: <20210623203925.GI8540@amd>

Hi,

On 6/23/21 10:39 PM, Pavel Machek wrote:
> Hi!
> 
>>> Sorry for the late reply.
>>> there are two categories of keyboard lighting modes:
>>> 1. static
>>> 2. dynamic
>>>
>>> In static mode, any of 4 zones can be configured to show specific color,
>>> independently.
>>>
>>> In dynamic mode, there is no control over specific zones.
>>> It's only possible to set some: color, speed, direction
>>> and: [R]ed,[G]reen, [B]lue
>>>
>>> so in dynamic mode, the user can't control zones,
>>> the dynamic effects take care of that.
>>
>> So we have 4 zones, which are individual controllable, so which should
>> probably be modeled as individual LED class devices. But when we enable
>> the hardware effects, then the individual addressing goes away and we
>> set one effect which applies to all zones.
>>
>> Jafar, do I understand this correctly?
>>
>> Pavel, how should this be mapped to the led-class API?
> 
> Fun :-).
> 
>> Some ideas:
>>
>> a) Only add the new lpattern to the main zone?
>> 2) Add the new lpattern to all zones, but only make it
>> writable in the main zone ?
> 
> Require lpattern in all zones to be same and active before actually
> enabling the pattern?

That seems less user friendly / a cumbersome interface I prefer
one of my 2 initial ideas.

Or maybe add lpattern symlinks to the other zones to the main zone,
I think that is actually best because it clearly shows how things
work, all 4 LED (zones) support a lpattern, but it is a single
shared lpattern.

> Decide lpattern is not suitable for this and figure out what to with
> multi-LED triggers? Someone wanted them for "meters" (CPU load 25% 50%
> 75% 100% LED bar)...

I think true multi-led triggers are overkill here, in essence this
is just a standard lpattern, except that it is shared between the
zones. 

> Skip this hardware feature for now. We don't have to support
> everything?

Although it is true that we don't have to support everything not
supporting this would give Linux a feature disparity with the
Windows utility for controlling the keyboard which IMHO is
undesirable.

Regards,

Hans




      reply	other threads:[~2021-06-25  9:18 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-05-26 15:30 LEDs with hardware-accelerated patterns, suspend indication Pavel Machek
2021-06-04 20:28 ` Hans de Goede
     [not found]   ` <CAMW3L+19tP_9=+8j8LLjqCGDaaVZ86UMm9NwLbbpA77zOYnr1Q@mail.gmail.com>
     [not found]     ` <79988fe2-7b3d-7485-131c-4f654ec6d8b8@redhat.com>
     [not found]       ` <CAMW3L+13O4jXyp1LVtuxhpXP_fkfWXi9JoNS8FYUAMHaJBGKZg@mail.gmail.com>
2021-06-15 12:17         ` Hans de Goede
2021-06-23 20:39           ` Pavel Machek
2021-06-25  9:18             ` Hans de Goede [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=59ac4a5b-7dc5-bb9d-e161-c0a7ceb9f399@redhat.com \
    --to=hdegoede@redhat.com \
    --cc=andy.shevchenko@gmail.com \
    --cc=gigelaknak@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-leds@vger.kernel.org \
    --cc=mauro.chehab@huawei.com \
    --cc=mchehab+huawei@kernel.org \
    --cc=pavel@ucw.cz \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.