Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit ca73b4f0 authored by Ville Syrjälä's avatar Ville Syrjälä Committed by Daniel Vetter
Browse files

drm/i915: Use adjusted_mode when checking conditions for PSR



intel_edp_psr_match_conditions() currently looks at crtc->mode
when it really needs to look at adjusted_mode. Fix it.

Signed-off-by: default avatarVille Syrjälä <ville.syrjala@linux.intel.com>
Reviewed-by: default avatarDamien Lespiau <damien.lespiau@intel.com>
Signed-off-by: default avatarDaniel Vetter <daniel.vetter@ffwll.ch>
parent 4af67d41
Loading
Loading
Loading
Loading
+3 −2
Original line number Diff line number Diff line
@@ -1628,7 +1628,8 @@ static bool intel_edp_psr_match_conditions(struct intel_dp *intel_dp)
	}

	intel_crtc = to_intel_crtc(crtc);
	if (!intel_crtc->active || !crtc->fb || !crtc->mode.clock) {
	if (!intel_crtc->active || !crtc->fb ||
	    !intel_crtc->config.adjusted_mode.clock) {
		DRM_DEBUG_KMS("crtc not active for PSR\n");
		dev_priv->no_psr_reason = PSR_CRTC_NOT_ACTIVE;
		return false;
@@ -1655,7 +1656,7 @@ static bool intel_edp_psr_match_conditions(struct intel_dp *intel_dp)
		return false;
	}

	if (crtc->mode.flags & DRM_MODE_FLAG_INTERLACE) {
	if (intel_crtc->config.adjusted_mode.flags & DRM_MODE_FLAG_INTERLACE) {
		DRM_DEBUG_KMS("PSR condition failed: Interlaced is Enabled\n");
		dev_priv->no_psr_reason = PSR_INTERLACED_ENABLED;
		return false;