Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 3f18bbc2 authored by Linux Build Service Account's avatar Linux Build Service Account Committed by Gerrit - the friendly Code Review server
Browse files

Merge "drm/msm/dsi-staging: fix dsi read for generic read commands"

parents 46cbd43a bef98fab
Loading
Loading
Loading
Loading
+7 −2
Original line number Diff line number Diff line
/*
 * Copyright (c) 2016-2018, The Linux Foundation. All rights reserved.
 * Copyright (c) 2016-2019, The Linux Foundation. All rights reserved.
 *
 * This program is free software; you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 2 and
@@ -891,6 +891,7 @@ static int dsi_ctrl_copy_and_pad_cmd(struct dsi_ctrl *dsi_ctrl,
	int rc = 0;
	u8 *buf = NULL;
	u32 len, i;
	u8 cmd_type = 0;

	len = packet->size;
	len += 0x3; len &= ~0x03; /* Align to 32 bits */
@@ -913,7 +914,11 @@ static int dsi_ctrl_copy_and_pad_cmd(struct dsi_ctrl *dsi_ctrl,


	/* send embedded BTA for read commands */
	if ((buf[2] & 0x3f) == MIPI_DSI_DCS_READ)
	cmd_type = buf[2] & 0x3f;
	if ((cmd_type == MIPI_DSI_DCS_READ) ||
	    (cmd_type == MIPI_DSI_GENERIC_READ_REQUEST_0_PARAM) ||
	    (cmd_type == MIPI_DSI_GENERIC_READ_REQUEST_1_PARAM) ||
	    (cmd_type == MIPI_DSI_GENERIC_READ_REQUEST_2_PARAM))
		buf[3] |= BIT(5);

	*buffer = buf;