]> git.ipfire.org Git - thirdparty/kernel/stable.git/commitdiff
drm/i915/psr: Write DSC parameters on Selective Update in ET mode
authorJouni Högander <jouni.hogander@intel.com>
Wed, 4 Mar 2026 11:30:11 +0000 (13:30 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Wed, 25 Mar 2026 10:08:48 +0000 (11:08 +0100)
commit 5923a6e0459fdd3edac4ad5abccb24d777d8f1b6 upstream.

There are slice row per frame and pic height parameters in DSC that needs
to be configured on every Selective Update in Early Transport mode. Use
helper provided by DSC code to configure these on Selective Update when in
Early Transport mode. Also fill crtc_state->psr2_su_area with full frame
area on full frame update for DSC calculation.

v2: move psr2_su_area under skip_sel_fetch_set_loop label

Bspec: 68927, 71709
Fixes: 467e4e061c44 ("drm/i915/psr: Enable psr2 early transport as possible")
Cc: <stable@vger.kernel.org> # v6.9+
Signed-off-by: Jouni Högander <jouni.hogander@intel.com>
Reviewed-by: Ankit Nautiyal <ankit.k.nautiyal@intel.com>
Link: https://patch.msgid.link/20260304113011.626542-5-jouni.hogander@intel.com
(cherry picked from commit 3140af2fab505a4cd47d516284529bf1585628be)
Signed-off-by: Tvrtko Ursulin <tursulin@ursulin.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/gpu/drm/i915/display/intel_psr.c

index 26a6edc2ec1b6dc567cfbd80038dac16f6c4fef3..fb948b117ca72dc56d2d47fa2624a8956ceda8e8 100644 (file)
@@ -41,6 +41,7 @@
 #include "intel_psr.h"
 #include "intel_psr_regs.h"
 #include "intel_snps_phy.h"
+#include "intel_vdsc.h"
 #include "skl_universal_plane.h"
 
 /**
@@ -2312,6 +2313,12 @@ void intel_psr2_program_trans_man_trk_ctl(const struct intel_crtc_state *crtc_st
 
        intel_de_write(display, PIPE_SRCSZ_ERLY_TPT(crtc->pipe),
                       crtc_state->pipe_srcsz_early_tpt);
+
+       if (!crtc_state->dsc.compression_enable)
+               return;
+
+       intel_dsc_su_et_parameters_configure(NULL, encoder, crtc_state,
+                                            drm_rect_height(&crtc_state->psr2_su_area));
 }
 
 static void psr2_man_trk_ctl_calc(struct intel_crtc_state *crtc_state,
@@ -2693,6 +2700,10 @@ int intel_psr2_sel_fetch_update(struct intel_atomic_state *state,
        }
 
 skip_sel_fetch_set_loop:
+       if (full_update)
+               clip_area_update(&crtc_state->psr2_su_area, &crtc_state->pipe_src,
+                                &crtc_state->pipe_src);
+
        psr2_man_trk_ctl_calc(crtc_state, full_update);
        crtc_state->pipe_srcsz_early_tpt =
                psr2_pipe_srcsz_early_tpt_calc(crtc_state, full_update);