leds: core: Introduce LED pattern trigger
authorBaolin Wang <baolin.wang@linaro.org>
Thu, 11 Oct 2018 04:07:14 +0000 (12:07 +0800)
committerJacek Anaszewski <jacek.anaszewski@gmail.com>
Thu, 11 Oct 2018 19:55:58 +0000 (21:55 +0200)
commit5fd752b6b3a2233972ce1726df8bdb40886113a9
tree6144ef6eee8ab1db8604de39dd311fae5e22861f
parent2d00f35c55e74fcb5626c9aa336c1ed697cd2ae9
leds: core: Introduce LED pattern trigger

This patch adds a new LED trigger that LED device can configure
to employ software or hardware pattern engine.

Consumers can write 'pattern' file to enable the software pattern
which alters the brightness for the specified duration with one
software timer.

Moreover consumers can write 'hw_pattern' file to enable the hardware
pattern for some LED controllers which can autonomously control
brightness over time, according to some preprogrammed hardware
patterns.

Signed-off-by: Raphael Teysseyre <rteysseyre@gmail.com>
Signed-off-by: Baolin Wang <baolin.wang@linaro.org>
Signed-off-by: Jacek Anaszewski <jacek.anaszewski@gmail.com>
Documentation/ABI/testing/sysfs-class-led-trigger-pattern [new file with mode: 0644]
drivers/leds/trigger/Kconfig
drivers/leds/trigger/Makefile
drivers/leds/trigger/ledtrig-pattern.c [new file with mode: 0644]
include/linux/leds.h