diff options
author | Christian König <christian.koenig@amd.com> | 2022-07-11 16:48:01 +0200 |
---|---|---|
committer | Christian König <christian.koenig@amd.com> | 2022-07-12 17:13:55 +0200 |
commit | bbd60fee2d2166b2b8722cbad740996ef2e7ce40 (patch) | |
tree | f206d78c37e30eef9edea5c4003589ffd0d43afc /drivers/dma-buf | |
parent | fc8d29e298cf47e07c2764ec1c340c1df8e50431 (diff) |
dma-buf: revert "return only unsignaled fences in dma_fence_unwrap_for_each v3"
This reverts commit 8f61973718485f3e89bc4f408f929048b7b47c83.
It turned out that this is not correct. Especially the sync_file info
IOCTL needs to see even signaled fences to correctly report back their
status to userspace.
Instead add the filter in the merge function again where it makes sense.
Signed-off-by: Christian König <christian.koenig@amd.com>
Tested-by: Karolina Drobnik <karolina.drobnik@intel.com>
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20220712102849.1562-1-christian.koenig@amd.com
Diffstat (limited to 'drivers/dma-buf')
-rw-r--r-- | drivers/dma-buf/dma-fence-unwrap.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/dma-buf/dma-fence-unwrap.c b/drivers/dma-buf/dma-fence-unwrap.c index 502a65ea6d44..7002bca792ff 100644 --- a/drivers/dma-buf/dma-fence-unwrap.c +++ b/drivers/dma-buf/dma-fence-unwrap.c @@ -72,7 +72,8 @@ struct dma_fence *__dma_fence_unwrap_merge(unsigned int num_fences, count = 0; for (i = 0; i < num_fences; ++i) { dma_fence_unwrap_for_each(tmp, &iter[i], fences[i]) - ++count; + if (!dma_fence_is_signaled(tmp)) + ++count; } if (count == 0) |