diff options
author | Daniel Vetter <daniel.vetter@ffwll.ch> | 2014-07-11 10:30:18 -0700 |
---|---|---|
committer | Daniel Vetter <daniel.vetter@ffwll.ch> | 2014-07-23 07:05:20 +0200 |
commit | eeefa889cddb8d7e4ee6ce0212e685dd624d66a1 (patch) | |
tree | 026c1110b986caa1b7b025a7bd56eabb0450f7dc /drivers/gpu/drm/i915/intel_dp.c | |
parent | fa128fa647b81734ff83c3c5ee0d60ebf69e6ee5 (diff) | |
download | linux-next-eeefa889cddb8d7e4ee6ce0212e685dd624d66a1.tar.gz |
drm/i915: Remove redundant HAS_PSR checks
We only need to check for this in psr_enable, everything else is
already protect by the dev_priv->psr.enabled checks. Those need the
psr locking, but these functions are called infrequent enough that the
locking overhead is negligible.
Suggested by Chris Wilson.
Reviewed-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
Cc: Chris Wilson <chris@chris-wilson.co.uk>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Diffstat (limited to 'drivers/gpu/drm/i915/intel_dp.c')
-rw-r--r-- | drivers/gpu/drm/i915/intel_dp.c | 14 |
1 files changed, 0 insertions, 14 deletions
diff --git a/drivers/gpu/drm/i915/intel_dp.c b/drivers/gpu/drm/i915/intel_dp.c index 333471c4dcd1..86b5e979e616 100644 --- a/drivers/gpu/drm/i915/intel_dp.c +++ b/drivers/gpu/drm/i915/intel_dp.c @@ -1772,11 +1772,6 @@ static bool intel_edp_psr_match_conditions(struct intel_dp *intel_dp) dev_priv->psr.source_ok = false; - if (!HAS_PSR(dev)) { - DRM_DEBUG_KMS("PSR not supported on this platform\n"); - return false; - } - if (IS_HASWELL(dev) && dig_port->port != PORT_A) { DRM_DEBUG_KMS("HSW ties PSR to DDI A (eDP)\n"); return false; @@ -1863,9 +1858,6 @@ void intel_edp_psr_disable(struct intel_dp *intel_dp) struct drm_device *dev = intel_dp_to_dev(intel_dp); struct drm_i915_private *dev_priv = dev->dev_private; - if (!HAS_PSR(dev)) - return; - mutex_lock(&dev_priv->psr.lock); if (!dev_priv->psr.enabled) { mutex_unlock(&dev_priv->psr.lock); @@ -1940,9 +1932,6 @@ void intel_edp_psr_invalidate(struct drm_device *dev, struct drm_crtc *crtc; enum pipe pipe; - if (!HAS_PSR(dev)) - return; - mutex_lock(&dev_priv->psr.lock); if (!dev_priv->psr.enabled) { mutex_unlock(&dev_priv->psr.lock); @@ -1967,9 +1956,6 @@ void intel_edp_psr_flush(struct drm_device *dev, struct drm_crtc *crtc; enum pipe pipe; - if (!HAS_PSR(dev)) - return; - mutex_lock(&dev_priv->psr.lock); if (!dev_priv->psr.enabled) { mutex_unlock(&dev_priv->psr.lock); |