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

Commit 0fe16840 authored by Vara Reddy's avatar Vara Reddy
Browse files

drm/msm/dsi-staging: fix cmd engine ref count logic



Fix command engine ref count logic which is not decremented
correctly after the command was sent successfully.

Change-Id: I6c6aaedf85bc8eb9f1d05aa657a5f3104f4e5fec
Signed-off-by: default avatarVara Reddy <varar@codeaurora.org>
parent 5915565f
Loading
Loading
Loading
Loading
+6 −6
Original line number Diff line number Diff line
@@ -1371,21 +1371,21 @@ static ssize_t dsi_host_transfer(struct mipi_dsi_host *host,
			goto error_disable_cmd_engine;
		}
	}
	return rc;

put_iova:
	msm_gem_put_iova(display->tx_cmd_buf, 0);
free_gem:
	msm_gem_free_object(display->tx_cmd_buf);
error_disable_cmd_engine:
	(void)dsi_display_cmd_engine_disable(display);
error_disable_clks:
	rc = dsi_display_clk_ctrl(display->dsi_clk_handle,
			DSI_ALL_CLKS, DSI_CLK_OFF);
	if (rc) {
		pr_err("[%s] failed to enable all DSI clocks, rc=%d\n",
		pr_err("[%s] failed to disable all DSI clocks, rc=%d\n",
		       display->name, rc);
	}
	return rc;
put_iova:
	msm_gem_put_iova(display->tx_cmd_buf, 0);
free_gem:
	msm_gem_free_object(display->tx_cmd_buf);
error:
	return rc;
}