drm/i915: Rename struct intel_crtc_config to intel_crtc_state
[linux-2.6-microblaze.git] / drivers / gpu / drm / i915 / intel_ddi.c
index e6b45cd..1cc38eb 100644 (file)
@@ -128,15 +128,15 @@ static const struct ddi_buf_trans bdw_ddi_translations_hdmi[] = {
 };
 
 static const struct ddi_buf_trans skl_ddi_translations_dp[] = {
-       { 0x00000018, 0x000000a0 },
-       { 0x00004014, 0x00000098 },
+       { 0x00000018, 0x000000a2 },
+       { 0x00004014, 0x0000009B },
        { 0x00006012, 0x00000088 },
-       { 0x00008010, 0x00000080 },
-       { 0x00000018, 0x00000098 },
+       { 0x00008010, 0x00000087 },
+       { 0x00000018, 0x0000009B },
        { 0x00004014, 0x00000088 },
-       { 0x00006012, 0x00000080 },
+       { 0x00006012, 0x00000087 },
        { 0x00000018, 0x00000088 },
-       { 0x00004014, 0x00000080 },
+       { 0x00004014, 0x00000087 },
 };
 
 static const struct ddi_buf_trans skl_ddi_translations_hdmi[] = {
@@ -732,7 +732,7 @@ static int skl_calc_wrpll_link(struct drm_i915_private *dev_priv,
 
 
 static void skl_ddi_clock_get(struct intel_encoder *encoder,
-                               struct intel_crtc_config *pipe_config)
+                               struct intel_crtc_state *pipe_config)
 {
        struct drm_i915_private *dev_priv = encoder->base.dev->dev_private;
        int link_clock = 0;
@@ -776,7 +776,7 @@ static void skl_ddi_clock_get(struct intel_encoder *encoder,
 }
 
 static void hsw_ddi_clock_get(struct intel_encoder *encoder,
-                             struct intel_crtc_config *pipe_config)
+                             struct intel_crtc_state *pipe_config)
 {
        struct drm_i915_private *dev_priv = encoder->base.dev->dev_private;
        int link_clock = 0;
@@ -832,9 +832,14 @@ static void hsw_ddi_clock_get(struct intel_encoder *encoder,
 }
 
 void intel_ddi_clock_get(struct intel_encoder *encoder,
-                        struct intel_crtc_config *pipe_config)
+                        struct intel_crtc_state *pipe_config)
 {
-       hsw_ddi_clock_get(encoder, pipe_config);
+       struct drm_device *dev = encoder->base.dev;
+
+       if (INTEL_INFO(dev)->gen <= 8)
+               hsw_ddi_clock_get(encoder, pipe_config);
+       else
+               skl_ddi_clock_get(encoder, pipe_config);
 }
 
 static void
@@ -2022,14 +2027,13 @@ static void intel_ddi_hot_plug(struct intel_encoder *intel_encoder)
 }
 
 void intel_ddi_get_config(struct intel_encoder *encoder,
-                         struct intel_crtc_config *pipe_config)
+                         struct intel_crtc_state *pipe_config)
 {
        struct drm_i915_private *dev_priv = encoder->base.dev->dev_private;
        struct intel_crtc *intel_crtc = to_intel_crtc(encoder->base.crtc);
        enum transcoder cpu_transcoder = intel_crtc->config.cpu_transcoder;
        struct intel_hdmi *intel_hdmi;
        u32 temp, flags = 0;
-       struct drm_device *dev = dev_priv->dev;
 
        temp = I915_READ(TRANS_DDI_FUNC_CTL(cpu_transcoder));
        if (temp & TRANS_DDI_PHSYNC)
@@ -2106,10 +2110,7 @@ void intel_ddi_get_config(struct intel_encoder *encoder,
                dev_priv->vbt.edp_bpp = pipe_config->pipe_bpp;
        }
 
-       if (INTEL_INFO(dev)->gen <= 8)
-               hsw_ddi_clock_get(encoder, pipe_config);
-       else
-               skl_ddi_clock_get(encoder, pipe_config);
+       intel_ddi_clock_get(encoder, pipe_config);
 }
 
 static void intel_ddi_destroy(struct drm_encoder *encoder)
@@ -2119,7 +2120,7 @@ static void intel_ddi_destroy(struct drm_encoder *encoder)
 }
 
 static bool intel_ddi_compute_config(struct intel_encoder *encoder,
-                                    struct intel_crtc_config *pipe_config)
+                                    struct intel_crtc_state *pipe_config)
 {
        int type = encoder->type;
        int port = intel_ddi_get_encoder_port(encoder);