aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/gpu')
-rw-r--r--drivers/gpu/drm/i915/intel_dp.c2
-rw-r--r--drivers/gpu/drm/i915/intel_drv.h3
-rw-r--r--drivers/gpu/drm/i915/intel_dsi.c2
-rw-r--r--drivers/gpu/drm/i915/intel_lvds.c10
-rw-r--r--drivers/gpu/drm/i915/intel_panel.c4
5 files changed, 12 insertions, 9 deletions
diff --git a/drivers/gpu/drm/i915/intel_dp.c b/drivers/gpu/drm/i915/intel_dp.c
index 0ef269053751..e5aaae3f8e19 100644
--- a/drivers/gpu/drm/i915/intel_dp.c
+++ b/drivers/gpu/drm/i915/intel_dp.c
@@ -3730,7 +3730,7 @@ static bool intel_edp_init_connector(struct intel_dp *intel_dp,
3730 fixed_mode->type |= DRM_MODE_TYPE_PREFERRED; 3730 fixed_mode->type |= DRM_MODE_TYPE_PREFERRED;
3731 } 3731 }
3732 3732
3733 intel_panel_init(&intel_connector->panel, fixed_mode); 3733 intel_panel_init(&intel_connector->panel, fixed_mode, NULL);
3734 intel_panel_setup_backlight(connector); 3734 intel_panel_setup_backlight(connector);
3735 3735
3736 return true; 3736 return true;
diff --git a/drivers/gpu/drm/i915/intel_drv.h b/drivers/gpu/drm/i915/intel_drv.h
index aff9171a91d8..3599d93caad4 100644
--- a/drivers/gpu/drm/i915/intel_drv.h
+++ b/drivers/gpu/drm/i915/intel_drv.h
@@ -823,7 +823,8 @@ int intel_overlay_attrs(struct drm_device *dev, void *data,
823 823
824/* intel_panel.c */ 824/* intel_panel.c */
825int intel_panel_init(struct intel_panel *panel, 825int intel_panel_init(struct intel_panel *panel,
826 struct drm_display_mode *fixed_mode); 826 struct drm_display_mode *fixed_mode,
827 struct drm_display_mode *downclock_mode);
827void intel_panel_fini(struct intel_panel *panel); 828void intel_panel_fini(struct intel_panel *panel);
828void intel_fixed_panel_mode(const struct drm_display_mode *fixed_mode, 829void intel_fixed_panel_mode(const struct drm_display_mode *fixed_mode,
829 struct drm_display_mode *adjusted_mode); 830 struct drm_display_mode *adjusted_mode);
diff --git a/drivers/gpu/drm/i915/intel_dsi.c b/drivers/gpu/drm/i915/intel_dsi.c
index fabbf0d895cf..6bffbdf149a8 100644
--- a/drivers/gpu/drm/i915/intel_dsi.c
+++ b/drivers/gpu/drm/i915/intel_dsi.c
@@ -624,7 +624,7 @@ bool intel_dsi_init(struct drm_device *dev)
624 } 624 }
625 625
626 fixed_mode->type |= DRM_MODE_TYPE_PREFERRED; 626 fixed_mode->type |= DRM_MODE_TYPE_PREFERRED;
627 intel_panel_init(&intel_connector->panel, fixed_mode); 627 intel_panel_init(&intel_connector->panel, fixed_mode, NULL);
628 628
629 return true; 629 return true;
630 630
diff --git a/drivers/gpu/drm/i915/intel_lvds.c b/drivers/gpu/drm/i915/intel_lvds.c
index 3f3043b4ff26..6341a8873d28 100644
--- a/drivers/gpu/drm/i915/intel_lvds.c
+++ b/drivers/gpu/drm/i915/intel_lvds.c
@@ -899,6 +899,7 @@ void intel_lvds_init(struct drm_device *dev)
899 struct drm_encoder *encoder; 899 struct drm_encoder *encoder;
900 struct drm_display_mode *scan; /* *modes, *bios_mode; */ 900 struct drm_display_mode *scan; /* *modes, *bios_mode; */
901 struct drm_display_mode *fixed_mode = NULL; 901 struct drm_display_mode *fixed_mode = NULL;
902 struct drm_display_mode *downclock_mode = NULL;
902 struct edid *edid; 903 struct edid *edid;
903 struct drm_crtc *crtc; 904 struct drm_crtc *crtc;
904 u32 lvds; 905 u32 lvds;
@@ -1032,15 +1033,14 @@ void intel_lvds_init(struct drm_device *dev)
1032 1033
1033 fixed_mode = drm_mode_duplicate(dev, scan); 1034 fixed_mode = drm_mode_duplicate(dev, scan);
1034 if (fixed_mode) { 1035 if (fixed_mode) {
1035 intel_connector->panel.downclock_mode = 1036 downclock_mode =
1036 intel_find_panel_downclock(dev, 1037 intel_find_panel_downclock(dev,
1037 fixed_mode, connector); 1038 fixed_mode, connector);
1038 if (intel_connector->panel.downclock_mode != 1039 if (downclock_mode != NULL &&
1039 NULL && i915.lvds_downclock) { 1040 i915.lvds_downclock) {
1040 /* We found the downclock for LVDS. */ 1041 /* We found the downclock for LVDS. */
1041 dev_priv->lvds_downclock_avail = true; 1042 dev_priv->lvds_downclock_avail = true;
1042 dev_priv->lvds_downclock = 1043 dev_priv->lvds_downclock =
1043 intel_connector->panel.
1044 downclock_mode->clock; 1044 downclock_mode->clock;
1045 DRM_DEBUG_KMS("LVDS downclock is found" 1045 DRM_DEBUG_KMS("LVDS downclock is found"
1046 " in EDID. Normal clock %dKhz, " 1046 " in EDID. Normal clock %dKhz, "
@@ -1116,7 +1116,7 @@ out:
1116 } 1116 }
1117 drm_sysfs_connector_add(connector); 1117 drm_sysfs_connector_add(connector);
1118 1118
1119 intel_panel_init(&intel_connector->panel, fixed_mode); 1119 intel_panel_init(&intel_connector->panel, fixed_mode, downclock_mode);
1120 intel_panel_setup_backlight(connector); 1120 intel_panel_setup_backlight(connector);
1121 1121
1122 return; 1122 return;
diff --git a/drivers/gpu/drm/i915/intel_panel.c b/drivers/gpu/drm/i915/intel_panel.c
index f1ee2c4d282e..5bc3f6ea1014 100644
--- a/drivers/gpu/drm/i915/intel_panel.c
+++ b/drivers/gpu/drm/i915/intel_panel.c
@@ -1190,9 +1190,11 @@ void intel_panel_init_backlight_funcs(struct drm_device *dev)
1190} 1190}
1191 1191
1192int intel_panel_init(struct intel_panel *panel, 1192int intel_panel_init(struct intel_panel *panel,
1193 struct drm_display_mode *fixed_mode) 1193 struct drm_display_mode *fixed_mode,
1194 struct drm_display_mode *downclock_mode)
1194{ 1195{
1195 panel->fixed_mode = fixed_mode; 1196 panel->fixed_mode = fixed_mode;
1197 panel->downclock_mode = downclock_mode;
1196 1198
1197 return 0; 1199 return 0;
1198} 1200}