Skip to content

Commit 7678e08

Browse files
committed
drm/i915/dsb: Evade transcoder undelayed vblank when using DSB
We want to start the DSB execution from the transcoder's undelayed vblank, so in order to guarantee atomicity with the all the other mmio register writes we need to evade both vblanks. Note that currently we don't add any vblank delay, so this is effectively a nop. But in the future when we start to program double buffered registers from the DSB we'll need to delay the pipe's vblank to provide the register programming "window2" for the DSB. Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com> Link: https://patchwork.freedesktop.org/patch/msgid/20230606191504.18099-15-ville.syrjala@linux.intel.com Reviewed-by: Uma Shankar <uma.shankar@intel.com>
1 parent 25ea341 commit 7678e08

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

drivers/gpu/drm/i915/display/intel_crtc.c

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -516,8 +516,11 @@ static void intel_crtc_vblank_evade_scanlines(struct intel_atomic_state *state,
516516
* M/N and TRANS_VTOTAL are double buffered on the transcoder's
517517
* undelayed vblank, so with seamless M/N and LRR we must evade
518518
* both vblanks.
519+
*
520+
* DSB execution waits for the transcoder's undelayed vblank,
521+
* hence we must kick off the commit before that.
519522
*/
520-
if (new_crtc_state->update_m_n || new_crtc_state->update_lrr)
523+
if (new_crtc_state->dsb || new_crtc_state->update_m_n || new_crtc_state->update_lrr)
521524
*min -= adjusted_mode->crtc_vblank_start - adjusted_mode->crtc_vdisplay;
522525
}
523526

0 commit comments

Comments
 (0)