Intel-GFX Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v3] drm/i915/panelreplay: Panel replay workaround with VRR
@ 2024-02-20 14:19 Animesh Manna
  2024-02-20 15:29 ` ✓ Fi.CI.BAT: success for drm/i915/panelreplay: Panel replay workaround with VRR (rev3) Patchwork
                   ` (2 more replies)
  0 siblings, 3 replies; 9+ messages in thread
From: Animesh Manna @ 2024-02-20 14:19 UTC (permalink / raw)
  To: intel-gfx; +Cc: ville.syrjala, jouni.hogander, arun.r.murthy, Animesh Manna

Panel Replay VSC SDP not getting sent when VRR is enabled
and W1 and W2 are 0. So Program Set Context Latency in
TRANS_SET_CONTEXT_LATENCY register to at least a value of 1.

HSD: 14015406119

v1: Initial version.
v2: Update timings stored in adjusted_mode struct. [Ville]
v3: Add WA in compute_config(). [Ville]

Signed-off-by: Animesh Manna <animesh.manna@intel.com>
---
 drivers/gpu/drm/i915/display/intel_dp.c | 12 ++++++++++++
 1 file changed, 12 insertions(+)

diff --git a/drivers/gpu/drm/i915/display/intel_dp.c b/drivers/gpu/drm/i915/display/intel_dp.c
index 217196196e50..eb0fa513cd0f 100644
--- a/drivers/gpu/drm/i915/display/intel_dp.c
+++ b/drivers/gpu/drm/i915/display/intel_dp.c
@@ -2948,6 +2948,18 @@ intel_dp_compute_config(struct intel_encoder *encoder,
 	intel_dp_compute_vsc_sdp(intel_dp, pipe_config, conn_state);
 	intel_dp_compute_hdr_metadata_infoframe_sdp(intel_dp, pipe_config, conn_state);
 
+	/*
+	 * WA: HSD-14015406119
+	 * Program Set Context Latency in TRANS_SET_CONTEXT_LATENCY register
+	 * to at least a value of 1 when Panel Replay is enabled with VRR.
+	 * Value for TRANS_SET_CONTEXT_LATENCY is calculated by substracting
+	 * crtc_vdisplay from crtc_vblank_start, so incrementing crtc_vblank_start
+	 * by 1 if both are equal.
+	 */
+	if (pipe_config->vrr.enable && pipe_config->has_panel_replay &&
+	    adjusted_mode->crtc_vblank_start == adjusted_mode->crtc_vdisplay)
+		adjusted_mode->crtc_vblank_start += 1;
+
 	return 0;
 }
 
-- 
2.29.0


^ permalink raw reply related	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2024-03-28  5:46 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-02-20 14:19 [PATCH v3] drm/i915/panelreplay: Panel replay workaround with VRR Animesh Manna
2024-02-20 15:29 ` ✓ Fi.CI.BAT: success for drm/i915/panelreplay: Panel replay workaround with VRR (rev3) Patchwork
2024-02-20 16:36 ` ✓ Fi.CI.IGT: " Patchwork
2024-02-20 17:41 ` [PATCH v3] drm/i915/panelreplay: Panel replay workaround with VRR Rodrigo Vivi
2024-02-21 20:19   ` Manna, Animesh
2024-02-21 20:58     ` Rodrigo Vivi
2024-02-21 21:08       ` Ville Syrjälä
2024-02-21 21:24         ` Ville Syrjälä
2024-03-28  5:46           ` Manna, Animesh

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox