]> git.proxmox.com Git - mirror_ubuntu-kernels.git/commitdiff
drm/amdgpu: use kernel fence interface when possible
authormonk.liu <monk.liu@amd.com>
Thu, 30 Jul 2015 06:56:18 +0000 (14:56 +0800)
committerAlex Deucher <alexander.deucher@amd.com>
Mon, 17 Aug 2015 20:50:47 +0000 (16:50 -0400)
Signed-off-by: monk.liu <monk.liu@amd.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
drivers/gpu/drm/amd/amdgpu/amdgpu_fence.c

index 67d9277d616847d27a5aa815e2aaf9826a571fbf..4834725b627e63c57b533c4d15c411e8dfc1484b 100644 (file)
@@ -622,18 +622,11 @@ static long amdgpu_fence_wait_seq_timeout(struct amdgpu_device *adev,
  */
 int amdgpu_fence_wait(struct amdgpu_fence *fence, bool intr)
 {
-       uint64_t seq[AMDGPU_MAX_RINGS] = {};
        long r;
 
-       seq[fence->ring->idx] = fence->seq;
-       r = amdgpu_fence_wait_seq_timeout(fence->ring->adev, seq, intr, MAX_SCHEDULE_TIMEOUT);
-       if (r < 0) {
-               return r;
-       }
-
-       r = fence_signal(&fence->base);
-       if (!r)
-               FENCE_TRACE(&fence->base, "signaled from fence_wait\n");
+       r = fence_wait_timeout(&fence->base, intr, MAX_SCHEDULE_TIMEOUT);
+       if (r < 0)
+               return  r;
        return 0;
 }