Add a workaround to fix BS jitter issues on MST links if the HBLANK
period is less than 1 MTP. The WA applies only to UHBR rates while on
non-UHBR the specification requires disabling it explicitly - presumedly
because the register's reset value has the WA enabled.
Bspec: 50050, 55424
Reviewed-by: Ankit Nautiyal <ankit.k.nautiyal@intel.com>
Signed-off-by: Imre Deak <imre.deak@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20240129175533.904590-3-imre.deak@intel.com
 
        if (crtc_state->fec_enable || intel_dp_is_uhbr(crtc_state))
                set |= DP_MST_FEC_BS_JITTER_WA(crtc_state->cpu_transcoder);
 
+       /* Wa_14014143976:adlp */
+       if (IS_DISPLAY_STEP(i915, STEP_E0, STEP_FOREVER)) {
+               if (intel_dp_is_uhbr(crtc_state))
+                       set |= DP_MST_SHORT_HBLANK_WA(crtc_state->cpu_transcoder);
+               else if (crtc_state->fec_enable)
+                       clear |= DP_MST_SHORT_HBLANK_WA(crtc_state->cpu_transcoder);
+       }
+
        if (!clear && !set)
                return;
 
 
 #define   GLK_CL0_PWR_DOWN             REG_BIT(10)
 
 #define CHICKEN_MISC_3         _MMIO(0x42088)
+#define   DP_MST_SHORT_HBLANK_WA(trans)                REG_BIT(5 + (trans) - TRANSCODER_A)
 #define   DP_MST_FEC_BS_JITTER_WA(trans)       REG_BIT(0 + (trans) - TRANSCODER_A)
 
 #define CHICKEN_MISC_4         _MMIO(0x4208c)