1
0

disp: msm: sde: update rc checks for mask configuration

Rounded corner mask layer height/width should match the panel height
and width. Change updates rounded corner mask configuration check
to ensure that dimensons match.

Change-Id: I97f544b0a7df1ebea6d8aa3321813649ebc69d82
Signed-off-by: Gopikrishnaiah Anandan <agopik@codeaurora.org>
Este cometimento está contido em:
Gopikrishnaiah Anandan
2021-08-25 18:35:18 -07:00
ascendente 3a2c526376
cometimento 51de59d06b
2 ficheiros modificados com 11 adições e 1 eliminações

Ver ficheiro

@@ -588,6 +588,13 @@ static int sde_hw_rc_check_mask_cfg(
return -EINVAL;
}
if (hw_cfg->panel_height != rc_mask_cfg->height ||
rc_mask_cfg->width != hw_cfg->panel_width) {
SDE_ERROR("RC mask Layer: h %d w %d panel: h %d w %d mismatch\n",
rc_mask_cfg->height, rc_mask_cfg->width,
hw_cfg->panel_height, hw_cfg->panel_width);
return -EINVAL;
}
flags = rc_mask_cfg->flags;
cfg_param_01 = rc_mask_cfg->cfg_param_01;
cfg_param_02 = rc_mask_cfg->cfg_param_02;
@@ -728,7 +735,8 @@ int sde_hw_rc_check_mask(struct sde_hw_dspp *hw_dspp, void *cfg)
if (hw_cfg->len != sizeof(struct drm_msm_rc_mask_cfg) ||
!hw_cfg->payload) {
SDE_ERROR("invalid payload\n");
SDE_ERROR("invalid payload len %d exp %zd\n", hw_cfg->len,
sizeof(struct drm_msm_rc_mask_cfg));
return -EINVAL;
}