drm/i915/psr: Check panel ALPM capability for eDP Panel Replay
authorJouni Högander <jouni.hogander@intel.com>
Wed, 19 Jun 2024 06:21:21 +0000 (09:21 +0300)
committerJouni Högander <jouni.hogander@intel.com>
Tue, 25 Jun 2024 05:23:27 +0000 (08:23 +0300)
Our HW doesn't support Panel Replay without AUX_LESS ALPM on eDP. Check
panel support for this and prevent eDP panel replay if it doesn't exits.

Bspec: 68920

v3: remove excessive parens
v2: use intel_alpm_aux_less_wake_supported

Signed-off-by: Jouni Högander <jouni.hogander@intel.com>
Reviewed-by: Animesh Manna <animesh.manna@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20240619062131.4021196-2-jouni.hogander@intel.com
drivers/gpu/drm/i915/display/intel_psr.c

index 0dbcaf64462448abb5f45fbd892004baed74a5e4..777aaa26464e088b00268b5ea9a293a5509368d8 100644 (file)
@@ -571,6 +571,13 @@ static void _panel_replay_init_dpcd(struct intel_dp *intel_dp)
 {
        struct drm_i915_private *i915 = dp_to_i915(intel_dp);
 
+       if (intel_dp_is_edp(intel_dp) &&
+           !intel_alpm_aux_less_wake_supported(intel_dp)) {
+               drm_dbg_kms(&i915->drm,
+                           "Panel doesn't support AUX-less ALPM, eDP Panel Replay not possible\n");
+               return;
+       }
+
        intel_dp->psr.sink_panel_replay_support = true;
 
        if (intel_dp->pr_dpcd & DP_PANEL_REPLAY_SU_SUPPORT)