Re: [Intel-gfx] [PATCH 3/7] drm/i915: Treat PCH eDP like DP in most places

Jesse Barnes
2011-11-02T16:20:30Z

[-- Attachment #1: Type: text/plain, Size: 1351 bytes --]

On Tue, 1 Nov 2011 23:20:26 -0700
Keith Packard <keithp@keithp.com> wrote:

> PCH eDP has many of the same needs as regular PCH DP connections,
> including the DP_CTl bit settings, the TRANS_DP_CTL register.
>
> Signed-off-by: Keith Packard <keithp@keithp.com>
> ---
> drivers/gpu/drm/i915/intel_display.c | 3 +-
> drivers/gpu/drm/i915/intel_dp.c | 112 ++++++++++++++++++++++++----------
> 2 files changed, 81 insertions(+), 34 deletions(-)
>

Might be nice to have some function pointers to handle the different
types better. But that could be a separate cleanup. I'd rather have
duplicated code than fragile code...

Reviewed-by: Jesse Barnes <jbarnes@virtuousgeek.org>

But I was curious about this hunk:

@@ -766,10 +766,10 @@ intel_dp_set_m_n(struct drm_crtc *crtc, struct drm_display_mode *mode,
continue;

intel_dp = enc_to_intel_dp(encoder);
- if (intel_dp->base.type == INTEL_OUTPUT_DISPLAYPORT) {
+ if (intel_dp->base.type == INTEL_OUTPUT_DISPLAYPORT || is_pch_edp(intel_dp)) {
lane_count = intel_dp->lane_count;
break;
- } else if (is_edp(intel_dp)) {
+ } else if (is_cpu_edp(intel_dp)) {
lane_count = dev_priv->edp.lanes;
break;
}

I guess this means we can't trust the BIOS settings for PCH eDP?

--
Jesse Barnes, Intel Open Source Technology Center

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 836 bytes --]