* LED: inform userspace about brightness change
@ 2014-12-24 20:06 Pali Rohár
2015-01-06 17:55 ` Bryan Wu
0 siblings, 1 reply; 2+ messages in thread
From: Pali Rohár @ 2014-12-24 20:06 UTC (permalink / raw)
To: Bryan Wu, Richard Purdie, Darren Hart, linux-leds,
platform-driver-x86, linux-kernel
[-- Attachment #1: Type: Text/Plain, Size: 811 bytes --]
Hello!
What is preferred way from kernel driver to inform userspace
about LED device brightness change? In /sys/class/leds/<device>/
is file brightness which can be used to read current brightness
or set write new value. But sometimes also firmware (or device)
can change value on its own and thus userspace software which
provides slider for setting brightness will be incorrect.
For example on Dell laptops there is driver which support setting
and reading keyboard backlight (via leds kernel interface). But
firmware/BIOS can change brightness (when something happen) and
it can inform running system about this change via ACPI/WMI event
interface. But how to use kernel led interface to inform userpace
about this change? It is possible?
--
Pali Rohár
pali.rohar@gmail.com
[-- Attachment #2: This is a digitally signed message part. --]
[-- Type: application/pgp-signature, Size: 198 bytes --]
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: LED: inform userspace about brightness change
2014-12-24 20:06 LED: inform userspace about brightness change Pali Rohár
@ 2015-01-06 17:55 ` Bryan Wu
0 siblings, 0 replies; 2+ messages in thread
From: Bryan Wu @ 2015-01-06 17:55 UTC (permalink / raw)
To: Pali Rohár
Cc: Richard Purdie, Darren Hart, Linux LED Subsystem,
platform-driver-x86, lkml
On Wed, Dec 24, 2014 at 12:06 PM, Pali Rohár <pali.rohar@gmail.com> wrote:
> Hello!
>
> What is preferred way from kernel driver to inform userspace
> about LED device brightness change? In /sys/class/leds/<device>/
> is file brightness which can be used to read current brightness
> or set write new value. But sometimes also firmware (or device)
> can change value on its own and thus userspace software which
> provides slider for setting brightness will be incorrect.
>
> For example on Dell laptops there is driver which support setting
> and reading keyboard backlight (via leds kernel interface). But
> firmware/BIOS can change brightness (when something happen) and
> it can inform running system about this change via ACPI/WMI event
> interface. But how to use kernel led interface to inform userpace
> about this change? It is possible?
>
Sorry for the delay, actually I don't find any possible existing way
to send brightness change event from LED subsystem to user space.
I think we can add an udev event in set_brightness API, then when we
change the brightness, it will send out udev event to user space.
Thanks,
-Bryan
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2015-01-06 17:55 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-12-24 20:06 LED: inform userspace about brightness change Pali Rohár
2015-01-06 17:55 ` Bryan Wu
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.