mirror of
https://github.com/followmsi/android_kernel_google_msm.git
synced 2024-11-06 23:17:41 +00:00
msm_fb: display: alloc/free writeback buffer done at do_blt()
To avoid double freeing writeback at end of blt mode, let both alloc and free writeback buffer done at do_blt(). Change-Id: Ida5d24589c19be8f6f655eca6add00badca356b2 Signed-off-by: Kuogee Hsieh <khsieh@codeaurora.org> Signed-off-by: Siddhartha Agrawal <agrawals@codeaurora.org> Signed-off-by: Ajay Dudani <adudani@codeaurora.org>
This commit is contained in:
parent
de46e23776
commit
523352899a
2 changed files with 3 additions and 4 deletions
|
@ -2738,7 +2738,6 @@ void mdp4_overlay_mdp_perf_upd(struct msm_fb_data_type *mfd,
|
||||||
}
|
}
|
||||||
if (mfd->panel_info.pdest == DISPLAY_1 &&
|
if (mfd->panel_info.pdest == DISPLAY_1 &&
|
||||||
perf_req->use_ov0_blt && !perf_cur->use_ov0_blt) {
|
perf_req->use_ov0_blt && !perf_cur->use_ov0_blt) {
|
||||||
mdp4_allocate_writeback_buf(mfd, MDP4_MIXER0);
|
|
||||||
if (mfd->panel_info.type == LCDC_PANEL ||
|
if (mfd->panel_info.type == LCDC_PANEL ||
|
||||||
mfd->panel_info.type == LVDS_PANEL)
|
mfd->panel_info.type == LVDS_PANEL)
|
||||||
mdp4_lcdc_overlay_blt_start(mfd);
|
mdp4_lcdc_overlay_blt_start(mfd);
|
||||||
|
@ -2755,7 +2754,6 @@ void mdp4_overlay_mdp_perf_upd(struct msm_fb_data_type *mfd,
|
||||||
}
|
}
|
||||||
if (mfd->panel_info.pdest == DISPLAY_2 &&
|
if (mfd->panel_info.pdest == DISPLAY_2 &&
|
||||||
perf_req->use_ov1_blt && !perf_cur->use_ov1_blt) {
|
perf_req->use_ov1_blt && !perf_cur->use_ov1_blt) {
|
||||||
mdp4_allocate_writeback_buf(mfd, MDP4_MIXER1);
|
|
||||||
mdp4_dtv_overlay_blt_start(mfd);
|
mdp4_dtv_overlay_blt_start(mfd);
|
||||||
pr_info("%s mixer1 start blt [%d] from %d to %d.\n",
|
pr_info("%s mixer1 start blt [%d] from %d to %d.\n",
|
||||||
__func__,
|
__func__,
|
||||||
|
@ -2795,7 +2793,6 @@ void mdp4_overlay_mdp_perf_upd(struct msm_fb_data_type *mfd,
|
||||||
mdp4_dsi_video_blt_stop(mfd);
|
mdp4_dsi_video_blt_stop(mfd);
|
||||||
else if (ctrl->panel_mode & MDP4_PANEL_DSI_CMD)
|
else if (ctrl->panel_mode & MDP4_PANEL_DSI_CMD)
|
||||||
mdp4_dsi_cmd_blt_stop(mfd);
|
mdp4_dsi_cmd_blt_stop(mfd);
|
||||||
mdp4_free_writeback_buf(mfd, MDP4_MIXER0);
|
|
||||||
pr_info("%s mixer0 stop blt [%d] from %d to %d.\n",
|
pr_info("%s mixer0 stop blt [%d] from %d to %d.\n",
|
||||||
__func__,
|
__func__,
|
||||||
flag,
|
flag,
|
||||||
|
@ -2806,7 +2803,6 @@ void mdp4_overlay_mdp_perf_upd(struct msm_fb_data_type *mfd,
|
||||||
if (mfd->panel_info.pdest == DISPLAY_2 &&
|
if (mfd->panel_info.pdest == DISPLAY_2 &&
|
||||||
!perf_req->use_ov1_blt && perf_cur->use_ov1_blt) {
|
!perf_req->use_ov1_blt && perf_cur->use_ov1_blt) {
|
||||||
mdp4_dtv_overlay_blt_stop(mfd);
|
mdp4_dtv_overlay_blt_stop(mfd);
|
||||||
mdp4_free_writeback_buf(mfd, MDP4_MIXER1);
|
|
||||||
pr_info("%s mixer1 stop blt [%d] from %d to %d.\n",
|
pr_info("%s mixer1 stop blt [%d] from %d to %d.\n",
|
||||||
__func__,
|
__func__,
|
||||||
flag,
|
flag,
|
||||||
|
|
|
@ -933,6 +933,8 @@ static void mdp4_dsi_video_do_blt(struct msm_fb_data_type *mfd, int enable)
|
||||||
vctrl = &vsync_ctrl_db[cndx];
|
vctrl = &vsync_ctrl_db[cndx];
|
||||||
pipe = vctrl->base_pipe;
|
pipe = vctrl->base_pipe;
|
||||||
|
|
||||||
|
mdp4_allocate_writeback_buf(mfd, MDP4_MIXER0);
|
||||||
|
|
||||||
if (mfd->ov0_wb_buf->write_addr == 0) {
|
if (mfd->ov0_wb_buf->write_addr == 0) {
|
||||||
pr_info("%s: no blt_base assigned\n", __func__);
|
pr_info("%s: no blt_base assigned\n", __func__);
|
||||||
return;
|
return;
|
||||||
|
@ -1015,6 +1017,7 @@ void mdp4_dsi_video_overlay(struct msm_fb_data_type *mfd)
|
||||||
}
|
}
|
||||||
|
|
||||||
mdp4_overlay_mdp_perf_upd(mfd, 1);
|
mdp4_overlay_mdp_perf_upd(mfd, 1);
|
||||||
|
|
||||||
mutex_lock(&mfd->dma->ov_mutex);
|
mutex_lock(&mfd->dma->ov_mutex);
|
||||||
mdp4_dsi_video_pipe_commit();
|
mdp4_dsi_video_pipe_commit();
|
||||||
mutex_unlock(&mfd->dma->ov_mutex);
|
mutex_unlock(&mfd->dma->ov_mutex);
|
||||||
|
|
Loading…
Reference in a new issue