summaryrefslogtreecommitdiffstats
path: root/drivers/gpu
diff options
context:
space:
mode:
authorAdam Jackson <ajax@redhat.com>2010-07-16 14:46:31 -0400
committerEric Anholt <eric@anholt.net>2010-08-01 19:38:08 -0700
commitb599c0bca1e08a89a7fc4305bc84f4be30ada368 (patch)
tree417b9c7e9d91bfb250d577aa70741802bd475743 /drivers/gpu
parentd6d952689a48375afb97f619f77d548f16d45a92 (diff)
downloadop-kernel-dev-b599c0bca1e08a89a7fc4305bc84f4be30ada368.zip
op-kernel-dev-b599c0bca1e08a89a7fc4305bc84f4be30ada368.tar.gz
drm/i915/hdmi: Set sync polarity based on actual mode
Signed-off-by: Adam Jackson <ajax@redhat.com> Signed-off-by: Eric Anholt <eric@anholt.net>
Diffstat (limited to 'drivers/gpu')
-rw-r--r--drivers/gpu/drm/i915/intel_hdmi.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/drivers/gpu/drm/i915/intel_hdmi.c b/drivers/gpu/drm/i915/intel_hdmi.c
index 83bd764..197887e 100644
--- a/drivers/gpu/drm/i915/intel_hdmi.c
+++ b/drivers/gpu/drm/i915/intel_hdmi.c
@@ -54,10 +54,11 @@ static void intel_hdmi_mode_set(struct drm_encoder *encoder,
struct intel_hdmi_priv *hdmi_priv = intel_encoder->dev_priv;
u32 sdvox;
- sdvox = SDVO_ENCODING_HDMI |
- SDVO_BORDER_ENABLE |
- SDVO_VSYNC_ACTIVE_HIGH |
- SDVO_HSYNC_ACTIVE_HIGH;
+ sdvox = SDVO_ENCODING_HDMI | SDVO_BORDER_ENABLE;
+ if (adjusted_mode->flags & DRM_MODE_FLAG_PVSYNC)
+ sdvox |= SDVO_VSYNC_ACTIVE_HIGH;
+ if (adjusted_mode->flags & DRM_MODE_FLAG_PHSYNC)
+ sdvox |= SDVO_HSYNC_ACTIVE_HIGH;
if (hdmi_priv->has_hdmi_sink) {
sdvox |= SDVO_AUDIO_ENABLE;
OpenPOWER on IntegriCloud