diff options
author | Eugeni Dodonov <eugeni.dodonov@intel.com> | 2012-05-09 19:30:31 -0400 |
---|---|---|
committer | Daniel Vetter <daniel.vetter@ffwll.ch> | 2012-05-19 16:39:45 -0400 |
commit | 6ee8bab09d515503f9f1d01690840c2bd5f66267 (patch) | |
tree | 61183b3d617d651bef2c4d55c5c81ab2c12db9ab /drivers | |
parent | f57e1e3a67503927824839996a6efce269281afa (diff) |
drm/i915: detect PCH encoders on Haswell
On Haswell, the recommended PCH-connected output is the one driven by DDI
E in FDI mode, used for VGA connection. All the others are handled by the
CPU.
Note that this does not accounts for Haswell/PPT combination yet, so if we
encounter such combination an error message is thrown to indicate that
things could go wrong.
v2: improve non-LPT detection warning per Daniel Vetter's suggestion.
Signed-off-by: Eugeni Dodonov <eugeni.dodonov@intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/gpu/drm/i915/intel_display.c | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c index cc910e69f709..bb049a178632 100644 --- a/drivers/gpu/drm/i915/intel_display.c +++ b/drivers/gpu/drm/i915/intel_display.c | |||
@@ -2610,6 +2610,22 @@ static bool intel_crtc_driving_pch(struct drm_crtc *crtc) | |||
2610 | if (encoder->base.crtc != crtc) | 2610 | if (encoder->base.crtc != crtc) |
2611 | continue; | 2611 | continue; |
2612 | 2612 | ||
2613 | /* On Haswell, LPT PCH handles the VGA connection via FDI, and Haswell | ||
2614 | * CPU handles all others */ | ||
2615 | if (IS_HASWELL(dev)) { | ||
2616 | /* It is still unclear how this will work on PPT, so throw up a warning */ | ||
2617 | WARN_ON(!HAS_PCH_LPT(dev)); | ||
2618 | |||
2619 | if (encoder->type == DRM_MODE_ENCODER_DAC) { | ||
2620 | DRM_DEBUG_KMS("Haswell detected DAC encoder, assuming is PCH\n"); | ||
2621 | return true; | ||
2622 | } else { | ||
2623 | DRM_DEBUG_KMS("Haswell detected encoder %d, assuming is CPU\n", | ||
2624 | encoder->type); | ||
2625 | return false; | ||
2626 | } | ||
2627 | } | ||
2628 | |||
2613 | switch (encoder->type) { | 2629 | switch (encoder->type) { |
2614 | case INTEL_OUTPUT_EDP: | 2630 | case INTEL_OUTPUT_EDP: |
2615 | if (!intel_encoder_is_pch_edp(&encoder->base)) | 2631 | if (!intel_encoder_is_pch_edp(&encoder->base)) |