diff options
| author | Krishna Manikandan <mkrishn@codeaurora.org> | 2017-12-15 14:32:07 +0530 |
|---|---|---|
| committer | Krishna Manikandan <mkrishn@codeaurora.org> | 2017-12-15 14:49:50 +0530 |
| commit | 4dab8ddb3cccaf872a44c67d8b42875f00c9c5e5 (patch) | |
| tree | 6997707a51a762b503d8bf7180f95a9c9a821310 | |
| parent | db87e2310e4eead66d2c29a4d51ec5946dddf0dc (diff) | |
msm: mdss: Trigger idle fallback when no update due to touch
Trigger an idle fallback with a reasonable timeout value when
there is no update despite of a touch event and idle_time is 0.
This will reset the refresh rate to minimum fps.
CRs-Fixed: 2003247
Change-Id: I4a2964038f23984bf1ea39c63bf679d80ad12cba
Signed-off-by: Krishna Manikandan <mkrishn@codeaurora.org>
| -rw-r--r-- | drivers/video/fbdev/msm/mdss_mdp_intf_video.c | 15 |
1 files changed, 13 insertions, 2 deletions
diff --git a/drivers/video/fbdev/msm/mdss_mdp_intf_video.c b/drivers/video/fbdev/msm/mdss_mdp_intf_video.c index bdf6705ef597..335614a33aaf 100644 --- a/drivers/video/fbdev/msm/mdss_mdp_intf_video.c +++ b/drivers/video/fbdev/msm/mdss_mdp_intf_video.c @@ -2458,10 +2458,21 @@ static int mdss_mdp_video_early_wake_up(struct mdss_mdp_ctl *ctl) * lot of latency rendering the input events useless in preventing the * idle time out. */ - if (ctl->mfd->idle_state == MDSS_FB_IDLE_TIMER_RUNNING) { - if (ctl->mfd->idle_time) + if ((ctl->mfd->idle_state == MDSS_FB_IDLE_TIMER_RUNNING) || + (ctl->mfd->idle_state == MDSS_FB_IDLE)) { + /* + * Modify the idle time so that an idle fallback can be + * triggered for those cases, where we have no update + * despite of a touch event and idle time is 0. + */ + if (!ctl->mfd->idle_time) { + ctl->mfd->idle_time = 70; + schedule_delayed_work(&ctl->mfd->idle_notify_work, + msecs_to_jiffies(200)); + } else { mod_delayed_work(system_wq, &ctl->mfd->idle_notify_work, msecs_to_jiffies(ctl->mfd->idle_time)); + } pr_debug("Delayed idle time\n"); } else { pr_debug("Nothing to done for this state (%d)\n", |
