From: Rob Clark <robdclark@gmail.com>
To: dri-devel@lists.freedesktop.org
Cc: freedreno@lists.freedesktop.org,
"Daniel Vetter" <daniel@ffwll.ch>,
"Christian König" <ckoenig.leichtzumerken@gmail.com>,
"Michel Dänzer" <michel@daenzer.net>,
"Tvrtko Ursulin" <tvrtko.ursulin@intel.com>,
"Rodrigo Vivi" <rodrigo.vivi@intel.com>,
"Alex Deucher" <alexander.deucher@amd.com>,
"Pekka Paalanen" <ppaalanen@gmail.com>,
"Simon Ser" <contact@emersion.fr>,
"Luben Tuikov" <luben.tuikov@amd.com>,
"Rob Clark" <robdclark@chromium.org>,
"Christian König" <christian.koenig@amd.com>,
"Sumit Semwal" <sumit.semwal@linaro.org>,
"Gustavo Padovan" <gustavo@padovan.org>,
linux-media@vger.kernel.org (open list:SYNC FILE FRAMEWORK),
linaro-mm-sig@lists.linaro.org (moderated list:DMA BUFFER
SHARING FRAMEWORK), linux-kernel@vger.kernel.org (open list)
Subject: [PATCH v8 03/16] dma-buf/fence-chain: Add fence deadline support
Date: Tue, 28 Feb 2023 14:58:07 -0800 [thread overview]
Message-ID: <20230228225833.2920879-4-robdclark@gmail.com> (raw)
In-Reply-To: <20230228225833.2920879-1-robdclark@gmail.com>
From: Rob Clark <robdclark@chromium.org>
Propagate the deadline to all the fences in the chain.
v2: Use dma_fence_chain_contained [Tvrtko]
Signed-off-by: Rob Clark <robdclark@chromium.org>
Reviewed-by: Christian König <christian.koenig@amd.com> for this one.
---
drivers/dma-buf/dma-fence-chain.c | 12 ++++++++++++
1 file changed, 12 insertions(+)
diff --git a/drivers/dma-buf/dma-fence-chain.c b/drivers/dma-buf/dma-fence-chain.c
index a0d920576ba6..9663ba1bb6ac 100644
--- a/drivers/dma-buf/dma-fence-chain.c
+++ b/drivers/dma-buf/dma-fence-chain.c
@@ -206,6 +206,17 @@ static void dma_fence_chain_release(struct dma_fence *fence)
dma_fence_free(fence);
}
+
+static void dma_fence_chain_set_deadline(struct dma_fence *fence,
+ ktime_t deadline)
+{
+ dma_fence_chain_for_each(fence, fence) {
+ struct dma_fence *f = dma_fence_chain_contained(fence);
+
+ dma_fence_set_deadline(f, deadline);
+ }
+}
+
const struct dma_fence_ops dma_fence_chain_ops = {
.use_64bit_seqno = true,
.get_driver_name = dma_fence_chain_get_driver_name,
@@ -213,6 +224,7 @@ const struct dma_fence_ops dma_fence_chain_ops = {
.enable_signaling = dma_fence_chain_enable_signaling,
.signaled = dma_fence_chain_signaled,
.release = dma_fence_chain_release,
+ .set_deadline = dma_fence_chain_set_deadline,
};
EXPORT_SYMBOL(dma_fence_chain_ops);
--
2.39.1
next prev parent reply other threads:[~2023-02-28 22:58 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-02-28 22:58 [PATCH v8 00/16] dma-fence: Deadline awareness Rob Clark
2023-02-28 22:58 ` [PATCH v8 01/16] dma-buf/dma-fence: Add deadline awareness Rob Clark
2023-03-01 8:28 ` Bagas Sanjaya
2023-02-28 22:58 ` [PATCH v8 02/16] dma-buf/fence-array: Add fence deadline support Rob Clark
2023-02-28 22:58 ` Rob Clark [this message]
2023-02-28 22:58 ` [PATCH v8 04/16] dma-buf/dma-resv: Add a way to set fence deadline Rob Clark
2023-02-28 22:58 ` [PATCH v8 05/16] dma-buf/sync_file: Surface sync-file uABI Rob Clark
2023-03-01 8:52 ` Pekka Paalanen
2023-02-28 22:58 ` [PATCH v8 06/16] dma-buf/sync_file: Add SET_DEADLINE ioctl Rob Clark
2023-02-28 22:58 ` [PATCH v8 07/16] dma-buf/sync_file: Support (E)POLLPRI Rob Clark
2023-02-28 22:58 ` [PATCH v8 08/16] dma-buf/sw_sync: Add fence deadline support Rob Clark
2023-03-01 8:57 ` Pekka Paalanen
2023-02-28 22:58 ` [PATCH v8 09/16] drm/scheduler: " Rob Clark
2023-02-28 22:58 ` [PATCH v8 13/16] drm/msm: Add deadline based boost support Rob Clark
2023-02-28 22:58 ` [PATCH v8 16/16] drm/i915: " Rob Clark
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=20230228225833.2920879-4-robdclark@gmail.com \
--to=robdclark@gmail.com \
--cc=alexander.deucher@amd.com \
--cc=christian.koenig@amd.com \
--cc=ckoenig.leichtzumerken@gmail.com \
--cc=contact@emersion.fr \
--cc=daniel@ffwll.ch \
--cc=dri-devel@lists.freedesktop.org \
--cc=freedreno@lists.freedesktop.org \
--cc=gustavo@padovan.org \
--cc=linaro-mm-sig@lists.linaro.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-media@vger.kernel.org \
--cc=luben.tuikov@amd.com \
--cc=michel@daenzer.net \
--cc=ppaalanen@gmail.com \
--cc=robdclark@chromium.org \
--cc=rodrigo.vivi@intel.com \
--cc=sumit.semwal@linaro.org \
--cc=tvrtko.ursulin@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