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

Commit a6679cf9 authored by Xiaowen Wu's avatar Xiaowen Wu Committed by Gerrit - the friendly Code Review server
Browse files

disp: msm: dp: fix dp-mst stream double disabled issue



There is a corner case when dp-mst stream is disabled twice:

1. stream 1 is enabled
2. cable plugged out, stream 1 is disabled by kernel
3. cable plugged in, enable stream 0 first
4. disable stream 1

Stream 1 is double disabled and will cause hw crash. This change
will add the check and skip stream_off if already disabled.

Change-Id: Icd1e815a1ed14cd4e784924f3db19b98eb06d571
Signed-off-by: default avatarXiaowen Wu <wxiaowen@codeaurora.org>
Signed-off-by: default avatarSankeerth Billakanti <sbillaka@codeaurora.org>
parent 3c3bfb63
Loading
Loading
Loading
Loading
+6 −0
Original line number Diff line number Diff line
@@ -1167,6 +1167,12 @@ static void dp_display_stream_disable(struct dp_display_private *dp,
		return;
	}

	if (dp_panel->stream_id == DP_STREAM_MAX ||
			!dp->active_panels[dp_panel->stream_id]) {
		DP_ERR("panel is already disabled\n");
		return;
	}

	DP_DEBUG("stream_id=%d, active_stream_cnt=%d\n",
			dp_panel->stream_id, dp->active_stream_cnt);