* + drivers-video-backlight-l4f00242t03c-prevent-unbalanced-calls-to-regulator-enable-disable.patch added to -mm tree
@ 2010-11-29 21:10 akpm
0 siblings, 0 replies; only message in thread
From: akpm @ 2010-11-29 21:10 UTC (permalink / raw)
To: mm-commits; +Cc: maramaopercheseimorto, axel.lin, marek.vasut, rpurdie, tj
The patch titled
drivers/video/backlight/l4f00242t03.c: prevent unbalanced calls to regulator enable/disable
has been added to the -mm tree. Its filename is
drivers-video-backlight-l4f00242t03c-prevent-unbalanced-calls-to-regulator-enable-disable.patch
Before you just go and hit "reply", please:
a) Consider who else should be cc'ed
b) Prefer to cc a suitable mailing list as well
c) Ideally: find the original patch on the mailing list and do a
reply-to-all to that, adding suitable additional cc's
*** Remember to use Documentation/SubmitChecklist when testing your code ***
See http://userweb.kernel.org/~akpm/stuff/added-to-mm.txt to find
out what to do about this
The current -mm tree may be found at http://userweb.kernel.org/~akpm/mmotm/
------------------------------------------------------
Subject: drivers/video/backlight/l4f00242t03.c: prevent unbalanced calls to regulator enable/disable
From: Alberto Panizzo <maramaopercheseimorto@gmail.com>
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 <maramaopercheseimorto@gmail.com>
Cc: Richard Purdie <rpurdie@rpsys.net>
Cc: Marek Vasut <marek.vasut@gmail.com>
Cc: Tejun Heo <tj@kernel.org>
Cc: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
---
drivers/video/backlight/l4f00242t03.c | 10 ++++++----
1 file changed, 6 insertions(+), 4 deletions(-)
diff -puN drivers/video/backlight/l4f00242t03.c~drivers-video-backlight-l4f00242t03c-prevent-unbalanced-calls-to-regulator-enable-disable drivers/video/backlight/l4f00242t03.c
--- a/drivers/video/backlight/l4f00242t03.c~drivers-video-backlight-l4f00242t03c-prevent-unbalanced-calls-to-regulator-enable-disable
+++ a/drivers/video/backlight/l4f00242t03.c
@@ -134,10 +134,12 @@ static int l4f00242t03_lcd_power_set(str
}
} 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;
_
Patches currently in -mm which might be from maramaopercheseimorto@gmail.com are
origin.patch
linux-next.patch
drivers-video-backlight-l4f00242t03c-full-implement-fb-power-states-for-this-lcd.patch
drivers-video-backlight-l4f00242t03c-prevent-unbalanced-calls-to-regulator-enable-disable.patch
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2010-11-29 21:11 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-11-29 21:10 + drivers-video-backlight-l4f00242t03c-prevent-unbalanced-calls-to-regulator-enable-disable.patch added to -mm tree akpm
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).