]> Git Repo - linux.git/blobdiff - drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
Merge branch 'topic/disconnect' of https://git.kernel.org/pub/scm/linux/kernel/git...
[linux.git] / drivers / gpu / drm / amd / amdgpu / amdgpu_cs.c
index 6c78623e13863c6773d9dd4f7c4444de045f9f2b..a57cec737c18ab1b8db405607042a4363493205b 100644 (file)
@@ -1495,8 +1495,11 @@ out:
        memset(wait, 0, sizeof(*wait));
        wait->out.status = (r > 0);
        wait->out.first_signaled = first;
-       /* set return value 0 to indicate success */
-       r = array[first]->error;
+
+       if (first < fence_count && array[first])
+               r = array[first]->error;
+       else
+               r = 0;
 
 err_free_fence_array:
        for (i = 0; i < fence_count; i++)
This page took 0.03599 seconds and 4 git commands to generate.