Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 218317
b: refs/heads/master
c: 2e3d600
h: refs/heads/master
i:
  218315: 5a6b958
v: v3
  • Loading branch information
Zhenyu Wang authored and Chris Wilson committed Oct 19, 2010
1 parent 44b32ae commit 6b3ba3a
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 5 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: a9756bb5b25d5d997df0c5d8c95db01292191bea
refs/heads/master: 2e3d6006aca163db3eeb931cec631974aaa3c293
12 changes: 8 additions & 4 deletions trunk/drivers/gpu/drm/i915/intel_hdmi.c
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@ struct intel_hdmi {
u32 sdvox_reg;
int ddc_bus;
bool has_hdmi_sink;
bool has_audio;
};

static struct intel_hdmi *enc_to_intel_hdmi(struct drm_encoder *encoder)
Expand Down Expand Up @@ -72,11 +73,12 @@ static void intel_hdmi_mode_set(struct drm_encoder *encoder,
if (adjusted_mode->flags & DRM_MODE_FLAG_PHSYNC)
sdvox |= SDVO_HSYNC_ACTIVE_HIGH;

if (intel_hdmi->has_hdmi_sink) {
/* Required on CPT */
if (intel_hdmi->has_hdmi_sink && HAS_PCH_CPT(dev))
sdvox |= HDMI_MODE_SELECT;

if (intel_hdmi->has_audio)
sdvox |= SDVO_AUDIO_ENABLE;
if (HAS_PCH_CPT(dev))
sdvox |= HDMI_MODE_SELECT;
}

if (intel_crtc->pipe == 1) {
if (HAS_PCH_CPT(dev))
Expand Down Expand Up @@ -154,13 +156,15 @@ intel_hdmi_detect(struct drm_connector *connector, bool force)
enum drm_connector_status status = connector_status_disconnected;

intel_hdmi->has_hdmi_sink = false;
intel_hdmi->has_audio = false;
edid = drm_get_edid(connector,
&dev_priv->gmbus[intel_hdmi->ddc_bus].adapter);

if (edid) {
if (edid->input & DRM_EDID_INPUT_DIGITAL) {
status = connector_status_connected;
intel_hdmi->has_hdmi_sink = drm_detect_hdmi_monitor(edid);
intel_hdmi->has_audio = drm_detect_monitor_audio(edid);
}
connector->display_info.raw_edid = NULL;
kfree(edid);
Expand Down

0 comments on commit 6b3ba3a

Please sign in to comment.