projects
/
openwrt
/
staging
/
blogic.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
95558ad
)
drivers/video/backlight/l4f00242t03.c: prevent unbalanced calls to regulator enable...
author
Alberto Panizzo
<
[email protected]
>
Thu, 13 Jan 2011 00:59:23 +0000
(16:59 -0800)
committer
Linus Torvalds
<
[email protected]
>
Thu, 13 Jan 2011 16:03:06 +0000
(08:03 -0800)
Otherwise a double call to:
$ echo 4 > /sys/class/lcd/l4f00242t03/lcd_power
Will, the first power down the lcd and regulators correctly and the
second produce an unbalanced call to regulator disable.
Signed-off-by: Alberto Panizzo <
[email protected]
>
Cc: Richard Purdie <
[email protected]
>
Cc: Marek Vasut <
[email protected]
>
Cc: Tejun Heo <
[email protected]
>
Cc: Axel Lin <
[email protected]
>
Signed-off-by: Andrew Morton <
[email protected]
>
Signed-off-by: Linus Torvalds <
[email protected]
>
drivers/video/backlight/l4f00242t03.c
patch
|
blob
|
history
diff --git
a/drivers/video/backlight/l4f00242t03.c
b/drivers/video/backlight/l4f00242t03.c
index 5d25743bf8e26001d00b2cbd558dd67f7b07468b..1fcaaf3d78e15fe7663762f3280738065603db64 100644
(file)
--- a/
drivers/video/backlight/l4f00242t03.c
+++ b/
drivers/video/backlight/l4f00242t03.c
@@
-134,10
+134,12
@@
static int l4f00242t03_lcd_power_set(struct lcd_device *ld, int power)
}
} else {
/* power == FB_BLANK_POWERDOWN */
- /* Clear the screen before shutting down */
- spi_write(spi, (const u8 *)&disoff, sizeof(u16));
- msleep(60);
- l4f00242t03_lcd_powerdown(spi);
+ if (priv->lcd_state != FB_BLANK_POWERDOWN) {
+ /* Clear the screen before shutting down */
+ spi_write(spi, (const u8 *)&disoff, sizeof(u16));
+ msleep(60);
+ l4f00242t03_lcd_powerdown(spi);
+ }
}
priv->lcd_state = power;