[V3,5/8] drm/i915/dsi: Use private flags to indicate TE in cmd mode
diff mbox series

Message ID 20191119123316.5094-6-vandita.kulkarni@intel.com
State New
Headers show
Series
  • Add support for mipi dsi cmd mode
Related show

Commit Message

Kulkarni, Vandita Nov. 19, 2019, 12:33 p.m. UTC
On dsi cmd mode we do not receive vblanks instead
we would get TE and these flags indicate TE is expected on
which port.

Signed-off-by: Vandita Kulkarni <vandita.kulkarni@intel.com>
---
 drivers/gpu/drm/i915/display/icl_dsi.c | 15 +++++++++++++++
 1 file changed, 15 insertions(+)

Patch
diff mbox series

diff --git a/drivers/gpu/drm/i915/display/icl_dsi.c b/drivers/gpu/drm/i915/display/icl_dsi.c
index 5bbaac5980ca..8db3a0f48c39 100644
--- a/drivers/gpu/drm/i915/display/icl_dsi.c
+++ b/drivers/gpu/drm/i915/display/icl_dsi.c
@@ -1376,6 +1376,21 @@  static int gen11_dsi_compute_config(struct intel_encoder *encoder,
 	/* We would not opereate in peridoc command mode */
 	pipe_config->hw.adjusted_mode.private_flags &=
 					~I915_MODE_FLAG_DSI_PERIODIC_CMD_MODE;
+
+	/*
+	 * In case of TE GATE cmd mode, we
+	 * receive TE from the slave if
+	 * dual link is enabled
+	 */
+	if (is_cmd_mode(intel_dsi)) {
+		if (intel_dsi->ports == BIT(PORT_B))
+			pipe_config->hw.adjusted_mode.private_flags |=
+						I915_MODE_FLAG_DSI_USE_TE1;
+		else
+			pipe_config->hw.adjusted_mode.private_flags |=
+						I915_MODE_FLAG_DSI_USE_TE0;
+	}
+
 	return 0;
 }