From c804b76b122a10baccb20ff31797cc47bfdf741d Mon Sep 17 00:00:00 2001 From: xxx Date: Fri, 1 Feb 2013 17:41:21 +0800 Subject: [PATCH] if brightness is set 0,thebrightness real set is 0 not min --- drivers/video/backlight/rk29_backlight.c | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/drivers/video/backlight/rk29_backlight.c b/drivers/video/backlight/rk29_backlight.c index d2e2e741d3ca..fb49a4853754 100755 --- a/drivers/video/backlight/rk29_backlight.c +++ b/drivers/video/backlight/rk29_backlight.c @@ -158,11 +158,13 @@ static int rk29_bl_update_status(struct backlight_device *bl) brightness = bl->props.brightness; - - if(rk29_bl_info->brightness_mode==BRIGHTNESS_MODE_LINE) - brightness=rk29_bl_val_scalor_line(rk29_bl_info,brightness); - else - brightness=rk29_bl_val_scalor_conic(rk29_bl_info,brightness); + if(brightness) + { + if(rk29_bl_info->brightness_mode==BRIGHTNESS_MODE_LINE) + brightness=rk29_bl_val_scalor_line(rk29_bl_info,brightness); + else + brightness=rk29_bl_val_scalor_conic(rk29_bl_info,brightness); + } //printk("%s,req brightness=%d,real is=%d\n",__FUNCTION__,bl->props.brightness,brightness); if (bl->props.power != FB_BLANK_UNBLANK) -- 2.34.1