diff options
author | Thierry Reding <treding@nvidia.com> | 2013-08-30 06:19:52 -0400 |
---|---|---|
committer | Thierry Reding <thierry.reding@gmail.com> | 2013-10-16 03:05:57 -0400 |
commit | a63652f1a7b5b04545bfe0ebc9e54f32bde05caf (patch) | |
tree | 69822de3fbb36f603af2d8c0c0e371decd0c94dd /arch/arm/plat-samsung | |
parent | db01120c5f6cb1d8c6533a49b009f08a73852498 (diff) |
ARM: SAMSUNG: Initialize PWM backlight enable_gpio field
The GPIO API defines 0 as being a valid GPIO number, so this field needs
to be initialized explicitly.
Signed-off-by: Thierry Reding <treding@nvidia.com>
Diffstat (limited to 'arch/arm/plat-samsung')
-rw-r--r-- | arch/arm/plat-samsung/dev-backlight.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/arch/arm/plat-samsung/dev-backlight.c b/arch/arm/plat-samsung/dev-backlight.c index d51f9565567c..be4ad0b21c08 100644 --- a/arch/arm/plat-samsung/dev-backlight.c +++ b/arch/arm/plat-samsung/dev-backlight.c | |||
@@ -70,6 +70,7 @@ static struct samsung_bl_drvdata samsung_dfl_bl_data __initdata = { | |||
70 | .max_brightness = 255, | 70 | .max_brightness = 255, |
71 | .dft_brightness = 255, | 71 | .dft_brightness = 255, |
72 | .pwm_period_ns = 78770, | 72 | .pwm_period_ns = 78770, |
73 | .enable_gpio = -1, | ||
73 | .init = samsung_bl_init, | 74 | .init = samsung_bl_init, |
74 | .exit = samsung_bl_exit, | 75 | .exit = samsung_bl_exit, |
75 | }, | 76 | }, |
@@ -121,6 +122,10 @@ void __init samsung_bl_set(struct samsung_bl_gpio_info *gpio_info, | |||
121 | samsung_bl_data->lth_brightness = bl_data->lth_brightness; | 122 | samsung_bl_data->lth_brightness = bl_data->lth_brightness; |
122 | if (bl_data->pwm_period_ns) | 123 | if (bl_data->pwm_period_ns) |
123 | samsung_bl_data->pwm_period_ns = bl_data->pwm_period_ns; | 124 | samsung_bl_data->pwm_period_ns = bl_data->pwm_period_ns; |
125 | if (bl_data->enable_gpio >= 0) | ||
126 | samsung_bl_data->enable_gpio = bl_data->enable_gpio; | ||
127 | if (bl_data->enable_gpio_flags) | ||
128 | samsung_bl_data->enable_gpio_flags = bl_data->enable_gpio_flags; | ||
124 | if (bl_data->init) | 129 | if (bl_data->init) |
125 | samsung_bl_data->init = bl_data->init; | 130 | samsung_bl_data->init = bl_data->init; |
126 | if (bl_data->notify) | 131 | if (bl_data->notify) |