aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/platform_data/leds-lm3556.h
diff options
context:
space:
mode:
authorG.Shark Jeong <gshark.jeong@gmail.com>2012-06-22 08:12:06 +0800
committerBryan Wu <bryan.wu@canonical.com>2012-07-24 07:52:35 +0800
commit32abb4788d3fff69fa242c7850e39ec1418df4f4 (patch)
tree26441f5ebda1a77b7f0f72fb6b487634b2e623c0 /include/linux/platform_data/leds-lm3556.h
parent1522d02e275332080ec27e268edc29c79c6f5e0c (diff)
downloadkernel_goldelico_gta04-32abb4788d3fff69fa242c7850e39ec1418df4f4.zip
kernel_goldelico_gta04-32abb4788d3fff69fa242c7850e39ec1418df4f4.tar.gz
kernel_goldelico_gta04-32abb4788d3fff69fa242c7850e39ec1418df4f4.tar.bz2
leds: Add LED driver for lm3556 chip
LM3556 : The LM3556 is a 4 MHz fixed-frequency synchronous boost converter plus 1.5A constant current driver for a high-current white LED. Datasheet: www.national.com/ds/LM/LM3556.pdf Tested on OMAP4430 (bryan.wu@canonical.com: use module_i2c_driver() rather than lm3556_init/lm3556_exit for code simplicity; fixed some typo pointed out by Rob Landley) Signed-off-by: G.Shark Jeong <gshark.jeong@gmail.com> Reviewed-by: Axel Lin <axel.lin@gmail.com> Reviewed-by: Kim, Milo <Milo.Kim@ti.com> Acked-by: Rob Landley <rob@landley.net> Signed-off-by: Bryan Wu <bryan.wu@canonical.com>
Diffstat (limited to 'include/linux/platform_data/leds-lm3556.h')
-rw-r--r--include/linux/platform_data/leds-lm3556.h50
1 files changed, 50 insertions, 0 deletions
diff --git a/include/linux/platform_data/leds-lm3556.h b/include/linux/platform_data/leds-lm3556.h
new file mode 100644
index 0000000..4b4e7d6
--- /dev/null
+++ b/include/linux/platform_data/leds-lm3556.h
@@ -0,0 +1,50 @@
+/*
+ * Simple driver for Texas Instruments LM3556 LED Flash driver chip (Rev0x03)
+ * Copyright (C) 2012 Texas Instruments
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License version 2 as
+ * published by the Free Software Foundation.
+ *
+ */
+
+#ifndef __LINUX_LM3556_H
+#define __LINUX_LM3556_H
+
+#define LM3556_NAME "leds-lm3556"
+
+enum lm3556_pin_polarity {
+ PIN_LOW_ACTIVE = 0,
+ PIN_HIGH_ACTIVE,
+};
+
+enum lm3556_pin_enable {
+ PIN_DISABLED = 0,
+ PIN_ENABLED,
+};
+
+enum lm3556_strobe_usuage {
+ STROBE_EDGE_DETECT = 0,
+ STROBE_LEVEL_DETECT,
+};
+
+enum lm3556_indic_mode {
+ INDIC_MODE_INTERNAL = 0,
+ INDIC_MODE_EXTERNAL,
+};
+
+struct lm3556_platform_data {
+ enum lm3556_pin_enable torch_pin_en;
+ enum lm3556_pin_polarity torch_pin_polarity;
+
+ enum lm3556_strobe_usuage strobe_usuage;
+ enum lm3556_pin_enable strobe_pin_en;
+ enum lm3556_pin_polarity strobe_pin_polarity;
+
+ enum lm3556_pin_enable tx_pin_en;
+ enum lm3556_pin_polarity tx_pin_polarity;
+
+ enum lm3556_indic_mode indicator_mode;
+};
+
+#endif /* __LINUX_LM3556_H */