From: "Ville Syrjälä" <ville.syrjala@linux.intel.com>
To: "Souza, Jose" <jose.souza@intel.com>
Cc: "intel-gfx@lists.freedesktop.org" <intel-gfx@lists.freedesktop.org>
Subject: Re: [Intel-gfx] [PATCH] drm/i915/display: Read planes watermarks during initial state readout
Date: Fri, 19 Feb 2021 22:33:50 +0200 [thread overview]
Message-ID: <YDAgri5FaAIIczRQ@intel.com> (raw)
In-Reply-To: <3c15a574a5673471c2e3b747e24e4608c3b49f31.camel@intel.com>
On Fri, Feb 19, 2021 at 08:16:25PM +0000, Souza, Jose wrote:
> On Fri, 2021-02-19 at 21:46 +0200, Ville Syrjälä wrote:
> > On Fri, Feb 19, 2021 at 11:16:23AM -0800, José Roberto de Souza wrote:
> > > Without this readout all plane watermarks will be kept at zero in the
> > > initial state readount causing two problems.
> > >
> > > All active planes will always have their watermarks programmed
> > > again, even if what firmware programmed matches with the sanitized
> > > state during driver takeover.
> > >
> > > State mismatch errors in disabled planes as watermarks will erroneous
> > > match with the calculated state if firmware left watermark registers
> > > with non-zero values.
> > >
> > > Cc: Ville Syrjälä <ville.syrjala@linux.intel.com>
> > > Signed-off-by: José Roberto de Souza <jose.souza@intel.com>
> > > ---
> > > drivers/gpu/drm/i915/display/intel_display.c | 2 ++
> > > 1 file changed, 2 insertions(+)
> > >
> > > diff --git a/drivers/gpu/drm/i915/display/intel_display.c b/drivers/gpu/drm/i915/display/intel_display.c
> > > index d0da88751c72..14fba4411be7 100644
> > > --- a/drivers/gpu/drm/i915/display/intel_display.c
> > > +++ b/drivers/gpu/drm/i915/display/intel_display.c
> > > @@ -13620,6 +13620,8 @@ static void intel_modeset_readout_hw_state(struct drm_device *dev)
> > > drm_calc_timestamping_constants(&slave->base,
> > > &slave_crtc_state->hw.adjusted_mode);
> > > }
> > > +
> > > + skl_pipe_wm_get_hw_state(crtc, &crtc_state->wm.skl.optimal);
> >
> > Strange. skl_wm_get_hw_state() should be doing this already.
>
> It is only doing some ddb readouts noting related to plane watermarks, maybe call skl_pipe_wm_get_hw_state() from there would be better?
The call is definitely there in my copy of the code:
skl_wm_get_hw_state(struct drm_i915_private *dev_priv)
{
struct intel_dbuf_state *dbuf_state =
to_intel_dbuf_state(dev_priv->dbuf.obj.state);
struct intel_crtc *crtc;
for_each_intel_crtc(&dev_priv->drm, crtc) {
struct intel_crtc_state *crtc_state =
to_intel_crtc_state(crtc->base.state);
enum pipe pipe = crtc->pipe;
enum plane_id plane_id;
skl_pipe_wm_get_hw_state(crtc, &crtc_state->wm.skl.optimal);
...
--
Ville Syrjälä
Intel
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
next prev parent reply other threads:[~2021-02-19 20:33 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-02-19 19:16 [Intel-gfx] [PATCH] drm/i915/display: Read planes watermarks during initial state readout José Roberto de Souza
2021-02-19 19:46 ` Ville Syrjälä
2021-02-19 20:16 ` Souza, Jose
2021-02-19 20:33 ` Ville Syrjälä [this message]
2021-02-19 20:15 ` [Intel-gfx] ✓ Fi.CI.BAT: success for " Patchwork
2021-02-19 21:43 ` [Intel-gfx] ✓ Fi.CI.IGT: " 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=YDAgri5FaAIIczRQ@intel.com \
--to=ville.syrjala@linux.intel.com \
--cc=intel-gfx@lists.freedesktop.org \
--cc=jose.souza@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.