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

Commit 9cb4975b authored by Shashank Babu Chinta Venkata's avatar Shashank Babu Chinta Venkata Committed by Gerrit - the friendly Code Review server
Browse files

drm/msm/dsi-staging: handle DSI command transfer during suspend



When a DSI command transfer is initiated from debugfs interface,
current error log does not give out adequate information. Handle
this scenario and modify logging appropriately.

Change-Id: I5c61d9ce5559631948ce91482644941aaf481349
Signed-off-by: default avatarShashank Babu Chinta Venkata <sbchin@codeaurora.org>
Signed-off-by: default avatarAbhijith Desai <desaia@codeaurora.org>
parent 9b145944
Loading
Loading
Loading
Loading
+11 −0
Original line number Diff line number Diff line
@@ -919,6 +919,17 @@ int dsi_display_cmd_transfer(struct drm_connector *connector,

	mutex_lock(&dsi_display->display_lock);
	rc = dsi_display_ctrl_get_host_init_state(dsi_display, &state);

	/**
	 * Handle scenario where a command transfer is initiated through
	 * sysfs interface when device is in suepnd state.
	 */
	if (!rc && !state) {
		pr_warn_ratelimited("Command xfer attempted while device is in suspend state\n"
				);
		rc = -EPERM;
		goto end;
	}
	if (rc || !state) {
		pr_err("[DSI] Invalid host state %d rc %d\n",
				state, rc);