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/dist/drm/radeon radeon_fence_signaled ...



details:   https://anonhg.NetBSD.org/src/rev/ba69e8b90973
branches:  trunk
changeset: 331272:ba69e8b90973
user:      riastradh <riastradh%NetBSD.org@localhost>
date:      Wed Aug 06 22:12:51 2014 +0000

description:
radeon_fence_signaled needs to take the fence lock.

diffstat:

 sys/external/bsd/drm2/dist/drm/radeon/radeon_fence.c |  4 ++++
 1 files changed, 4 insertions(+), 0 deletions(-)

diffs (21 lines):

diff -r 7e54f6060484 -r ba69e8b90973 sys/external/bsd/drm2/dist/drm/radeon/radeon_fence.c
--- a/sys/external/bsd/drm2/dist/drm/radeon/radeon_fence.c      Wed Aug 06 21:57:48 2014 +0000
+++ b/sys/external/bsd/drm2/dist/drm/radeon/radeon_fence.c      Wed Aug 06 22:12:51 2014 +0000
@@ -265,13 +265,17 @@
        if (!fence) {
                return true;
        }
+       spin_lock(&fence->rdev->fence_lock);
        if (fence->seq == RADEON_FENCE_SIGNALED_SEQ) {
+               spin_unlock(&fence->rdev->fence_lock);
                return true;
        }
        if (radeon_fence_seq_signaled(fence->rdev, fence->seq, fence->ring)) {
                fence->seq = RADEON_FENCE_SIGNALED_SEQ;
+               spin_unlock(&fence->rdev->fence_lock);
                return true;
        }
+       spin_unlock(&fence->rdev->fence_lock);
        return false;
 }
 



Home | Main Index | Thread Index | Old Index