]> git.proxmox.com Git - mirror_ubuntu-hirsute-kernel.git/commitdiff
drm/amdgpu: fix wait_any_fence
authorMonk Liu <monk.liu@amd.com>
Fri, 11 Aug 2017 09:49:48 +0000 (17:49 +0800)
committerAlex Deucher <alexander.deucher@amd.com>
Tue, 12 Sep 2017 18:22:43 +0000 (14:22 -0400)
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>
drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c

index b57adc0723cb71614329682f0e2cf06db0e88fdd..233b6f2f84279edfe53dbbfb7c93efbbd56f8640 100644 (file)
@@ -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;
                }
        }