aboutsummaryrefslogtreecommitdiffstats
path: root/include/linux/platform_data
diff options
context:
space:
mode:
authorKim, Milo <Milo.Kim@ti.com>2013-04-29 19:18:03 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2013-04-29 21:28:18 -0400
commit0b8185733966c1863b6b90ca2697327118ce5032 (patch)
tree746742b89c6eb0b9f20058139afc2ec93c3bd122 /include/linux/platform_data
parent600ffd33d09e3803d81607d3404a8cad709160e4 (diff)
backlight: lp855x: move backlight mode platform data
The brightness of LP855x devices is controlled by I2C register or PWM input . This mode was selected through the platform data, but it can be chosen by the driver internally without platform data configuration. How to decide the control mode: If the PWM period has specific value, the mode is PWM input. On the other hand, the mode is register-based. This mode selection is done on the _probe(). Move 'mode' from a header file to the driver private data structure, 'lp855 x'. And correlated code was replaced. Signed-off-by: Milo(Woogyom) Kim <milo.kim@ti.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'include/linux/platform_data')
-rw-r--r--include/linux/platform_data/lp855x.h7
1 files changed, 0 insertions, 7 deletions
diff --git a/include/linux/platform_data/lp855x.h b/include/linux/platform_data/lp855x.h
index d135939d392a..e0954dfea7ee 100644
--- a/include/linux/platform_data/lp855x.h
+++ b/include/linux/platform_data/lp855x.h
@@ -69,11 +69,6 @@ enum lp855x_chip_id {
69 LP8557, 69 LP8557,
70}; 70};
71 71
72enum lp855x_brightness_ctrl_mode {
73 PWM_BASED = 1,
74 REGISTER_BASED,
75};
76
77enum lp8550_brighntess_source { 72enum lp8550_brighntess_source {
78 LP8550_PWM_ONLY, 73 LP8550_PWM_ONLY,
79 LP8550_I2C_ONLY = 2, 74 LP8550_I2C_ONLY = 2,
@@ -116,7 +111,6 @@ struct lp855x_rom_data {
116/** 111/**
117 * struct lp855x_platform_data 112 * struct lp855x_platform_data
118 * @name : Backlight driver name. If it is not defined, default name is set. 113 * @name : Backlight driver name. If it is not defined, default name is set.
119 * @mode : brightness control by pwm or lp855x register
120 * @device_control : value of DEVICE CONTROL register 114 * @device_control : value of DEVICE CONTROL register
121 * @initial_brightness : initial value of backlight brightness 115 * @initial_brightness : initial value of backlight brightness
122 * @period_ns : platform specific pwm period value. unit is nano. 116 * @period_ns : platform specific pwm period value. unit is nano.
@@ -129,7 +123,6 @@ struct lp855x_rom_data {
129 */ 123 */
130struct lp855x_platform_data { 124struct lp855x_platform_data {
131 const char *name; 125 const char *name;
132 enum lp855x_brightness_ctrl_mode mode;
133 u8 device_control; 126 u8 device_control;
134 int initial_brightness; 127 int initial_brightness;
135 unsigned int period_ns; 128 unsigned int period_ns;