disp: msm: Fixing motUtil tool for ACL feature

- Mot's panel param feature is working with sending single MIPI DSI
command, but it doesn't work correct with sending more than one MIPI
DSI commands
- Enable ACL support to enable or disable ACL feature with the MotUtil
tool. This tool is designed to validate the MOT display DRM Framework.

Change-Id: I211818d9c2b2c8a736f4dfc1768c78357383c531
Signed-off-by: Bang Nguyen <bangnguyen@motorola.com>
Reviewed-on: https://gerrit.mot.com/1697631
SME-Granted: SME Approvals Granted
SLTApproved: Slta Waiver
Tested-by: Jira Key
Reviewed-by: Guobin Zhang <zhanggb@motorola.com>
Submit-Approved: Jira Key
This commit is contained in:
Bang Nguyen 2020-01-16 10:58:31 -06:00 • committed by tongkun1
commit d93b18f00e
2 changed files with 19 additions and 14 deletions

View file

@ -759,14 +759,15 @@ static int dsi_panel_pwm_register(struct dsi_panel *panel)
static int dsi_panel_send_param_cmd(struct dsi_panel *panel,
struct msm_param_info *param_info)
{
int rc = 0;
int rc = 0, i = 0;
struct panel_param_val_map *param_map;
struct panel_param_val_map *param_map_state;
struct panel_param *panel_param;
struct dsi_cmd_desc *cmds;
ssize_t len;
const struct mipi_dsi_host_ops *ops = panel->host->ops;
u32 count;
const struct mipi_dsi_host_ops *ops = panel->host->ops;
panel_param = &panel->param_cmds[param_info->param_idx];
if (!panel_param) {
DSI_ERR("%s: invalid panel_param.\n", __func__);
@ -802,17 +803,22 @@ static int dsi_panel_send_param_cmd(struct dsi_panel *panel,
}
cmds = param_map_state->cmds->cmds;
if (param_map_state->cmds->state == DSI_CMD_SET_STATE_LP)
cmds->msg.flags |= MIPI_DSI_MSG_USE_LPM |
MIPI_DSI_MSG_LASTCOMMAND;
len = ops->transfer(panel->host, &cmds->msg);
if (len < 0) {
rc = len;
DSI_ERR("%s:failed to send param cmd, rc=%d\n",
__func__, rc);
goto end;
}
count = param_map_state->cmds->count;
for (i =0; i < count; i++) {
if (param_map_state->cmds->state == DSI_CMD_SET_STATE_LP)
cmds->msg.flags |= MIPI_DSI_MSG_USE_LPM;
if (cmds->last_command)
cmds->msg.flags |= MIPI_DSI_MSG_LASTCOMMAND;
len = ops->transfer(panel->host, &cmds->msg);
if (len < 0) {
rc = len;
DSI_ERR("%s:failed to send param cmd, rc=%d\n",
__func__, rc);
goto end;
}
cmds++;
}
panel_param->value = param_info->value;
DSI_INFO("(%d) is setting new value %d\n",
param_info->param_idx, param_info->value);

View file

@ -214,10 +214,9 @@ static int _sde_debugfs_motUtil_kms_prop_test(struct sde_kms *kms,
case KMSPROPTEST_TYPE_HBM:
conn_prop_idx = CONNECTOR_PROP_HBM;
break;
/* case KMSPROPTEST_TYPE_ACL:
case KMSPROPTEST_TYPE_ACL:
conn_prop_idx = CONNECTOR_PROP_ACL;
break;
*/
default:
DRM_ERROR(" Invalid KMSPROPTEST_PROP_INDEX = %d\n",
input[KMSPROPTEST_PROP_INDEX]);