linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Pavel Machek <pavel@ucw.cz>
To: Richard Purdie <rpurdie@rpsys.net>
Cc: "Németh Márton" <nm127@freemail.hu>,
	"Dmitry Torokhov" <dmitry.torokhov@gmail.com>,
	linux-input@atrey.karlin.mff.cuni.cz,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH] input: extend EV_LED
Date: Fri, 16 Feb 2007 00:24:38 +0100	[thread overview]
Message-ID: <20070215232438.GB4176@elf.ucw.cz> (raw)
In-Reply-To: <1171580944.5839.38.camel@localhost.localdomain>

Hi!

> > > > >I do not know the LED subsystem in detail, but I do not 
> > > > >know any possibility to access the i8042 from different 
> > > > >subsystem than the input subsystem.
> > > > >
> > > > >What do you think and recommend?
> > > > 
> > > > I think you need to use leds framework for what you are 
> > > > trying to do.
> > > 
> > > I'm actually not sure if led framework can do that. It was
> > > designed for leds on gpios, and handles blinking itself.
> 
> The led framework is generic. If you can write a function to turn it
> on/off you can drive it with the LED framework.

Even if that function is slow and sleeps?

> > > But he could export two leds :-).
> >
> > what do you mean about two leds? The first one would be
> > off/0.5Hz and the other off/1Hz?
> > 
> > I read in linux/Documentation/led-class.txt the following:
> > 
> > | Some leds can be programmed to flash in hardware. As this
> > isn't a generic
> > | LED device property, this should be exported as a device
> > specific sysfs
> > | attribute rather than part of the class if this
> > functionality is required.
> > 
> > Does it mean that neither the input subsystem nor the led
> > subsystem is designed for hardware acelerated blinking leds?
> > Is there any usual way what attribute a hw accelerated
> > blinking LED_MAIL should export?
> 
> This has been discussed in several places several times. The problem
> with hardware accelerated flashing is that you're are often limited to
> certain constraints (this case being no exception) and indicating what
> these are to userspace in a generic fashion is difficult.
> 
> One way I've come up with is adds capability to the class to have LED
> specific triggers and you can then expose these hardware capabilities as
> an extra trigger specific to the LED.
> 
> Another proposal more specific to this use case was to have some
> information behind the scenes which the software timer based trigger
> could use to turn on the "hardware acceleration" if present and capable
> of the requested mode. This might just need a function pointer in the
> core so could be quite neat.

I do not think we want to permit this led to run in "not accelerated"
mode. I believe i8042 accesses are pretty expensive.

> Nether patch exists yet.

Yep, interested party should create one of them :-). (And I'd prefer
the first one, due to i8042 slowness).

									Pavel
-- 
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html

  reply	other threads:[~2007-02-15 23:25 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-02-11 10:02 [PATCH] input: extend EV_LED Németh Márton
2007-02-12 18:31 ` Dmitry Torokhov
2007-02-14 19:06   ` Németh Márton
2007-02-14 19:49     ` Dmitry Torokhov
2007-02-14 23:51       ` Németh Márton
2007-02-15 17:40       ` Pavel Machek
2007-02-15 22:47         ` Németh Márton
2007-02-15 23:09           ` Richard Purdie
2007-02-15 23:24             ` Pavel Machek [this message]
2007-02-15 23:36               ` Richard Purdie
2007-02-16  3:12             ` Henrique de Moraes Holschuh
2007-02-18 11:05               ` Richard Purdie
2007-02-18 14:42                 ` Henrique de Moraes Holschuh
2007-02-18  7:45             ` Németh Márton
2007-02-18  8:07               ` Willy Tarreau
2007-02-18 11:12               ` Richard Purdie
2007-02-16 14:04           ` 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=20070215232438.GB4176@elf.ucw.cz \
    --to=pavel@ucw.cz \
    --cc=dmitry.torokhov@gmail.com \
    --cc=linux-input@atrey.karlin.mff.cuni.cz \
    --cc=linux-kernel@vger.kernel.org \
    --cc=nm127@freemail.hu \
    --cc=rpurdie@rpsys.net \
    /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).