From: yzq Date: Sat, 29 Sep 2012 08:56:39 +0000 (+0800) Subject: fix backlight bug for quick suspend and resume X-Git-Tag: firefly_0821_release~8496 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=37b474ef7fedc0caf3de81862fef0b2e5838e67d;p=firefly-linux-kernel-4.4.55.git fix backlight bug for quick suspend and resume --- diff --git a/drivers/video/backlight/rk29_backlight.c b/drivers/video/backlight/rk29_backlight.c index 596c37e8c6df..f7f4a5a8f20e 100755 --- a/drivers/video/backlight/rk29_backlight.c +++ b/drivers/video/backlight/rk29_backlight.c @@ -152,7 +152,6 @@ static struct backlight_ops rk29_bl_ops = { static void rk29_backlight_work_func(struct work_struct *work) { - suspend_flag = 0; rk29_bl_update_status(rk29_bl); } static DECLARE_DELAYED_WORK(rk29_backlight_work, rk29_backlight_work_func); @@ -190,6 +189,7 @@ static void rk29_bl_resume(struct early_suspend *h) clk_enable(pwm_clk); + suspend_flag = 0; schedule_delayed_work(&rk29_backlight_work, msecs_to_jiffies(rk29_bl_info->delay_ms)); }