From: Lyude Paul <lyude@redhat.com>
To: "Ville Syrjälä" <ville.syrjala@linux.intel.com>
Cc: intel-gfx@lists.freedesktop.org,
Laura Abbott <labbott@redhat.com>,
Dhinakaran Pandiyan <dhinakaran.pandiyan@intel.com>,
stable@vger.kernel.org, Jani Nikula <jani.nikula@linux.intel.com>,
Joonas Lahtinen <joonas.lahtinen@linux.intel.com>,
Rodrigo Vivi <rodrigo.vivi@intel.com>,
David Airlie <airlied@linux.ie>,
dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH v2] drm/i915: Keep AUX block running when disabling DPMS for MST
Date: Wed, 04 Apr 2018 14:37:41 -0400 [thread overview]
Message-ID: <1522867061.12403.6.camel@redhat.com> (raw)
In-Reply-To: <20180404153429.GE5453@intel.com>
On Wed, 2018-04-04 at 18:34 +0300, Ville Syrjälä wrote:
> On Mon, Apr 02, 2018 at 05:26:16PM -0400, Lyude Paul wrote:
> > While enabling/disabling DPMS before link training with MST hubs is
> > perfectly valid; unfortunately disabling DPMS results in some devices
> > disabling their AUX CH block as well. For SST this isn't as much of a
> > problem, but for MST we need to be able to continue handling aux
> > transactions even when none of the sinks are turned on since it's
> > possible for us to have a single atomic commit which results in
> > disabling each downstream sink, followed by subsequently re-enabling
> > each sink.
> >
> > If we don't do this, we'll end up stalling any pending ESI interrupts
> > from the sink for up to 1ms. Unfortunately, dropping ESIs during this
> > timespan makes it so that link fallback retraining for MST (which I will
> > be submitting to the ML shortly) fails due to the channel EQ failure
> > interrupts potentially getting dropped. Additionally, when performing a
> > modeset that brings the hub status's link status from bad -> good having
> > ESIs disabled for that long causes us to miss the hub's response to us
> > trying to start link training as well.
> >
> > Since any sink with MST is going to support DisplayPort 1.2 anyway, save
> > us the hassle of trying to wait until the sink comes back up and just
> > never shut the aux block down.
> >
> > Changes since v2:
> > - Fix patch name, no functional changes
> >
> > Signed-off-by: Lyude Paul <lyude@redhat.com>
> > Cc: Laura Abbott <labbott@redhat.com>
> > Cc: Dhinakaran Pandiyan <dhinakaran.pandiyan@intel.com>
> > Cc: Ville Syrjälä <ville.syrjala@linux.intel.com>
> > Cc: stable@vger.kernel.org
> > Fixes: ad260ab32a4d9 ("drm/i915/dp: Write to SET_POWER dpcd to enable MST
> > hub.")
> > ---
> > drivers/gpu/drm/i915/intel_dp.c | 6 ++++--
> > 1 file changed, 4 insertions(+), 2 deletions(-)
> >
> > diff --git a/drivers/gpu/drm/i915/intel_dp.c
> > b/drivers/gpu/drm/i915/intel_dp.c
> > index 62f82c4298ac..0479c377981b 100644
> > --- a/drivers/gpu/drm/i915/intel_dp.c
> > +++ b/drivers/gpu/drm/i915/intel_dp.c
> > @@ -2589,11 +2589,13 @@ void intel_dp_sink_dpms(struct intel_dp *intel_dp,
> > int mode)
> > return;
> >
> > if (mode != DRM_MODE_DPMS_ON) {
> > + unsigned char data = intel_dp->is_mst ?
> > + DP_SET_POWER_D3_AUX_ON : DP_SET_POWER_D3;
>
> This smells like a workaround for an actual bug somewhere. Why exactly
> is the slower wakeup or the AUX block a problem for MST but not for SST
> when the link training is exactly the same for SST and MST?
I actually thought about this but I still think this is the appropriate fix.
So; the real reason for the wakeup not being a problem with SST is that for
DPMS on with SST, we actually do a wait to make sure that the hub is ready
before continuing. And yes: I'm fairly sure SST does actually have around the
same wakeup time that MST does, but with the wait we do it doesn't reallhy
make a difference. With MST, we could do this but there's a few reasons I
don't think we should:
* We don't need to. D3_AUX_ON is a part of the 1.2 spec, so any hub that has
MST is going to be guaranteed to have this.
* Turning off the aux block means that there's a high chance we're going to
miss ESIs from sinks
* It's faster to keep the aux block on anyway
>
> > +
> > if (downstream_hpd_needs_d0(intel_dp))
> > return;
> >
> > - ret = drm_dp_dpcd_writeb(&intel_dp->aux, DP_SET_POWER,
> > - DP_SET_POWER_D3);
> > + ret = drm_dp_dpcd_writeb(&intel_dp->aux, DP_SET_POWER,
> > data);
> > } else {
> > struct intel_lspcon *lspcon = dp_to_lspcon(intel_dp);
> >
> > --
> > 2.14.3
>
>
--
Cheers,
Lyude Paul
next prev parent reply other threads:[~2018-04-04 18:37 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-04-02 21:21 [PATCH] i915/dp_mst: Keep AUX block running when disabling DPMS Lyude Paul
2018-04-02 21:26 ` [PATCH v2] drm/i915: Keep AUX block running when disabling DPMS for MST Lyude Paul
2018-04-03 2:15 ` Laura Abbott
2018-04-04 15:34 ` Ville Syrjälä
2018-04-04 18:37 ` Lyude Paul [this message]
2018-04-04 18:53 ` Ville Syrjälä
2018-04-04 18:59 ` Lyude Paul
2018-04-04 19:31 ` Ville Syrjälä
2018-04-04 19:46 ` Lyude Paul
2018-04-04 19:00 ` Lyude Paul
2018-04-04 19:35 ` Ville Syrjälä
2018-04-04 20:11 ` Lyude Paul
2018-04-04 18:44 ` [Intel-gfx] " Manasi Navare
2018-04-04 18:48 ` Lyude Paul
2018-04-02 22:30 ` [PATCH] i915/dp_mst: Keep AUX block running when disabling DPMS Pandiyan, Dhinakaran
2018-04-05 16:42 ` Sasha Levin
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=1522867061.12403.6.camel@redhat.com \
--to=lyude@redhat.com \
--cc=airlied@linux.ie \
--cc=dhinakaran.pandiyan@intel.com \
--cc=dri-devel@lists.freedesktop.org \
--cc=intel-gfx@lists.freedesktop.org \
--cc=jani.nikula@linux.intel.com \
--cc=joonas.lahtinen@linux.intel.com \
--cc=labbott@redhat.com \
--cc=linux-kernel@vger.kernel.org \
--cc=rodrigo.vivi@intel.com \
--cc=stable@vger.kernel.org \
--cc=ville.syrjala@linux.intel.com \
/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;
as well as URLs for NNTP newsgroup(s).