summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/i915/intel_ddi.c
diff options
context:
space:
mode:
authorDaniel Vetter <daniel.vetter@ffwll.ch>2014-04-24 23:54:47 +0200
committerDaniel Vetter <daniel.vetter@ffwll.ch>2014-05-16 11:57:44 +0200
commit6897b4b5d3336a0a02d94225de971985c7ad42fe (patch)
treed9873e0d2456b48e525b6343b1003aea73a5620e /drivers/gpu/drm/i915/intel_ddi.c
parentabac6a009c34cb4d191360dd17c5c4a804ab392a (diff)
downloadop-kernel-dev-6897b4b5d3336a0a02d94225de971985c7ad42fe.zip
op-kernel-dev-6897b4b5d3336a0a02d94225de971985c7ad42fe.tar.gz
drm/i915: Track hdmi mode in the pipe config
Also add state readout and cross-check support. The only invasive change is wiring up the new flag to the ->set_infoframes callbacks. Reviewed-by: Naresh Kumar Kachhi <naresh.kumar.kachhi@intel.com> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Diffstat (limited to 'drivers/gpu/drm/i915/intel_ddi.c')
-rw-r--r--drivers/gpu/drm/i915/intel_ddi.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/drivers/gpu/drm/i915/intel_ddi.c b/drivers/gpu/drm/i915/intel_ddi.c
index 0ad4e96..94dc626 100644
--- a/drivers/gpu/drm/i915/intel_ddi.c
+++ b/drivers/gpu/drm/i915/intel_ddi.c
@@ -409,7 +409,9 @@ static void intel_ddi_mode_set(struct intel_encoder *encoder)
intel_write_eld(&encoder->base, adjusted_mode);
}
- intel_hdmi->set_infoframes(&encoder->base, adjusted_mode);
+ intel_hdmi->set_infoframes(&encoder->base,
+ crtc->config.has_hdmi_sink,
+ adjusted_mode);
}
}
@@ -1062,9 +1064,7 @@ void intel_ddi_enable_transcoder_func(struct drm_crtc *crtc)
}
if (type == INTEL_OUTPUT_HDMI) {
- struct intel_hdmi *intel_hdmi = enc_to_intel_hdmi(encoder);
-
- if (intel_hdmi->has_hdmi_sink)
+ if (intel_crtc->config.has_hdmi_sink)
temp |= TRANS_DDI_MODE_SELECT_HDMI;
else
temp |= TRANS_DDI_MODE_SELECT_DVI;
@@ -1580,6 +1580,7 @@ void intel_ddi_get_config(struct intel_encoder *encoder,
switch (temp & TRANS_DDI_MODE_SELECT_MASK) {
case TRANS_DDI_MODE_SELECT_HDMI:
+ pipe_config->has_hdmi_sink = true;
case TRANS_DDI_MODE_SELECT_DVI:
case TRANS_DDI_MODE_SELECT_FDI:
break;
OpenPOWER on IntegriCloud