drm/amdgpu: Fix null pointer issue in amdgpu_cs_wait_any_fence
authorEmily Deng <Emily.Deng@amd.com>
Thu, 9 Nov 2017 09:18:18 +0000 (17:18 +0800)
committerAlex Deucher <alexander.deucher@amd.com>
Thu, 9 Nov 2017 23:11:47 +0000 (18:11 -0500)
commitcdadab89f8cc37dd6101e2bbab50037d72e0e1d0
treea1c24f194732f66c9bb84f62d14b144bfe997b21
parentab6613b7eaefe85dadfc86025e901c55d71c0379
drm/amdgpu: Fix null pointer issue in amdgpu_cs_wait_any_fence

The array[first] may be null when the fence has already been signaled.

BUG: SWDEV-136239

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