From: "Souza, Jose" <jose.souza@intel.com>
To: "Deak, Imre" <imre.deak@intel.com>
Cc: "intel-gfx@lists.freedesktop.org" <intel-gfx@lists.freedesktop.org>
Subject: Re: [Intel-gfx] [PATCH 1/6] drm/i915/tgl+: Use the correct DP_TP_* register instances in MST encoders
Date: Tue, 16 Jun 2020 17:02:10 +0000 [thread overview]
Message-ID: <afab588c525d40b6b02347645808ce159bc4b44b.camel@intel.com> (raw)
In-Reply-To: <20200616164209.GD21389@ideak-desk.fi.intel.com>
On Tue, 2020-06-16 at 19:42 +0300, Imre Deak wrote:
> On Tue, Jun 16, 2020 at 07:32:46PM +0300, Souza, Jose wrote:
> > On Tue, 2020-06-16 at 17:18 +0300, Imre Deak wrote:
> > > MST encoders must use the master MST transcoder's DP_TP_STATUS and
> > > DP_TP_CONTROL registers. Atm, during the HW readout of a slave
> > > transcoder's CRTC state we reset these register addresses in
> > > intel_dp::regs.dp_tp_* to the slave transcoder's DP_TP_* register
> > > addresses incorrectly; fix this.
> > >
> > > This issue led at least to
> > > 'Timed out waiting for ACT sent when disabling'
> > > errors during output disabling in a multiple MST stream config.
> >
> > Can you point to place where dp_tp_ctl is used and cause this? All
> > the MST code paths uses the dp_tp_ctl of the main intel_dp(the one
> > that is not a mst connector).
>
> During a slave stream disabling when waiting for the ACT sent flag for
> that stream.
>
> > > This change replaces
> > > https://patchwork.freedesktop.org/patch/369577/?series=78193&rev=1
> > > which just papered over the problem.
> > >
> > > Cc: Ville Syrjälä <ville.syrjala@linux.intel.com>
> > > Cc: José Roberto de Souza <jose.souza@intel.com>
> > > Signed-off-by: Imre Deak <imre.deak@intel.com>
> > > ---
> > > drivers/gpu/drm/i915/display/intel_ddi.c | 15 ++++++++++-----
> > > 1 file changed, 10 insertions(+), 5 deletions(-)
> > >
> > > diff --git a/drivers/gpu/drm/i915/display/intel_ddi.c b/drivers/gpu/drm/i915/display/intel_ddi.c
> > > index ca7bb2294d2b..73d6cc29291a 100644
> > > --- a/drivers/gpu/drm/i915/display/intel_ddi.c
> > > +++ b/drivers/gpu/drm/i915/display/intel_ddi.c
> > > @@ -4193,11 +4193,6 @@ void intel_ddi_get_config(struct intel_encoder *encoder,
> > > if (drm_WARN_ON(&dev_priv->drm, transcoder_is_dsi(cpu_transcoder)))
> > > return;
> > >
> > > - if (INTEL_GEN(dev_priv) >= 12) {
> > > - intel_dp->regs.dp_tp_ctl = TGL_DP_TP_CTL(cpu_transcoder);
> > > - intel_dp->regs.dp_tp_status = TGL_DP_TP_STATUS(cpu_transcoder);
> > > - }
> > > -
> > > intel_dsc_get_config(encoder, pipe_config);
> > >
> > > temp = intel_de_read(dev_priv, TRANS_DDI_FUNC_CTL(cpu_transcoder));
> > > @@ -4299,6 +4294,16 @@ void intel_ddi_get_config(struct intel_encoder *encoder,
> > > break;
> > > }
> > >
> > > + if (INTEL_GEN(dev_priv) >= 12) {
> > > + enum transcoder transcoder =
> > > + intel_dp_mst_is_slave_trans(pipe_config) ?
> > > + pipe_config->mst_master_transcoder :
> > > + pipe_config->cpu_transcoder;
> > > +
> > > + intel_dp->regs.dp_tp_ctl = TGL_DP_TP_CTL(transcoder);
> > > + intel_dp->regs.dp_tp_status = TGL_DP_TP_STATUS(transcoder);
> > > + }
> >
> > Also not sure how change only in the config readout would fix the issue,
>
> After a modeset we'll verify the HW state. The readout for a slave
> stream CRTC (get_pipe_config) running after the master CRTC's readout
> will overwrite the dp_tp reg addresses. The other instance of dp_tp
> register address init (in tgl_ddi_pre_enable_dp()) is correct.
intel_mst_post_disable_dp()
struct intel_digital_port *intel_dig_port = intel_mst->primary;
struct intel_dp *intel_dp = &intel_dig_port->dp;
...
if (intel_de_wait_for_set(dev_priv, intel_dp->regs.dp_tp_status,
DP_TP_STATUS_ACT_SENT, 1))
drm_err(&dev_priv->drm, "Timed out waiting for ACT sent when disabling\n");
Until here is right, but yeah bellow is the problem:
static void intel_dp_mst_enc_get_config(struct intel_encoder *encoder,
struct intel_crtc_state *pipe_config)
{
struct intel_dp_mst_encoder *intel_mst = enc_to_mst(encoder);
struct intel_digital_port *intel_dig_port = intel_mst->primary;
intel_ddi_get_config(&intel_dig_port->base, pipe_config);
}
It will be overwritten with the transcoder of the last crtc read.Would suggest to add something about intel_dp_mst_enc_get_config() to the commit
description but the change looks good now.
>
> > IFWI don't enable MST so when i915 takes over a full modeset will
> > happen to enable MST and only dp_tp_ctl of the main intel_dp(the one
> > that is not a mst connector) will be set, check
> > tgl_ddi_pre_enable_dp().
> >
> > > +
> > > pipe_config->has_audio =
> > > intel_ddi_is_audio_enabled(dev_priv, cpu_transcoder);
> > >
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
next prev parent reply other threads:[~2020-06-16 17:02 UTC|newest]
Thread overview: 34+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-06-16 14:18 [Intel-gfx] [PATCH 1/6] drm/i915/tgl+: Use the correct DP_TP_* register instances in MST encoders Imre Deak
2020-06-16 14:18 ` [Intel-gfx] [PATCH 2/6] drm/i915/dp_mst: Disable link training fallback on MST links Imre Deak
2020-06-16 15:22 ` Ville Syrjälä
2020-06-16 15:30 ` Imre Deak
2020-06-16 15:39 ` Ville Syrjälä
2020-06-16 15:49 ` Imre Deak
2020-06-16 16:20 ` Ville Syrjälä
2020-06-16 21:11 ` [Intel-gfx] [PATCH v2 " Imre Deak
2020-06-16 14:18 ` [Intel-gfx] [PATCH 3/6] drm/i915/dp_mst: Move clearing the ACT sent flag closer to its polling Imre Deak
2020-06-16 15:47 ` Ville Syrjälä
2020-06-16 14:18 ` [Intel-gfx] [PATCH 4/6] drm/i915/dp_mst: Clear only the ACT sent flag from DP_TP_STATUS Imre Deak
2020-06-16 15:47 ` Ville Syrjälä
2020-06-16 14:18 ` [Intel-gfx] [PATCH 5/6] drm/i915/dp_mst: Clear the ACT sent flag during encoder disabling too Imre Deak
2020-06-16 15:47 ` Ville Syrjälä
2020-06-16 14:18 ` [Intel-gfx] [PATCH 6/6] drm/i915/dp_mst: Ensure the DPCD ACT sent flag is cleared before waiting for it Imre Deak
2020-06-16 15:45 ` Ville Syrjälä
2020-06-16 15:54 ` Imre Deak
2020-06-16 16:23 ` Ville Syrjälä
2020-06-16 16:40 ` Ville Syrjälä
2020-06-16 16:47 ` Imre Deak
2020-06-16 21:11 ` [Intel-gfx] [PATCH v2 " Imre Deak
2020-06-17 15:27 ` Lyude Paul
2020-06-23 7:30 ` Imre Deak
2020-06-16 15:46 ` [Intel-gfx] [PATCH 1/6] drm/i915/tgl+: Use the correct DP_TP_* register instances in MST encoders Ville Syrjälä
2020-06-16 16:32 ` Souza, Jose
2020-06-16 16:42 ` Imre Deak
2020-06-16 17:02 ` Souza, Jose [this message]
2020-06-16 17:32 ` Imre Deak
2020-06-16 19:50 ` [Intel-gfx] ✓ Fi.CI.BAT: success for series starting with [1/6] " Patchwork
2020-06-16 21:11 ` [Intel-gfx] [PATCH v2 1/6] " Imre Deak
2020-06-16 22:38 ` Souza, Jose
2020-06-16 22:16 ` [Intel-gfx] ✓ Fi.CI.IGT: success for series starting with [1/6] " Patchwork
2020-06-23 7:21 ` Imre Deak
2020-06-16 23:36 ` [Intel-gfx] ✓ Fi.CI.BAT: success for series starting with [v2,1/6] drm/i915/tgl+: Use the correct DP_TP_* register instances in MST encoders (rev4) Patchwork
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=afab588c525d40b6b02347645808ce159bc4b44b.camel@intel.com \
--to=jose.souza@intel.com \
--cc=imre.deak@intel.com \
--cc=intel-gfx@lists.freedesktop.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