From: Daniel Vetter <daniel@ffwll.ch>
To: Matthew Auld <matthew.auld@intel.com>
Cc: intel-gfx@lists.freedesktop.org, dri-devel@lists.freedesktop.org,
"Thomas Hellström" <thomas.hellstrom@linux.intel.com>
Subject: Re: [Intel-gfx] [PATCH 2/2] drm/i915/dmabuf: drop the flush on discrete
Date: Thu, 28 Oct 2021 17:31:52 +0200 [thread overview]
Message-ID: <YXrCaBnFWxlD3zX4@phenom.ffwll.local> (raw)
In-Reply-To: <20211021125332.2455288-2-matthew.auld@intel.com>
On Thu, Oct 21, 2021 at 01:53:32PM +0100, Matthew Auld wrote:
> We were overzealous here; even though discrete is non-LLC, it should
> still be always coherent.
>
> Signed-off-by: Matthew Auld <matthew.auld@intel.com>
> Cc: Thomas Hellström <thomas.hellstrom@linux.intel.com>
> ---
> drivers/gpu/drm/i915/gem/i915_gem_dmabuf.c | 3 ++-
> 1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/gpu/drm/i915/gem/i915_gem_dmabuf.c b/drivers/gpu/drm/i915/gem/i915_gem_dmabuf.c
> index a45d0ec2c5b6..848e81368043 100644
> --- a/drivers/gpu/drm/i915/gem/i915_gem_dmabuf.c
> +++ b/drivers/gpu/drm/i915/gem/i915_gem_dmabuf.c
> @@ -251,7 +251,8 @@ static int i915_gem_object_get_pages_dmabuf(struct drm_i915_gem_object *obj)
> return PTR_ERR(pages);
>
> /* XXX: consider doing a vmap flush or something */
> - if (!HAS_LLC(i915) || i915_gem_object_can_bypass_llc(obj))
> + if ((!HAS_LLC(i915) && !IS_DGFX(i915)) ||
> + i915_gem_object_can_bypass_llc(obj))
> wbinvd_on_all_cpus();
I think a comment here why we do wbinvd and not clflush like everywhere
else here would be good. There's the XXX, but it's kinda not explaining
why vmap isn't a good idea.
Just an aside.
-Daneil
>
> sg_page_sizes = i915_sg_dma_sizes(pages->sgl);
> --
> 2.26.3
>
--
Daniel Vetter
Software Engineer, Intel Corporation
http://blog.ffwll.ch
next prev parent reply other threads:[~2021-10-28 15:31 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-10-21 12:53 [Intel-gfx] [PATCH 1/2] drm/i915/dmabuf: fix broken build Matthew Auld
2021-10-21 12:53 ` [Intel-gfx] [PATCH 2/2] drm/i915/dmabuf: drop the flush on discrete Matthew Auld
2021-10-22 9:26 ` Thomas Hellström
2021-10-22 9:47 ` Matthew Auld
2021-10-28 15:31 ` Daniel Vetter [this message]
2021-10-21 14:52 ` [Intel-gfx] ✗ Fi.CI.CHECKPATCH: warning for series starting with [1/2] drm/i915/dmabuf: fix broken build Patchwork
2021-10-21 15:18 ` [Intel-gfx] [PATCH 1/2] " Dixit, Ashutosh
2021-10-21 15:23 ` [Intel-gfx] ✓ Fi.CI.BAT: success for series starting with [1/2] " Patchwork
2021-10-21 18:16 ` [Intel-gfx] ✓ Fi.CI.IGT: " Patchwork
2021-10-27 7:57 ` [Intel-gfx] [PATCH 1/2] " Matthew Auld
2021-10-27 8:58 ` Jani Nikula
2021-10-27 9:00 ` Jani Nikula
2021-10-27 9:03 ` Matthew Auld
2021-10-27 9:44 ` Jani Nikula
2021-10-27 9:48 ` Matthew Auld
2021-10-28 1:43 ` Vivi, Rodrigo
2021-10-28 8:48 ` Matthew Auld
2021-11-22 13:34 ` Tvrtko Ursulin
2021-10-27 14:54 ` Lucas De Marchi
2021-10-27 16:23 ` Matthew Auld
2021-10-27 17:16 ` Lucas De Marchi
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=YXrCaBnFWxlD3zX4@phenom.ffwll.local \
--to=daniel@ffwll.ch \
--cc=dri-devel@lists.freedesktop.org \
--cc=intel-gfx@lists.freedesktop.org \
--cc=matthew.auld@intel.com \
--cc=thomas.hellstrom@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