aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/mfd/tps65217.h
diff options
context:
space:
mode:
authorMatthias Kaehlcke <matthias@kaehlcke.net>2012-09-24 16:25:28 -0400
committerSamuel Ortiz <sameo@linux.intel.com>2012-09-25 04:42:02 -0400
commiteebfdc17cc6c9f184a713d84b84e7602236360c6 (patch)
tree6f591d7a70cb540db68520b5c91361b1cb604bc5 /include/linux/mfd/tps65217.h
parentb6290ffe1f4ed4d8521fd7e46738d42ddd9f1935 (diff)
backlight: Add TPS65217 WLED driver
The TPS65217 chip contains a boost converter and current sinks which can be used to drive LEDs for use as backlights. Expose this functionality via the backlight API. Tested on an AM335x based custom board with a single WLED string, using different values for ISEL and FDIM (though it would be hard to tell the difference except for the value in WLEDCTRL1). Both instantiation through the device tree and by passing platform data have been tested. Testing has been done with an Androidized 3.2 kernel from the rowboat project. Koen Kooi reported the driver to be working on a Beaglebone board with LCD3 cape Signed-off-by: Matthias Kaehlcke <matthias@kaehlcke.net> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Diffstat (limited to 'include/linux/mfd/tps65217.h')
-rw-r--r--include/linux/mfd/tps65217.h18
1 files changed, 18 insertions, 0 deletions
diff --git a/include/linux/mfd/tps65217.h b/include/linux/mfd/tps65217.h
index 7cd83d826ed8..290762f93930 100644
--- a/include/linux/mfd/tps65217.h
+++ b/include/linux/mfd/tps65217.h
@@ -213,6 +213,23 @@ enum tps65217_regulator_id {
213/* Number of total regulators available */ 213/* Number of total regulators available */
214#define TPS65217_NUM_REGULATOR (TPS65217_NUM_DCDC + TPS65217_NUM_LDO) 214#define TPS65217_NUM_REGULATOR (TPS65217_NUM_DCDC + TPS65217_NUM_LDO)
215 215
216enum tps65217_bl_isel {
217 TPS65217_BL_ISET1 = 1,
218 TPS65217_BL_ISET2,
219};
220
221enum tps65217_bl_fdim {
222 TPS65217_BL_FDIM_100HZ,
223 TPS65217_BL_FDIM_200HZ,
224 TPS65217_BL_FDIM_500HZ,
225 TPS65217_BL_FDIM_1000HZ,
226};
227
228struct tps65217_bl_pdata {
229 enum tps65217_bl_isel isel;
230 enum tps65217_bl_fdim fdim;
231};
232
216/** 233/**
217 * struct tps65217_board - packages regulator init data 234 * struct tps65217_board - packages regulator init data
218 * @tps65217_regulator_data: regulator initialization values 235 * @tps65217_regulator_data: regulator initialization values
@@ -222,6 +239,7 @@ enum tps65217_regulator_id {
222struct tps65217_board { 239struct tps65217_board {
223 struct regulator_init_data *tps65217_init_data[TPS65217_NUM_REGULATOR]; 240 struct regulator_init_data *tps65217_init_data[TPS65217_NUM_REGULATOR];
224 struct device_node *of_node[TPS65217_NUM_REGULATOR]; 241 struct device_node *of_node[TPS65217_NUM_REGULATOR];
242 struct tps65217_bl_pdata *bl_pdata;
225}; 243};
226 244
227/** 245/**