Commit cbaa3315 authored by Gustavo A. R. Silva's avatar Gustavo A. R. Silva Committed by Daniel Vetter

gpu: drm: i915: remove dead code

Local variable has_reduced_clock is assigned to a constant value and it is
never updated again. Remove this variable and the dead code it guards.

Addresses-Coverity-ID: 1362230
Signed-off-by: default avatarGustavo A. R. Silva <garsilva@embeddedor.com>
Signed-off-by: default avatarDaniel Vetter <daniel.vetter@ffwll.ch>
Link: http://patchwork.freedesktop.org/patch/msgid/20170515215605.GA14963@embeddedgus
parent 9a09485d
...@@ -8192,8 +8192,6 @@ static int ironlake_crtc_compute_clock(struct intel_crtc *crtc, ...@@ -8192,8 +8192,6 @@ static int ironlake_crtc_compute_clock(struct intel_crtc *crtc,
{ {
struct drm_device *dev = crtc->base.dev; struct drm_device *dev = crtc->base.dev;
struct drm_i915_private *dev_priv = to_i915(dev); struct drm_i915_private *dev_priv = to_i915(dev);
struct dpll reduced_clock;
bool has_reduced_clock = false;
struct intel_shared_dpll *pll; struct intel_shared_dpll *pll;
const struct intel_limit *limit; const struct intel_limit *limit;
int refclk = 120000; int refclk = 120000;
...@@ -8236,8 +8234,7 @@ static int ironlake_crtc_compute_clock(struct intel_crtc *crtc, ...@@ -8236,8 +8234,7 @@ static int ironlake_crtc_compute_clock(struct intel_crtc *crtc,
return -EINVAL; return -EINVAL;
} }
ironlake_compute_dpll(crtc, crtc_state, ironlake_compute_dpll(crtc, crtc_state, NULL);
has_reduced_clock ? &reduced_clock : NULL);
pll = intel_get_shared_dpll(crtc, crtc_state, NULL); pll = intel_get_shared_dpll(crtc, crtc_state, NULL);
if (pll == NULL) { if (pll == NULL) {
...@@ -8246,10 +8243,6 @@ static int ironlake_crtc_compute_clock(struct intel_crtc *crtc, ...@@ -8246,10 +8243,6 @@ static int ironlake_crtc_compute_clock(struct intel_crtc *crtc,
return -EINVAL; return -EINVAL;
} }
if (intel_crtc_has_type(crtc_state, INTEL_OUTPUT_LVDS) &&
has_reduced_clock)
crtc->lowfreq_avail = true;
return 0; return 0;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment