Skip to content

Commit 4eaf02d

Browse files
drm/scheduler: fix drm_sched_job_add_implicit_dependencies
Trivial fix since we now need to grab a reference to the fence we have added. Previously the dma_resv function where doing that for us. Signed-off-by: Christian König <christian.koenig@amd.com> Fixes: 9c2ba26 ("drm/scheduler: use new iterator in drm_sched_job_add_implicit_dependencies v2") Link: https://patchwork.freedesktop.org/patch/msgid/20211019112706.27769-1-christian.koenig@amd.com Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch> Reported-by: Nicolas Frattaroli <frattaroli.nicolas@gmail.com> References: https://lore.kernel.org/dri-devel/2023306.UmlnhvANQh@archbook/ Tested-by: Nicolas Frattaroli <frattaroli.nicolas@gmail.com> Tested-by: Yassine Oudjana <y.oudjana@protonmail.com>
1 parent 467dd91 commit 4eaf02d

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

drivers/gpu/drm/scheduler/sched_main.c

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -707,6 +707,9 @@ int drm_sched_job_add_implicit_dependencies(struct drm_sched_job *job,
707707
ret = drm_sched_job_add_dependency(job, fence);
708708
if (ret)
709709
return ret;
710+
711+
/* Make sure to grab an additional ref on the added fence */
712+
dma_fence_get(fence);
710713
}
711714
return 0;
712715
}

0 commit comments

Comments
 (0)