Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/external/bsd/drm2/linux linux dma-fence: Use dma_fence_d...



details:   https://anonhg.NetBSD.org/src/rev/1d8d0d87cec6
branches:  trunk
changeset: 1028484:1d8d0d87cec6
user:      riastradh <riastradh%NetBSD.org@localhost>
date:      Sun Dec 19 11:09:09 2021 +0000

description:
linux dma-fence: Use dma_fence_default_wait if .wait is null.

diffstat:

 sys/external/bsd/drm2/linux/linux_dma_fence.c |  9 ++++++---
 1 files changed, 6 insertions(+), 3 deletions(-)

diffs (30 lines):

diff -r 5669dab7349e -r 1d8d0d87cec6 sys/external/bsd/drm2/linux/linux_dma_fence.c
--- a/sys/external/bsd/drm2/linux/linux_dma_fence.c     Sun Dec 19 11:09:02 2021 +0000
+++ b/sys/external/bsd/drm2/linux/linux_dma_fence.c     Sun Dec 19 11:09:09 2021 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: linux_dma_fence.c,v 1.13 2021/12/19 11:04:50 riastradh Exp $   */
+/*     $NetBSD: linux_dma_fence.c,v 1.14 2021/12/19 11:09:09 riastradh Exp $   */
 
 /*-
  * Copyright (c) 2018 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: linux_dma_fence.c,v 1.13 2021/12/19 11:04:50 riastradh Exp $");
+__KERNEL_RCSID(0, "$NetBSD: linux_dma_fence.c,v 1.14 2021/12/19 11:09:09 riastradh Exp $");
 
 #include <sys/atomic.h>
 #include <sys/condvar.h>
@@ -745,7 +745,10 @@
        KASSERT(timeout >= 0);
        KASSERT(timeout < MAX_SCHEDULE_TIMEOUT);
 
-       return (*fence->ops->wait)(fence, intr, timeout);
+       if (fence->ops->wait)
+               return (*fence->ops->wait)(fence, intr, timeout);
+       else
+               return dma_fence_default_wait(fence, intr, timeout);
 }
 
 /*



Home | Main Index | Thread Index | Old Index