aboutsummaryrefslogtreecommitdiff
path: root/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
diff options
context:
space:
mode:
authorMonk Liu <monk.liu@amd.com>2017-08-11 17:49:48 +0800
committerAlex Deucher <alexander.deucher@amd.com>2017-09-12 14:22:43 -0400
commita2138eaf97b4e053b229fe07e1bb4ecbe07e6769 (patch)
tree88ae958ccc594267367b47a3bfb4a6fc2ca7395c /drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
parent238e793f4704e794bd3bc04b0e8fadcf0334b495 (diff)
drm/amdgpu: fix wait_any_fence
first is incorrect if hit NULL/signaled fence Signed-off-by: Monk Liu <monk.liu@amd.com> Reviewed-by: Chunming Zhou <David1.Zhou@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c')
-rw-r--r--drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
index b57adc0723cb..233b6f2f8427 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
@@ -1384,6 +1384,7 @@ static int amdgpu_cs_wait_any_fence(struct amdgpu_device *adev,
array[i] = fence;
} else { /* NULL, the fence has been already signaled */
r = 1;
+ first = i;
goto out;
}
}