Skip to content

Commit

Permalink
drm/amdgpu: add zero timeout check in amdgpu_fence_wait_seq_timeout
Browse files Browse the repository at this point in the history
Signed-off-by: Jack Xiao <Jack.Xiao@amd.com>
Reviewed-by: Jammy Zhou <Jammy.Zhou@amd.com>
  • Loading branch information
Jack Xiao authored and Alex Deucher committed Jun 5, 2015
1 parent ae45577 commit 25f45e6
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions drivers/gpu/drm/amd/amdgpu/amdgpu_fence.c
Original file line number Diff line number Diff line change
Expand Up @@ -522,6 +522,10 @@ long amdgpu_fence_wait_seq_timeout(struct amdgpu_device *adev, u64 *target_seq,
bool signaled;
int i, r;

if (timeout == 0) {
return amdgpu_fence_any_seq_signaled(adev, target_seq);
}

while (!amdgpu_fence_any_seq_signaled(adev, target_seq)) {

/* Save current sequence values, used to check for GPU lockups */
Expand Down

0 comments on commit 25f45e6

Please sign in to comment.