disp: msm: sde: fix partial update offset calculation
Panel height and width should be passed for partial update offset calculation. Change passes the offsets to demura partial update function. Change-Id: Ic4113d46e8c1643a855f672e7a2bdd848ef99adc
This commit is contained in:
@@ -1990,6 +1990,8 @@ static int _sde_cp_crtc_update_pu_features(struct drm_crtc *crtc, bool *need_flu
|
||||
hw_cfg.payload = (sde_crtc_state->user_roi_list.num_rects) ?
|
||||
&sde_crtc_state->user_roi_list : NULL;
|
||||
hw_cfg.len = sizeof(sde_crtc_state->user_roi_list);
|
||||
hw_cfg.panel_height = sde_crtc->base.state->adjusted_mode.vdisplay;
|
||||
hw_cfg.panel_width = sde_crtc->base.state->adjusted_mode.hdisplay;
|
||||
for (i = 0; i < hw_cfg.num_of_mixers; i++)
|
||||
hw_cfg.dspp[i] = sde_crtc->mixers[i].hw_dspp;
|
||||
|
||||
@@ -2634,6 +2636,7 @@ void sde_cp_disable_features(struct drm_crtc *crtc)
|
||||
ret = set_feature(hw_dspp, &hw_cfg, sde_crtc);
|
||||
if (ret)
|
||||
break;
|
||||
_sde_cp_dspp_flush_helper(sde_crtc, SDE_CP_CRTC_DSPP_DEMURA_INIT);
|
||||
}
|
||||
mutex_unlock(&sde_crtc->crtc_cp_lock);
|
||||
}
|
||||
|
||||
@@ -3336,6 +3336,7 @@ static void _sde_plane_atomic_disable(struct drm_plane *plane,
|
||||
struct drm_plane_state *state;
|
||||
struct sde_plane_state *pstate;
|
||||
u32 multirect_index = SDE_SSPP_RECT_0;
|
||||
u32 blend_type;
|
||||
|
||||
if (!plane) {
|
||||
SDE_ERROR("invalid plane\n");
|
||||
@@ -3352,6 +3353,14 @@ static void _sde_plane_atomic_disable(struct drm_plane *plane,
|
||||
state = plane->state;
|
||||
pstate = to_sde_plane_state(state);
|
||||
|
||||
blend_type = sde_plane_get_property(pstate,
|
||||
PLANE_PROP_BLEND_OP);
|
||||
/* some of the color features are dependent on plane with skip blend.
|
||||
* if skip blend plane is being disabled, we need to disable color properties.
|
||||
*/
|
||||
if (blend_type == SDE_DRM_BLEND_OP_SKIP && old_state->crtc)
|
||||
sde_crtc_disable_cp_features(old_state->crtc);
|
||||
|
||||
SDE_EVT32(DRMID(plane), is_sde_plane_virtual(plane),
|
||||
pstate->multirect_mode);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user