From: Daniel Vetter <daniel@ffwll.ch>
To: Jesse Barnes <jbarnes@virtuousgeek.org>
Cc: intel-gfx@lists.freedesktop.org
Subject: Re: [PATCH 3/3] drm/i915: Simplify DP vs. eDP detection
Date: Thu, 28 Nov 2013 13:43:17 +0100 [thread overview]
Message-ID: <20131128124317.GH27344@phenom.ffwll.local> (raw)
In-Reply-To: <20131101102542.4605c354@jbarnes-desktop>
On Fri, Nov 01, 2013 at 10:25:42AM -0700, Jesse Barnes wrote:
> On Fri, 1 Nov 2013 18:22:41 +0200
> ville.syrjala@linux.intel.com wrote:
>
> > From: Ville Syrjälä <ville.syrjala@linux.intel.com>
> >
> > Reduce the eDP detection to just checking if it's port A, or if
> > the VBT tells us that the port is eDP for the other ports.
> >
> > Suggested-by: Jesse Barnes <jbarnes@virtuousgeek.org>
> > Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
> > ---
> > drivers/gpu/drm/i915/intel_dp.c | 26 ++++++--------------------
> > 1 file changed, 6 insertions(+), 20 deletions(-)
> >
> > diff --git a/drivers/gpu/drm/i915/intel_dp.c b/drivers/gpu/drm/i915/intel_dp.c
> > index 87cfb12..1e6bf7b 100644
> > --- a/drivers/gpu/drm/i915/intel_dp.c
> > +++ b/drivers/gpu/drm/i915/intel_dp.c
> > @@ -3274,6 +3274,9 @@ bool intel_dp_is_edp(struct drm_device *dev, enum port port)
> > [PORT_D] = PORT_IDPD,
> > };
> >
> > + if (port == PORT_A)
> > + return true;
> > +
> > if (!dev_priv->vbt.child_dev_num)
> > return false;
> >
> > @@ -3560,27 +3563,10 @@ intel_dp_init_connector(struct intel_digital_port *intel_dig_port,
> > intel_dp->DP = I915_READ(intel_dp->output_reg);
> > intel_dp->attached_connector = intel_connector;
> >
> > - type = DRM_MODE_CONNECTOR_DisplayPort;
> > - /*
> > - * FIXME : We need to initialize built-in panels before external panels.
> > - * For X0, DP_C is fixed as eDP. Revisit this as part of VLV eDP cleanup
> > - */
> > - switch (port) {
> > - case PORT_A:
> > + if (intel_dp_is_edp(dev, port))
> > type = DRM_MODE_CONNECTOR_eDP;
> > - break;
> > - case PORT_B:
> > - case PORT_C:
> > - if (IS_VALLEYVIEW(dev) && intel_dp_is_edp(dev, port))
> > - type = DRM_MODE_CONNECTOR_eDP;
> > - break;
> > - case PORT_D:
> > - if (HAS_PCH_SPLIT(dev) && intel_dp_is_edp(dev, port))
> > - type = DRM_MODE_CONNECTOR_eDP;
> > - break;
> > - default: /* silence GCC warning */
> > - break;
> > - }
> > + else
> > + type = DRM_MODE_CONNECTOR_DisplayPort;
> >
> > /*
> > * For eDP we always set the encoder type to INTEL_OUTPUT_EDP, but
>
> Ah much better.
>
> Reviewed-by: Jesse Barnes <jbarnes@virtuousgeek.org>
Ok, now also merged patches 1&3 of the original series here. Patch 1
didn't really apply that well any more, so please double-check what I've
done.
-Daniel
--
Daniel Vetter
Software Engineer, Intel Corporation
+41 (0) 79 365 57 48 - http://blog.ffwll.ch
prev parent reply other threads:[~2013-11-28 12:42 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-11-01 16:22 [PATCH 0/3] drm/i915: eDP vs. DP detection changes ville.syrjala
2013-11-01 16:22 ` [PATCH 1/3] drm/i915: Check VBT for eDP ports on VLV ville.syrjala
2013-11-01 17:23 ` Jesse Barnes
2013-11-01 16:22 ` [PATCH 2/3] drm/i915: Make intel_dp_is_edp() less specific ville.syrjala
2013-11-01 17:25 ` Jesse Barnes
2013-11-01 18:32 ` [PATCH 1/2] drm/i915: Give names to the VBT child device type bits ville.syrjala
2013-11-01 18:32 ` [PATCH v2 2/2] drm/i915: Make intel_dp_is_edp() less specific ville.syrjala
2013-11-04 16:08 ` Paulo Zanoni
2013-11-04 16:30 ` Daniel Vetter
2013-11-04 15:58 ` [PATCH 1/2] drm/i915: Give names to the VBT child device type bits Paulo Zanoni
2013-11-01 16:22 ` [PATCH 3/3] drm/i915: Simplify DP vs. eDP detection ville.syrjala
2013-11-01 17:25 ` Jesse Barnes
2013-11-28 12:43 ` Daniel Vetter [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20131128124317.GH27344@phenom.ffwll.local \
--to=daniel@ffwll.ch \
--cc=intel-gfx@lists.freedesktop.org \
--cc=jbarnes@virtuousgeek.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox