From mboxrd@z Thu Jan 1 00:00:00 1970 From: Daniel Vetter Subject: Re: [PATCH 08/25] drm/i915: detect PCH encoders on Haswell Date: Wed, 9 May 2012 23:46:58 +0200 Message-ID: <20120509214658.GF4963@phenom.ffwll.local> References: <1336588652-702-1-git-send-email-eugeni.dodonov@intel.com> <1336588652-702-9-git-send-email-eugeni.dodonov@intel.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Received: from mail-we0-f177.google.com (mail-we0-f177.google.com [74.125.82.177]) by gabe.freedesktop.org (Postfix) with ESMTP id A06999E7C3 for ; Wed, 9 May 2012 14:45:50 -0700 (PDT) Received: by werp11 with SMTP id p11so643336wer.36 for ; Wed, 09 May 2012 14:45:49 -0700 (PDT) Content-Disposition: inline In-Reply-To: <1336588652-702-9-git-send-email-eugeni.dodonov@intel.com> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: intel-gfx-bounces+gcfxdi-intel-gfx=m.gmane.org@lists.freedesktop.org Errors-To: intel-gfx-bounces+gcfxdi-intel-gfx=m.gmane.org@lists.freedesktop.org To: Eugeni Dodonov Cc: intel-gfx@lists.freedesktop.org List-Id: intel-gfx@lists.freedesktop.org On Wed, May 09, 2012 at 03:37:15PM -0300, Eugeni Dodonov wrote: > 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. > > Signed-off-by: Eugeni Dodonov > --- > drivers/gpu/drm/i915/intel_display.c | 16 ++++++++++++++++ > 1 file changed, 16 insertions(+) > > diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c > index f809d6a..96933cc 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) > if (encoder->base.crtc != crtc) > continue; > > + /* On Haswell, LPT PCH handles the VGA connection via FDI, and Haswell > + * CPU handles all others */ > + if (IS_HASWELL(dev)) { > + if (encoder->type == DRM_MODE_ENCODER_DAC) { > + /* It is still unclear how this would work on PPT, so throw up an error */ > + if (!HAS_PCH_LPT(dev)) > + DRM_ERROR("DAC detected on a non-LPT PCH, this probably won't work\n"); Hm, I guess we should move the LPT check out of the DAC check - after all we could drive a DP output through FDI on a PPT. Or maybe not, which implies that we have no clue in either case ;-) -Daniel > + > + return true; > + } else { > + DRM_DEBUG_KMS("Haswell detected encoder %d, assuming is CPU\n", > + encoder->type); > + return false; > + } > + } > + > switch (encoder->type) { > case INTEL_OUTPUT_EDP: > if (!intel_encoder_is_pch_edp(&encoder->base)) > -- > 1.7.10 > > _______________________________________________ > Intel-gfx mailing list > Intel-gfx@lists.freedesktop.org > http://lists.freedesktop.org/mailman/listinfo/intel-gfx -- Daniel Vetter Mail: daniel@ffwll.ch Mobile: +41 (0)79 365 57 48