drm/amdgpu: remove fence reset detection leftovers
authorChristian König <christian.koenig@amd.com>
Thu, 11 Feb 2016 13:42:33 +0000 (14:42 +0100)
committerAlex Deucher <alexander.deucher@amd.com>
Tue, 16 Feb 2016 22:22:16 +0000 (17:22 -0500)
wait_event() never returns before the fence was signaled.

Signed-off-by: Christian König <christian.koenig@amd.com>
Acked-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/amdgpu/amdgpu_fence.c

index 72105020086cc3662831f5b87a4c342f9a371f49..97db196dc6f836371c309eaebbd669991934c4b8 100644 (file)
@@ -260,19 +260,16 @@ static bool amdgpu_fence_seq_signaled(struct amdgpu_ring *ring, u64 seq)
 }
 
 /*
- * amdgpu_ring_wait_seq_timeout - wait for seq of the specific ring to signal
+ * amdgpu_ring_wait_seq - wait for seq of the specific ring to signal
  * @ring: ring to wait on for the seq number
  * @seq: seq number wait for
  *
  * return value:
  * 0: seq signaled, and gpu not hang
- * -EDEADL: GPU hang detected
  * -EINVAL: some paramter is not valid
  */
 static int amdgpu_fence_ring_wait_seq(struct amdgpu_ring *ring, uint64_t seq)
 {
-       bool signaled = false;
-
        BUG_ON(!ring);
        if (seq > ring->fence_drv.sync_seq)
                return -EINVAL;
@@ -281,13 +278,10 @@ static int amdgpu_fence_ring_wait_seq(struct amdgpu_ring *ring, uint64_t seq)
                return 0;
 
        amdgpu_fence_schedule_fallback(ring);
-       wait_event(ring->fence_drv.fence_queue, (
-                  (signaled = amdgpu_fence_seq_signaled(ring, seq))));
+       wait_event(ring->fence_drv.fence_queue,
+                  amdgpu_fence_seq_signaled(ring, seq));
 
-       if (signaled)
-               return 0;
-       else
-               return -EDEADLK;
+       return 0;
 }
 
 /**