diff options
author | Luotao Fu <l.fu@pengutronix.de> | 2009-02-11 16:24:40 -0500 |
---|---|---|
committer | Richard Purdie <rpurdie@linux.intel.com> | 2009-04-06 11:06:26 -0400 |
commit | 41c42ff5dbe29b7b826e6736f960959c76e7acf0 (patch) | |
tree | c405b8e5e266994fbf81d7610cf8498215e0baff /include/linux | |
parent | b2bdc3e7130001804f27e7c1254930143119f435 (diff) |
leds: simple driver for pwm driven LEDs
Add a simple driver for pwm driver LEDs. pwm_id and period can be defined
in board file. It is developed for pxa, however it is probably generic
enough to be used on other platforms with pwm.
Signed-off-by: Luotao Fu <l.fu@pengutronix.de>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
Diffstat (limited to 'include/linux')
-rw-r--r-- | include/linux/leds_pwm.h | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/include/linux/leds_pwm.h b/include/linux/leds_pwm.h new file mode 100644 index 000000000000..33a071167489 --- /dev/null +++ b/include/linux/leds_pwm.h | |||
@@ -0,0 +1,21 @@ | |||
1 | /* | ||
2 | * PWM LED driver data - see drivers/leds/leds-pwm.c | ||
3 | */ | ||
4 | #ifndef __LINUX_LEDS_PWM_H | ||
5 | #define __LINUX_LEDS_PWM_H | ||
6 | |||
7 | struct led_pwm { | ||
8 | const char *name; | ||
9 | const char *default_trigger; | ||
10 | unsigned pwm_id; | ||
11 | u8 active_low; | ||
12 | unsigned max_brightness; | ||
13 | unsigned pwm_period_ns; | ||
14 | }; | ||
15 | |||
16 | struct led_pwm_platform_data { | ||
17 | int num_leds; | ||
18 | struct led_pwm *leds; | ||
19 | }; | ||
20 | |||
21 | #endif | ||