summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKrishna Chaitanya Parimi <cparimi@codeaurora.org>2015-03-10 09:50:41 -0700
committerDavid Keitel <dkeitel@codeaurora.org>2016-03-23 20:42:34 -0700
commitec458f6feb02620a221bf499987d2ab5b33a82fa (patch)
tree5ce8bc4293f6812703ecef490e2dd3f99ff0f394
parentf954efe13095bca79095360614a9f53d245c9846 (diff)
msm: mdss: initialize AD calibration bl to current bl level
When AD calibration mode is turned ON, an ioctl is sent to set the mode to calibration in driver. However this does not set the calibration mode backlight. So the backlight value would remain 0. If bl is not set during calibration then upon suspend resume the bl will remain as 0 and nothing would appear on display. Now initializing the calibration mode bl level to the bl level when calibration mode was turned on. Change-Id: Iecee61dc69815b673deb8610a524b07c4f4b9261 Signed-off-by: Krishna Chaitanya Parimi <cparimi@codeaurora.org> Signed-off-by: Ping Li <pingli@codeaurora.org>
-rw-r--r--drivers/video/fbdev/msm/mdss_mdp_pp.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/video/fbdev/msm/mdss_mdp_pp.c b/drivers/video/fbdev/msm/mdss_mdp_pp.c
index 90fa5c37dc9b..20031a83bbfa 100644
--- a/drivers/video/fbdev/msm/mdss_mdp_pp.c
+++ b/drivers/video/fbdev/msm/mdss_mdp_pp.c
@@ -5933,6 +5933,9 @@ int mdss_mdp_calib_mode(struct msm_fb_data_type *mfd,
return -EINVAL;
mutex_lock(&mdss_pp_mutex);
mfd->calib_mode = cfg->calib_mask;
+ mutex_lock(&mfd->bl_lock);
+ mfd->calib_mode_bl = mfd->bl_level;
+ mutex_unlock(&mfd->bl_lock);
mutex_unlock(&mdss_pp_mutex);
return 0;
}