Re: [PATCH 3/3] lp5521: move to drivers/leds

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Felipe Balbi wrote:
On Mon, Oct 06, 2008 at 03:54:57PM +0300, ext Riku Voipio wrote:
On Mon, Oct 06, 2008 at 02:51:03PM +0300, Felipe Balbi wrote:
On Mon, Oct 06, 2008 at 02:17:23PM +0300, Tony Lindgren wrote:
* Riku Voipio <riku.voipio@xxxxxx> [081006 14:09]:
On Mon, Oct 06, 2008 at 12:11:31PM +0300, Felipe Balbi wrote:
This driver should be sitting together with the other
led drivers.
But this driver actually doesn't implement the led sysfs interface.
If the driver is changed to implement the led framework interface,
we break the existing n810 userland and expose only limited subset
of lp5521 features for userland..
Maybe this feature should be a distro specific hack on top of
the mainline tree?
the problem is that led api (afaict) doesn't really have abstraction for
rgb leds like the one we use. It can only handle blinky leds and on/off
transitions and we need more functionality.
RGB can somewhat be handled, by creating three led devices:

n810:red:foo
n810:gree:foo
n810:blue:foo

If that's the case I'd expect the driver author to do it since I have no
time left for that. A few fixes here and there to the driver is fine and
preparing the driver for mainline integration is also fine since it's a
simple cp iteration.

The driver and chip supports lots of functionality that is not yet in the led framework. Even if there is now support for some "Hardware accelerated blink of LEDs" it is not enough.

The lp5521 chip can be programmed with blinking patterns including fades, triggers between R, G and B channels and other nice features Chip has three modes: direct,(set brightness of leds directly through sysfs) load (load a pattern to channel) and run.

RGB direct mode could be handled with three led devices but the rest of the functionality is a bit trickier.

Patterns are mainly used in n810 as it doesn't require any CPU interaction

At the time of writing this driver led-class.txt stated that:
"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."

The driver for the next version of the lp552x chip uses the led class for the direct mode

-Mathias

--
To unsubscribe from this list: send the line "unsubscribe linux-omap" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Arm (vger)]     [ARM Kernel]     [ARM MSM]     [Linux Tegra]     [Linux WPAN Networking]     [Linux Wireless Networking]     [Maemo Users]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite Trails]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux