From: Jesse Barnes Subject: Re: [PATCH 2/5] drm/i915: read full receiver capability field during DP hot plug Date: Mon, 17 Oct 2011 08:53:07 -0700 Message-ID: <20111017085307.1a68ef67@jbarnes-desktop> References: <1316670361-18412-1-git-send-email-jbarnes@virtuousgeek.org> <1316670361-18412-3-git-send-email-jbarnes@virtuousgeek.org> <20110922202909.5b39ab6c@jbarnes-x220> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============1253920666==" Return-path: Received: from oproxy1-pub.bluehost.com (oproxy1-pub.bluehost.com [66.147.249.253]) by gabe.freedesktop.org (Postfix) with SMTP id DE73A9F78A for ; Mon, 17 Oct 2011 08:53:16 -0700 (PDT) In-Reply-To: <20110922202909.5b39ab6c@jbarnes-x220> 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 Cc: intel-gfx@lists.freedesktop.org List-Id: intel-gfx@lists.freedesktop.org --===============1253920666== Content-Type: multipart/signed; micalg=PGP-SHA1; boundary="Sig_/lh=1ankGyVr9BBpLkivcEwn"; protocol="application/pgp-signature" --Sig_/lh=1ankGyVr9BBpLkivcEwn Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: quoted-printable On Thu, 22 Sep 2011 20:29:09 +0530 Jesse Barnes wrote: > On Thu, 22 Sep 2011 09:41:01 +0100 > Chris Wilson wrote: >=20 > > On Thu, 22 Sep 2011 11:15:58 +0530, Jesse Barnes > > wrote: > > > Read link status first, followed by the full DPCD receiver cap field > > > rather than just the first 8 bytes. > > >=20 > > > Signed-off-by: Jesse Barnes > > > --- > > > drivers/gpu/drm/i915/i915_irq.c | 2 ++ > > > drivers/gpu/drm/i915/intel_dp.c | 4 ++-- > > > 2 files changed, 4 insertions(+), 2 deletions(-) > > >=20 > > > diff --git a/drivers/gpu/drm/i915/i915_irq.c > > > b/drivers/gpu/drm/i915/i915_irq.c index 02f96fd..80b49cc 100644 > > > --- a/drivers/gpu/drm/i915/i915_irq.c > > > +++ b/drivers/gpu/drm/i915/i915_irq.c > > > @@ -530,6 +530,7 @@ static irqreturn_t > > > ivybridge_irq_handler(DRM_IRQ_ARGS) if (pch_iir & > > > SDE_HOTPLUG_MASK_CPT) queue_work(dev_priv->wq, > > > &dev_priv->hotplug_work); pch_irq_handler(dev); > > > + I915_WRITE(PCH_PORT_HOTPLUG, > > > I915_READ(PCH_PORT_HOTPLUG)); } > > > =20 > > > if (pm_iir & GEN6_PM_DEFERRED_EVENTS) { > > > @@ -629,6 +630,7 @@ static irqreturn_t > > > ironlake_irq_handler(DRM_IRQ_ARGS) if (pch_iir & hotplug_mask) > > > queue_work(dev_priv->wq, > > > &dev_priv->hotplug_work); pch_irq_handler(dev); > > > + I915_WRITE(PCH_PORT_HOTPLUG, > > > I915_READ(PCH_PORT_HOTPLUG)); } > >=20 > > This is a seperate chunk to the commit message. >=20 > Damnit, git commit -a should ask "do you really mean it?". >=20 > > > =20 > > > if (de_iir & DE_PCU_EVENT) { > > > diff --git a/drivers/gpu/drm/i915/intel_dp.c > > > b/drivers/gpu/drm/i915/intel_dp.c index 0feae90..01848f9 100644 > > > --- a/drivers/gpu/drm/i915/intel_dp.c > > > +++ b/drivers/gpu/drm/i915/intel_dp.c > > > @@ -36,7 +36,7 @@ > > > #include "i915_drv.h" > > > #include "drm_dp_helper.h" > > > =20 > > > - > > > +#define DP_RECEIVER_CAP_SIZE 0xf > > > #define DP_LINK_STATUS_SIZE 6 > > > #define DP_LINK_CHECK_TIMEOUT (10 * 1000) > > > =20 > > > @@ -53,7 +53,7 @@ struct intel_dp { > > > int dpms_mode; > > > uint8_t link_bw; > > > uint8_t lane_count; > > > - uint8_t dpcd[8]; > > > + uint8_t dpcd[DP_RECEIVER_CAP_SIZE]; > > > struct i2c_adapter adapter; > > > struct i2c_algo_dp_aux_data algo; > > > bool is_pch_edp; > >=20 > > So I'm not seeing the quick check followed by the full read as > > described. >=20 > Increasing the DPCD size here increases the read size to include the > full receiver caps field. We already read the link status at hot plug > time, so the commit message is a little misleading. The main fix here > is to read the full caps field rather than just the first 8 bytes. Sorry Keith, should have cc'd you on the other two replies to this thread as well. This one is mainly increasing the size of the DPCD array we use so that we read all the cap bytes instead of just the first 8. This makes some sinks (the compliance testing one at least) happier. I can re-post or you can just commit this by itself. Any preference? Thanks, --=20 Jesse Barnes, Intel Open Source Technology Center --Sig_/lh=1ankGyVr9BBpLkivcEwn Content-Type: application/pgp-signature; name=signature.asc Content-Disposition: attachment; filename=signature.asc -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.10 (GNU/Linux) iQIcBAEBAgAGBQJOnE9jAAoJEIEoDkX4Qk9heW0QAIwKlA0RQZ8gIL6PT6dNjuBn f0eTQR4mUFokt0YII5na8F7U9Nw08q3OvLbVinEWPKlOJoKbSyCtp6mqNHm3RKeI k0q6Nm9yH+YlaSWYDBj/CiapRbGKOoJOsuasWxFm65BtsNS3hev1pduv3lHhiglD dKc5Lb79BwAGn8ULIOQd6Nn0dlOUjp+WLNCSLhRHwCsJJCVfuTFWxSFN4FmnJgqM txS9mXbwaYeQBC9a4NB5PE/Ym1JNUCA663Zo3X4pwaMu3vcICyXfioi7p/dJ/ADT oYY8LMffMFXNjuSzgnea0yPHmDDiBsdR0tHoNdGimG5J0nikkfdZH5Wr25/axNCI rW2u1CVyaK4L4P6JAFn8AVJM1nHZYBaqHNt+orbKzXAXHiLZg8x4PGHibdGlfxFH vhhhJVFlrsrejydZGzTz67JnJLjlCj3bjrJlJXcHBWKku+mvtMNNh/dfjlSDk0yE ol9eGinevJaCJmf8mBFtOfEjnOUc1dYJMF/jGrcbbAR1oaTrN1YeOUgLws862gfZ yg2C11Q6JIt+pEgYtu/efFnhRUosTiG0wxZUseXoF5H4NxVps4/LVdeDvFGNB7Pw xCsUbyLkKuQ3EPQCUIq6pYKUsZdqzWMXRwzoEtqnQ46d5plNYuAa+WDEs2VbGBuK R5UW4pPad7IoY82Na+zU =rEMe -----END PGP SIGNATURE----- --Sig_/lh=1ankGyVr9BBpLkivcEwn-- --===============1253920666== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Intel-gfx mailing list Intel-gfx@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/intel-gfx --===============1253920666==--