diff options
author | Daniel Vetter <daniel.vetter@ffwll.ch> | 2013-04-17 14:15:07 -0400 |
---|---|---|
committer | Daniel Vetter <daniel.vetter@ffwll.ch> | 2013-04-18 03:43:32 -0400 |
commit | 3b117c8f2815bc4dd36b0b2c4b6490ad7d10b758 (patch) | |
tree | 24b0677f6f6ff5d3fa3a994e19c136dda5460731 /drivers/gpu/drm/i915/intel_hdmi.c | |
parent | dc4bd2d1095d0a7b45dcd23cc8a423a2952cbf4d (diff) |
drm/i915: move cpu_transcoder to the pipe configuration
For a bunch of reason we need to more accurately track this:
- hw pipe state readout for Haswell needs the cpu transcoder.
- We need to know the right cpu transcoder in a bunch of places in
->disable and other modeset callbacks.
In the future we need to add hw state readout&check support, too. But
to avoid ugly merge conflicts do the rote sed job now without any
functional changes.
v2: Preserve the cpu_transcoder value when overwriting crtc->config.
Reported by Paulo.
Cc: Paulo Zanoni <przanoni@gmail.com>
Reviewed-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk> (v1)
[danvet: Removed rough whitespace that Chris spotted.]
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Diffstat (limited to 'drivers/gpu/drm/i915/intel_hdmi.c')
-rw-r--r-- | drivers/gpu/drm/i915/intel_hdmi.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/gpu/drm/i915/intel_hdmi.c b/drivers/gpu/drm/i915/intel_hdmi.c index 89122011720b..3e6a3ef10d5c 100644 --- a/drivers/gpu/drm/i915/intel_hdmi.c +++ b/drivers/gpu/drm/i915/intel_hdmi.c | |||
@@ -294,8 +294,8 @@ static void hsw_write_infoframe(struct drm_encoder *encoder, | |||
294 | struct drm_device *dev = encoder->dev; | 294 | struct drm_device *dev = encoder->dev; |
295 | struct drm_i915_private *dev_priv = dev->dev_private; | 295 | struct drm_i915_private *dev_priv = dev->dev_private; |
296 | struct intel_crtc *intel_crtc = to_intel_crtc(encoder->crtc); | 296 | struct intel_crtc *intel_crtc = to_intel_crtc(encoder->crtc); |
297 | u32 ctl_reg = HSW_TVIDEO_DIP_CTL(intel_crtc->cpu_transcoder); | 297 | u32 ctl_reg = HSW_TVIDEO_DIP_CTL(intel_crtc->config.cpu_transcoder); |
298 | u32 data_reg = hsw_infoframe_data_reg(frame, intel_crtc->cpu_transcoder); | 298 | u32 data_reg = hsw_infoframe_data_reg(frame, intel_crtc->config.cpu_transcoder); |
299 | unsigned int i, len = DIP_HEADER_SIZE + frame->len; | 299 | unsigned int i, len = DIP_HEADER_SIZE + frame->len; |
300 | u32 val = I915_READ(ctl_reg); | 300 | u32 val = I915_READ(ctl_reg); |
301 | 301 | ||
@@ -570,7 +570,7 @@ static void hsw_set_infoframes(struct drm_encoder *encoder, | |||
570 | struct drm_i915_private *dev_priv = encoder->dev->dev_private; | 570 | struct drm_i915_private *dev_priv = encoder->dev->dev_private; |
571 | struct intel_crtc *intel_crtc = to_intel_crtc(encoder->crtc); | 571 | struct intel_crtc *intel_crtc = to_intel_crtc(encoder->crtc); |
572 | struct intel_hdmi *intel_hdmi = enc_to_intel_hdmi(encoder); | 572 | struct intel_hdmi *intel_hdmi = enc_to_intel_hdmi(encoder); |
573 | u32 reg = HSW_TVIDEO_DIP_CTL(intel_crtc->cpu_transcoder); | 573 | u32 reg = HSW_TVIDEO_DIP_CTL(intel_crtc->config.cpu_transcoder); |
574 | u32 val = I915_READ(reg); | 574 | u32 val = I915_READ(reg); |
575 | 575 | ||
576 | assert_hdmi_port_disabled(intel_hdmi); | 576 | assert_hdmi_port_disabled(intel_hdmi); |