drm/i915/psr: Intel_psr_pause/resume needs to support panel replay
authorJouni Högander <jouni.hogander@intel.com>
Fri, 5 Apr 2024 11:35:57 +0000 (14:35 +0300)
committerJouni Högander <jouni.hogander@intel.com>
Mon, 8 Apr 2024 07:28:52 +0000 (10:28 +0300)
Currently intel_psr_pause and intel_psr_resume do nothing in case of panel
replay. Change them to perform pause and return also in case of panel
replay.

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/20240405113602.992714-4-jouni.hogander@intel.com
drivers/gpu/drm/i915/display/intel_psr.c

index 10a7795cdb6f01775526c280cfdb7208b16e7a97..bd99b995327483dc6a035ec2fd65f1c8e44338bb 100644 (file)
@@ -2104,7 +2104,7 @@ void intel_psr_pause(struct intel_dp *intel_dp)
        struct drm_i915_private *dev_priv = dp_to_i915(intel_dp);
        struct intel_psr *psr = &intel_dp->psr;
 
-       if (!CAN_PSR(intel_dp))
+       if (!CAN_PSR(intel_dp) && !CAN_PANEL_REPLAY(intel_dp))
                return;
 
        mutex_lock(&psr->lock);
@@ -2137,7 +2137,7 @@ void intel_psr_resume(struct intel_dp *intel_dp)
 {
        struct intel_psr *psr = &intel_dp->psr;
 
-       if (!CAN_PSR(intel_dp))
+       if (!CAN_PSR(intel_dp) && !CAN_PANEL_REPLAY(intel_dp))
                return;
 
        mutex_lock(&psr->lock);