drm/i915: Remove the redundant check for a fixed_panel_mode
authorChris Wilson <chris@chris-wilson.co.uk>
Sat, 17 Jul 2010 12:38:43 +0000 (13:38 +0100)
committerEric Anholt <eric@anholt.net>
Mon, 2 Aug 2010 02:35:16 +0000 (19:35 -0700)
We already checked just a couple of lines above that we have found a
fixed_panel_mode for the LVDS, so remove the surplus check.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Signed-off-by: Eric Anholt <eric@anholt.net>
drivers/gpu/drm/i915/intel_lvds.c

index 0eab8df5bf7e1c679b52752311e665e51d3ab21d..6ef9388c54d3c1a5c7f88a1c334ec6556eaf5769 100644 (file)
@@ -200,27 +200,25 @@ static bool intel_lvds_mode_fixup(struct drm_encoder *encoder,
        if (dev_priv->panel_fixed_mode == NULL)
                return true;
        /*
-        * If we have timings from the BIOS for the panel, put them in
+        * We have timings from the BIOS for the panel, put them in
         * to the adjusted mode.  The CRTC will be set up for this mode,
         * with the panel scaling set up to source from the H/VDisplay
         * of the original mode.
         */
-       if (dev_priv->panel_fixed_mode != NULL) {
-               adjusted_mode->hdisplay = dev_priv->panel_fixed_mode->hdisplay;
-               adjusted_mode->hsync_start =
-                       dev_priv->panel_fixed_mode->hsync_start;
-               adjusted_mode->hsync_end =
-                       dev_priv->panel_fixed_mode->hsync_end;
-               adjusted_mode->htotal = dev_priv->panel_fixed_mode->htotal;
-               adjusted_mode->vdisplay = dev_priv->panel_fixed_mode->vdisplay;
-               adjusted_mode->vsync_start =
-                       dev_priv->panel_fixed_mode->vsync_start;
-               adjusted_mode->vsync_end =
-                       dev_priv->panel_fixed_mode->vsync_end;
-               adjusted_mode->vtotal = dev_priv->panel_fixed_mode->vtotal;
-               adjusted_mode->clock = dev_priv->panel_fixed_mode->clock;
-               drm_mode_set_crtcinfo(adjusted_mode, CRTC_INTERLACE_HALVE_V);
-       }
+       adjusted_mode->hdisplay = dev_priv->panel_fixed_mode->hdisplay;
+       adjusted_mode->hsync_start =
+               dev_priv->panel_fixed_mode->hsync_start;
+       adjusted_mode->hsync_end =
+               dev_priv->panel_fixed_mode->hsync_end;
+       adjusted_mode->htotal = dev_priv->panel_fixed_mode->htotal;
+       adjusted_mode->vdisplay = dev_priv->panel_fixed_mode->vdisplay;
+       adjusted_mode->vsync_start =
+               dev_priv->panel_fixed_mode->vsync_start;
+       adjusted_mode->vsync_end =
+               dev_priv->panel_fixed_mode->vsync_end;
+       adjusted_mode->vtotal = dev_priv->panel_fixed_mode->vtotal;
+       adjusted_mode->clock = dev_priv->panel_fixed_mode->clock;
+       drm_mode_set_crtcinfo(adjusted_mode, CRTC_INTERLACE_HALVE_V);
 
        /* Make sure pre-965s set dither correctly */
        if (!IS_I965G(dev)) {