OSDN Git Service

drm/amdgpu: fix error handling in amdgpu_cs_process_fence_dep
authorChristian König <christian.koenig@amd.com>
Tue, 30 Jul 2019 09:17:03 +0000 (11:17 +0200)
committerAlex Deucher <alexander.deucher@amd.com>
Wed, 31 Jul 2019 04:48:33 +0000 (23:48 -0500)
commit649412069501c1710f42ad50ab420e2fd5eaea70
tree52e0023de4d9fb3d161bc4121722fc9584fbf1f1
parent6e92e156aacce9b5d2f8003b92d71e676e5e9139
drm/amdgpu: fix error handling in amdgpu_cs_process_fence_dep

We always need to drop the ctx reference and should check
for errors first and then dereference the fence pointer.

Signed-off-by: Christian König <christian.koenig@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