@@ -1578,7 +1578,6 @@ bool intel_is_dual_link_lvds(struct drm_device *dev);
/* intel_modes.c */
int intel_connector_update_modes(struct drm_connector *connector,
struct edid *edid);
-int intel_ddc_get_modes(struct drm_connector *c, struct i2c_adapter *adapter);
void intel_attach_force_audio_property(struct drm_connector *connector);
void intel_attach_broadcast_rgb_property(struct drm_connector *connector);
void intel_attach_aspect_ratio_property(struct drm_connector *connector);
@@ -319,8 +319,9 @@ static int intel_dvo_get_modes(struct drm_connector *connector)
* (TV-out, for example), but for now with just TMDS and LVDS,
* that's not the case.
*/
- intel_ddc_get_modes(connector,
- intel_gmbus_get_adapter(dev_priv, GMBUS_PIN_DPC));
+ drm_mode_connector_get_edid(connector,
+ intel_gmbus_get_adapter(dev_priv, GMBUS_PIN_DPC),
+ NULL, true);
if (!list_empty(&connector->probed_modes))
return 1;
@@ -47,29 +47,6 @@ int intel_connector_update_modes(struct drm_connector *connector,
return ret;
}
-/**
- * intel_ddc_get_modes - get modelist from monitor
- * @connector: DRM connector device to use
- * @adapter: i2c adapter
- *
- * Fetch the EDID information from @connector using the DDC bus.
- */
-int intel_ddc_get_modes(struct drm_connector *connector,
- struct i2c_adapter *adapter)
-{
- struct edid *edid;
- int ret;
-
- edid = drm_get_edid(connector, adapter);
- if (!edid)
- return 0;
-
- ret = intel_connector_update_modes(connector, edid);
- kfree(edid);
-
- return ret;
-}
-
static const struct drm_prop_enum_list force_audio_names[] = {
{ HDMI_AUDIO_OFF_DVI, "force-dvi" },
{ HDMI_AUDIO_OFF, "off" },
@@ -1948,7 +1948,7 @@ static void intel_sdvo_get_lvds_modes(struct drm_connector *connector)
* Assume that the preferred modes are
* arranged in priority order.
*/
- intel_ddc_get_modes(connector, &intel_sdvo->ddc);
+ drm_mode_connector_get_edid(connector, &intel_sdvo->ddc, NULL, true);
list_for_each_entry(newmode, &connector->probed_modes, head) {
if (newmode->type & DRM_MODE_TYPE_PREFERRED) {
Don't do caching for now to minimize changes. Signed-off-by: Jani Nikula <jani.nikula@intel.com> --- drivers/gpu/drm/i915/intel_drv.h | 1 - drivers/gpu/drm/i915/intel_dvo.c | 5 +++-- drivers/gpu/drm/i915/intel_modes.c | 23 ----------------------- drivers/gpu/drm/i915/intel_sdvo.c | 2 +- 4 files changed, 4 insertions(+), 27 deletions(-)