linux-leds.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Pavel Machek <pavel@ucw.cz>
To: Doug Zobel <dougdev334@gmail.com>
Cc: Rob Herring <robh@kernel.org>,
	Jacek Anaszewski <jacek.anaszewski@gmail.com>,
	linux-leds@vger.kernel.org, devicetree@vger.kernel.org,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH 2/2] dt: bindings: lp55xx: Add predefined LED pattern
Date: Sun, 16 May 2021 20:31:35 +0200	[thread overview]
Message-ID: <20210516183135.GA26985@duo.ucw.cz> (raw)
In-Reply-To: <CABa6EMYdY9WBN0+edgcEFc0uiBmWUDert7nXCN+FWeRMG=0S6A@mail.gmail.com>

[-- Attachment #1: Type: text/plain, Size: 1295 bytes --]

Hi!

> > I don't know that this belongs in DT though. Won't a user want to create
> > their own patterns? That means there should be a sysfs interface (which
> > we either already have or has been attempted IIRC).
> 
> Yes, there is a sysfs interface for running patterns via the firmware
> loading interface.  The firmware loading interface doesn't seem well
> suited for constantly changing the pattern that the LED driver runs.
> I found it to be slow and unreliable when quickly changing the LED
> pattern.  The existing predef pattern functionality works much better.
> Unfortunately the only way to define the patterns for it is via the
> platform data structure.  Adding the predef patterns to the device
> tree seemed like a good way to make use of the existing functionality
> in the driver.

Take a look at the pattern trigger. That's the way to change patterns
at runtime, no need for firmware loading.

I may even have compiler from that interface to the bytecode lp55xx
uses. Some assembly will be required. Doing so with the RGB LED will
be even more fun. 

We'll want to deprecate the firmware loading interface at some point.

Forget the device tree, that will not help you.

Best regards,
								Pavel
-- 
http://www.livejournal.com/~pavelmachek

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 195 bytes --]

  reply	other threads:[~2021-05-16 18:31 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-05-11 20:48 [PATCH 0/2] Device Tree support for LP5562 predefined patterns Doug Zobel
2021-05-11 20:48 ` [PATCH 1/2] leds: lp55xx: support predefined pattern in Device Tree Doug Zobel
2021-05-11 20:48 ` [PATCH 2/2] dt: bindings: lp55xx: Add predefined LED pattern Doug Zobel
2021-05-12 18:35   ` Rob Herring
2021-05-13  2:20   ` Rob Herring
2021-05-13 20:47     ` Doug Zobel
2021-05-16 18:31       ` Pavel Machek [this message]
2021-05-17 20:07         ` Doug Zobel
2021-05-16 18:22   ` Pavel Machek

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=20210516183135.GA26985@duo.ucw.cz \
    --to=pavel@ucw.cz \
    --cc=devicetree@vger.kernel.org \
    --cc=dougdev334@gmail.com \
    --cc=jacek.anaszewski@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-leds@vger.kernel.org \
    --cc=robh@kernel.org \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).