msm: mdss: do not skip pipe programming if roi changed
Current driver has an optimization where if pipe parameters are not changed between consecutive updates then it will skip pipe's HW register programming. However when partial update is enabled and ROI is changed compared to previous update, pipe's HW programming should not be skipped because HW is programmed with stale ROI for that given pipe. Fix this by forcing pipe HW programming update if ROI is changed. Change-Id: Iebff043ecbb35b22ffbe344bdffa830602437252 Signed-off-by: Ujwal Patel <ujwalp@codeaurora.org>
This commit is contained in:
parent
6489c0aef1
commit
8df91abd3e
2 changed files with 27 additions and 2 deletions
|
@ -750,6 +750,26 @@ enum mdss_mdp_clt_intf_event_flags {
|
|||
#define mfd_to_wb(mfd) (((struct mdss_overlay_private *)\
|
||||
(mfd->mdp.private1))->wb)
|
||||
|
||||
/**
|
||||
* - mdss_mdp_is_roi_changed
|
||||
* @mfd - pointer to mfd
|
||||
*
|
||||
* Function returns true if roi is changed for any layer mixer of a given
|
||||
* display, false otherwise.
|
||||
*/
|
||||
static inline bool mdss_mdp_is_roi_changed(struct msm_fb_data_type *mfd)
|
||||
{
|
||||
struct mdss_mdp_ctl *ctl;
|
||||
|
||||
if (!mfd)
|
||||
return false;
|
||||
|
||||
ctl = mfd_to_ctl(mfd); /* returns master ctl */
|
||||
|
||||
return ctl->mixer_left->roi_changed ||
|
||||
(is_split_lm(mfd) ? ctl->mixer_right->roi_changed : false);
|
||||
}
|
||||
|
||||
/**
|
||||
* - mdss_mdp_is_both_lm_valid
|
||||
* @main_ctl - pointer to a main ctl
|
||||
|
|
|
@ -1516,8 +1516,13 @@ static int __overlay_queue_pipes(struct msm_fb_data_type *mfd)
|
|||
if (buf && (buf->state == MDP_BUF_STATE_READY)) {
|
||||
buf->state = MDP_BUF_STATE_ACTIVE;
|
||||
ret = mdss_mdp_data_map(buf, false, DMA_TO_DEVICE);
|
||||
} else if (!pipe->params_changed) {
|
||||
/* nothing to update so continue with next */
|
||||
} else if (!pipe->params_changed &&
|
||||
!mdss_mdp_is_roi_changed(pipe->mfd)) {
|
||||
|
||||
/*
|
||||
* no update for the given pipe nor any change in the
|
||||
* ROI so skip pipe programming and continue with next.
|
||||
*/
|
||||
continue;
|
||||
} else if (buf) {
|
||||
BUG_ON(buf->state != MDP_BUF_STATE_ACTIVE);
|
||||
|
|
Loading…
Add table
Reference in a new issue