public inbox for linux-media@vger.kernel.org
 help / color / mirror / Atom feed
From: Daniel Vetter <daniel@ffwll.ch>
To: "Christian König" <ckoenig.leichtzumerken@gmail.com>
Cc: dri-devel@lists.freedesktop.org, chris@chris-wilson.co.uk,
	daniel.vetter@ffwll.ch, sumit.semwal@linaro.org,
	linux-media@vger.kernel.org, linaro-mm-sig@lists.linaro.org
Subject: Re: Use dma_fence_array for implementing shared dma_resv fences
Date: Tue, 27 Aug 2019 18:37:41 +0200	[thread overview]
Message-ID: <20190827163741.GD2112@phenom.ffwll.local> (raw)
In-Reply-To: <20190826145731.1725-1-christian.koenig@amd.com>

On Mon, Aug 26, 2019 at 04:57:22PM +0200, Christian König wrote:
> This is the new dma_fence_array based container for shared fences in the
> dma_resv object.
> 
> Advantage of this approach is that you can grab a reference to the
> current set of shared fences at any time, which allows us to drop the
> sequence number increment and makes the whole RCU handling much more
> easier.
> 
> Disadvantage is that RCU users now have to grab a reference instead of
> using the sequence counter. As far as I can see i915 was actually the
> only driver doing this.
> 
> So we optimize for adding more fences instead of reading them now.
> 
> Another behavior change worth noting is that the shared fences are now
> only visible after unlocking the dma_resv object or calling
> dma_resv_fences_commit() manually.

I think more specific point for publishing fences makes a lot of sense, so
this sounds like a solid improvement on the dma_resv api. I'm working on
some dma_fence instrumentation where that at least might be useful.

/me back to burried state

Cheers, Daniel
-- 
Daniel Vetter
Software Engineer, Intel Corporation
http://blog.ffwll.ch

      parent reply	other threads:[~2019-08-27 16:37 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-08-26 14:57 Use dma_fence_array for implementing shared dma_resv fences Christian König
2019-08-26 14:57 ` [PATCH 1/9] dma-buf: fix dma_fence_array_signaled Christian König
2019-08-27 11:44   ` Chris Wilson
2019-08-26 14:57 ` [PATCH 2/9] dma-buf: make to_dma_fence_array NULL safe Christian König
2019-08-30 16:07   ` Ruhl, Michael J
2019-08-26 14:57 ` [PATCH 3/9] dma-buf: add dma_fence_array_alloc/free Christian König
2019-08-26 14:57 ` [PATCH 4/9] dma-buf: add dma_fence_array_recycle v2 Christian König
2019-08-26 14:57 ` [PATCH 5/9] dma-buf: add dma_fence_array_for_each Christian König
2019-08-26 14:57 ` [PATCH 6/9] dma-buf/resv: add dma_resv_prune_fences v2 Christian König
2019-08-26 14:57 ` [PATCH 7/9] dma-buf/resv: add new fences container implementation Christian König
2019-08-26 14:57 ` [PATCH 8/9] dma-buf/resv: use new dma_fence_array based implementation Christian König
2019-08-26 14:57 ` [PATCH 9/9] dma-buf/resv: drop the sequence count Christian König
2019-08-27 16:37 ` Daniel Vetter [this message]

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=20190827163741.GD2112@phenom.ffwll.local \
    --to=daniel@ffwll.ch \
    --cc=chris@chris-wilson.co.uk \
    --cc=ckoenig.leichtzumerken@gmail.com \
    --cc=daniel.vetter@ffwll.ch \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=linaro-mm-sig@lists.linaro.org \
    --cc=linux-media@vger.kernel.org \
    --cc=sumit.semwal@linaro.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