[PATCH 2/3] Use gpio_set_value_cansleep() in corgi_lcd.c
Eric Miao
eric.y.miao at gmail.com
Mon Apr 4 06:45:46 EDT 2011
Personally, I don't quite like the idea of an explicit _cansleep() version,
which is just confusing. A programmer shouldn't be aware of which
version to use.
David, you have any justification?
On Sat, Apr 2, 2011 at 9:43 AM, Marek Vasut <marek.vasut at gmail.com> wrote:
> Signed-off-by: Marek Vasut <marek.vasut at gmail.com>
> ---
> drivers/video/backlight/corgi_lcd.c | 4 ++--
> 1 files changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/video/backlight/corgi_lcd.c b/drivers/video/backlight/corgi_lcd.c
> index 1e71c35..8c80cb7 100644
> --- a/drivers/video/backlight/corgi_lcd.c
> +++ b/drivers/video/backlight/corgi_lcd.c
> @@ -409,10 +409,10 @@ static int corgi_bl_set_intensity(struct corgi_lcd *lcd, int intensity)
> cont = !!(intensity & 0x20) ^ lcd->gpio_backlight_cont_inverted;
>
> if (gpio_is_valid(lcd->gpio_backlight_cont))
> - gpio_set_value(lcd->gpio_backlight_cont, cont);
> + gpio_set_value_cansleep(lcd->gpio_backlight_cont, cont);
>
> if (gpio_is_valid(lcd->gpio_backlight_on))
> - gpio_set_value(lcd->gpio_backlight_on, intensity);
> + gpio_set_value_cansleep(lcd->gpio_backlight_on, intensity);
>
> if (lcd->kick_battery)
> lcd->kick_battery();
> --
> 1.7.4.1
>
>
More information about the linux-arm-kernel
mailing list