Skip to content

Commit 34eb757

Browse files
rodrigovividanvet
authored andcommitted
drm/i915: Do not try to enable PSR when Panel doesn't suport it.
Also do not cache aux info. That info could be related to another panel. Reviewed-by: Vijay Purushothaman <vijay.a.purushothaman@intel.com> Signed-off-by: Rodrigo Vivi <rodrigo.vivi@intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
1 parent 1648725 commit 34eb757

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

drivers/gpu/drm/i915/intel_dp.c

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1613,11 +1613,9 @@ static void intel_dp_get_config(struct intel_encoder *encoder,
16131613
}
16141614
}
16151615

1616-
static bool is_edp_psr(struct drm_device *dev)
1616+
static bool is_edp_psr(struct intel_dp *intel_dp)
16171617
{
1618-
struct drm_i915_private *dev_priv = dev->dev_private;
1619-
1620-
return dev_priv->psr.sink_support;
1618+
return intel_dp->psr_dpcd[0] & DP_PSR_IS_SUPPORTED;
16211619
}
16221620

16231621
static bool intel_edp_is_psr_enabled(struct drm_device *dev)
@@ -1821,6 +1819,11 @@ void intel_edp_psr_enable(struct intel_dp *intel_dp)
18211819
return;
18221820
}
18231821

1822+
if (!is_edp_psr(intel_dp)) {
1823+
DRM_DEBUG_KMS("PSR not supported by this panel\n");
1824+
return;
1825+
}
1826+
18241827
/* Setup PSR once */
18251828
intel_edp_psr_setup(intel_dp);
18261829

@@ -1862,9 +1865,6 @@ void intel_edp_psr_update(struct drm_device *dev)
18621865
if (encoder->type == INTEL_OUTPUT_EDP) {
18631866
intel_dp = enc_to_intel_dp(&encoder->base);
18641867

1865-
if (!is_edp_psr(dev))
1866-
return;
1867-
18681868
if (!intel_edp_psr_match_conditions(intel_dp))
18691869
intel_edp_psr_disable(intel_dp);
18701870
else

0 commit comments

Comments
 (0)