linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Richard Purdie <rpurdie@rpsys.net>
To: "Németh Márton" <nm127@freemail.hu>
Cc: Pavel Machek <pavel@ucw.cz>,
	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: Thu, 15 Feb 2007 23:09:03 +0000	[thread overview]
Message-ID: <1171580944.5839.38.camel@localhost.localdomain> (raw)
In-Reply-To: <freemail.20070115234756.58787@fm13.freemail.hu>

On Thu, 2007-02-15 at 23:47 +0100, Németh Márton wrote:
> Pavel Machek <pavel@ucw.cz> wrote:
> > > >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.

> > 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.

Nether patch exists yet.

Cheers,

Richard



  reply	other threads:[~2007-02-15 23:10 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 [this message]
2007-02-15 23:24             ` Pavel Machek
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=1171580944.5839.38.camel@localhost.localdomain \
    --to=rpurdie@rpsys.net \
    --cc=dmitry.torokhov@gmail.com \
    --cc=linux-input@atrey.karlin.mff.cuni.cz \
    --cc=linux-kernel@vger.kernel.org \
    --cc=nm127@freemail.hu \
    --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 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).