drm_ioctl: add return value for set_param

DC mode will not be set properly if sde_kms_set_panel_feature does
not return error value when it fails.

Change-Id: I49d38a22f4c78406085888a07cf71dc056223651
Reviewed-on: https://gerrit.mot.com/2362283
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Guobin Zhang <zhanggb@motorola.com>
Reviewed-by: Dezhen Hou <houdz1@motorola.com>
Submit-Approved: Jira Key
This commit is contained in:
zhanggb 2022-08-13 10:26:23 +08:00 • committed by tongkun1
commit 0620256fb4

View file

@ -3663,6 +3663,7 @@ static int sde_kms_set_panel_feature(const struct msm_kms *kms,
struct sde_kms *sde_kms;
struct dsi_display *display;
struct msm_param_info param_info_msm;
int rc = 0;
if (!kms) {
SDE_ERROR("invalid input args\n");
@ -3673,9 +3674,12 @@ static int sde_kms_set_panel_feature(const struct msm_kms *kms,
param_info_msm.param_idx = (enum msm_param_id)param_info.param_idx;
param_info_msm.value = param_info.value;
display = (struct dsi_display *)sde_kms->dsi_displays[0];
dsi_display_set_param(display, &param_info_msm);
rc = dsi_display_set_param(display, &param_info_msm);
if (rc)
SDE_ERROR("set param %d value %d failed\n",
param_info_msm.param_idx, param_info_msm.value);
return 0;
return rc;
}
static void _sde_kms_null_commit(struct drm_device *dev,