linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] pwm-backlight: Turn off pwm backlight in probe
@ 2014-10-06 19:22 Markus Pargmann
  2014-10-07  8:35 ` Thierry Reding
  0 siblings, 1 reply; 8+ messages in thread
From: Markus Pargmann @ 2014-10-06 19:22 UTC (permalink / raw)
  To: linux-arm-kernel

The backlight will be enabled by the panel again if it is used. So we
can save the default brightness and disable the pwm backlight when
probing.

Signed-off-by: Markus Pargmann <mpa@pengutronix.de>
---
 drivers/video/backlight/pwm_bl.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/drivers/video/backlight/pwm_bl.c b/drivers/video/backlight/pwm_bl.c
index 336b83be7e2d..b4f433a6f106 100644
--- a/drivers/video/backlight/pwm_bl.c
+++ b/drivers/video/backlight/pwm_bl.c
@@ -317,9 +317,11 @@ static int pwm_backlight_probe(struct platform_device *pdev)
 		data->dft_brightness = data->max_brightness;
 	}
 
-	bl->props.brightness = data->dft_brightness;
+	bl->props.brightness = 0;
 	backlight_update_status(bl);
 
+	bl->props.brightness = data->dft_brightness;
+
 	platform_set_drvdata(pdev, bl);
 	return 0;
 
-- 
2.1.0

^ permalink raw reply related	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2014-10-08 12:13 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-10-06 19:22 [PATCH] pwm-backlight: Turn off pwm backlight in probe Markus Pargmann
2014-10-07  8:35 ` Thierry Reding
2014-10-07  9:06   ` Lee Jones
2014-10-07  9:07   ` Markus Pargmann
2014-10-07  9:17     ` Ajay kumar
2014-10-08  9:55       ` Markus Pargmann
2014-10-08  9:44   ` Jingoo Han
2014-10-08 12:13     ` Thierry Reding

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).