From: Matt Roper <matthew.d.roper@intel.com>
To: Stanislav Lisovskiy <stanislav.lisovskiy@intel.com>
Cc: jani.nikula@intel.com, intel-gfx@lists.freedesktop.org
Subject: Re: [Intel-gfx] [PATCH v1 1/3] drm/i915: Ensure no conflicts with BIOS when updating Dbuf
Date: Thu, 13 Feb 2020 12:25:33 -0800 [thread overview]
Message-ID: <20200213202533.GH2014153@mdroper-desk1.amr.corp.intel.com> (raw)
In-Reply-To: <20200213140412.32697-2-stanislav.lisovskiy@intel.com>
On Thu, Feb 13, 2020 at 04:04:10PM +0200, Stanislav Lisovskiy wrote:
> TGL BIOS seems to enable both DBuf slices ocasionally, depending
> how many displays are connected, while i915 according to BSpec
> was powering on S1 DBuf slice, until a modeset was done.
>
> This was causing a brief flash during the boot as we were
> disabling slice, previously used by BIOS with that.
>
> To prevent this, now we are ensuring tht we are enabling
> _at least_ one slice, but if there are more, let's not
> power them off.
>
> Fixes: ff2cd8635e41 ("drm/i915: Correctly map DBUF slices to pipes")
> Signed-off-by: Stanislav Lisovskiy <stanislav.lisovskiy@intel.com>
> ---
> drivers/gpu/drm/i915/display/intel_display_power.c | 6 ++++--
> 1 file changed, 4 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/gpu/drm/i915/display/intel_display_power.c b/drivers/gpu/drm/i915/display/intel_display_power.c
> index 53056def5414..b9a9cbad8a03 100644
> --- a/drivers/gpu/drm/i915/display/intel_display_power.c
> +++ b/drivers/gpu/drm/i915/display/intel_display_power.c
> @@ -4470,11 +4470,13 @@ void icl_dbuf_slices_update(struct drm_i915_private *dev_priv,
>
> static void icl_dbuf_enable(struct drm_i915_private *dev_priv)
> {
> + skl_ddb_get_hw_state(dev_priv);
Might want to add a blank line here to make it visually easier to read.
> /*
> - * Just power up 1 slice, we will
> + * Just power up at least 1 slice, we will
You might want to say "at least slice S1" since if the BIOS were to
initialize only S2, that wouldn't be sufficient for us (according to the
bspec).
> * figure out later which slices we have and what we need.
> */
> - icl_dbuf_slices_update(dev_priv, BIT(DBUF_S1));
> + icl_dbuf_slices_update(dev_priv, dev_priv->enabled_dbuf_slices_mask |
> + BIT(DBUF_S1));
We could potentially avoid some unnecessary work by checking whether
what we read back above was already good enough or not.
if (!(dev_priv->enabled_dbuf_slices_mask & BIT(DBUF_S1)))
icl_dbuf_slices_update(...)
But either way,
Reviewed-by: Matt Roper <matthew.d.roper@intel.com>
> }
>
> static void icl_dbuf_disable(struct drm_i915_private *dev_priv)
> --
> 2.24.1.485.gad05a3d8e5
>
> _______________________________________________
> Intel-gfx mailing list
> Intel-gfx@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/intel-gfx
--
Matt Roper
Graphics Software Engineer
VTT-OSGC Platform Enablement
Intel Corporation
(916) 356-2795
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
next prev parent reply other threads:[~2020-02-13 20:25 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-02-13 14:04 [Intel-gfx] [PATCH v1 0/3] Fix modeset transitions related to DBuf Stanislav Lisovskiy
2020-02-13 14:04 ` [Intel-gfx] [PATCH v1 1/3] drm/i915: Ensure no conflicts with BIOS when updating Dbuf Stanislav Lisovskiy
2020-02-13 20:25 ` Matt Roper [this message]
2020-02-13 14:04 ` [Intel-gfx] [PATCH v1 2/3] drm/i915/dsc: force full modeset whenever DSC is enabled at probe Stanislav Lisovskiy
2020-02-13 20:56 ` Matt Roper
2020-02-13 21:03 ` Jani Nikula
2020-02-13 21:06 ` Matt Roper
2020-02-13 21:21 ` Jani Nikula
2020-02-13 14:04 ` [Intel-gfx] [PATCH v1 3/3] drm/i915: Force state->modeset=true when distrust_bios_wm==true Stanislav Lisovskiy
2020-02-13 21:08 ` Matt Roper
2020-02-13 16:39 ` [Intel-gfx] ✗ Fi.CI.CHECKPATCH: warning for Fix modeset transitions related to DBuf Patchwork
2020-02-13 17:10 ` [Intel-gfx] ✓ Fi.CI.BAT: success " Patchwork
2020-02-15 12:33 ` [Intel-gfx] ✓ Fi.CI.IGT: " Patchwork
2020-02-15 18:27 ` [Intel-gfx] [PATCH v1 0/3] " Jani Nikula
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=20200213202533.GH2014153@mdroper-desk1.amr.corp.intel.com \
--to=matthew.d.roper@intel.com \
--cc=intel-gfx@lists.freedesktop.org \
--cc=jani.nikula@intel.com \
--cc=stanislav.lisovskiy@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).