diff options
| author | Adrian Salido-Moreno <adrianm@codeaurora.org> | 2013-10-10 14:30:10 -0700 |
|---|---|---|
| committer | David Keitel <dkeitel@codeaurora.org> | 2016-03-23 20:22:32 -0700 |
| commit | 762416ffbf8451e8fac1f71ee1ad0bd98a2538e4 (patch) | |
| tree | 03d00b2aa4d28fb4213049e019ac8ab1eaa1aa29 | |
| parent | 13a6375739c29e1767fbc6a2ead7372ad9d2b256 (diff) | |
msm: mdss: unregister command mode vsync handlers on stop
When command mode panel is being stopped, any vsync handlers that are
still pending should be removed before shutdown sequence. If this is
done afterwards VSYNC_TICKS update may cause the clock to continue
running after clocks have been shutdown and may lead to MDP hang.
Change-Id: I149390413326b21ddf608e7fe5a31b3a57abe50b
Signed-off-by: Adrian Salido-Moreno <adrianm@codeaurora.org>
| -rw-r--r-- | drivers/video/fbdev/msm/mdss_mdp_intf_cmd.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/drivers/video/fbdev/msm/mdss_mdp_intf_cmd.c b/drivers/video/fbdev/msm/mdss_mdp_intf_cmd.c index 8b4d753a7981..083af54a386a 100644 --- a/drivers/video/fbdev/msm/mdss_mdp_intf_cmd.c +++ b/drivers/video/fbdev/msm/mdss_mdp_intf_cmd.c @@ -506,6 +506,10 @@ int mdss_mdp_cmd_stop(struct mdss_mdp_ctl *ctl) pr_err("invalid ctx\n"); return -ENODEV; } + + list_for_each_entry_safe(handle, tmp, &ctx->vsync_handlers, list) + mdss_mdp_cmd_remove_vsync_handler(ctl, handle); + spin_lock_irqsave(&ctx->clk_lock, flags); if (ctx->rdptr_enabled) { INIT_COMPLETION(ctx->stop_comp); @@ -525,9 +529,6 @@ int mdss_mdp_cmd_stop(struct mdss_mdp_ctl *ctl) ctx->panel_on = 0; - list_for_each_entry_safe(handle, tmp, &ctx->vsync_handlers, list) - mdss_mdp_cmd_remove_vsync_handler(ctl, handle); - mdss_mdp_set_intr_callback(MDSS_MDP_IRQ_PING_PONG_RD_PTR, ctx->pp_num, NULL, NULL); mdss_mdp_set_intr_callback(MDSS_MDP_IRQ_PING_PONG_COMP, ctx->pp_num, |
