Merge commit 'keithp/drm-intel-next' into drm-intel-next
Eric Anholt [Mon, 22 Jun 2009 05:14:55 +0000 (22:14 -0700)]
1  2 
drivers/gpu/drm/i915/intel_hdmi.c

@@@ -135,14 -136,20 +136,20 @@@ intel_hdmi_edid_detect(struct drm_conne
        struct intel_output *intel_output = to_intel_output(connector);
        struct intel_hdmi_priv *hdmi_priv = intel_output->dev_priv;
        struct edid *edid = NULL;
+       enum drm_connector_status status = connector_status_disconnected;
  
        edid = drm_get_edid(&intel_output->base,
-                           &intel_output->ddc_bus->adapter);
-       if (edid != NULL) {
-               hdmi_priv->has_hdmi_sink = drm_detect_hdmi_monitor(edid);
-               kfree(edid);
+                           intel_output->ddc_bus);
+       hdmi_priv->has_hdmi_sink = false;
+       if (edid) {
 -              if (edid->digital) {
++              if (edid->input & DRM_EDID_INPUT_DIGITAL) {
+                       status = connector_status_connected;
+                       hdmi_priv->has_hdmi_sink = drm_detect_hdmi_monitor(edid);
+               }
                intel_output->base.display_info.raw_edid = NULL;
+               kfree(edid);
        }
+       return status;
  }
  
  static enum drm_connector_status