Skip to content

Commit 82a401c

Browse files
committed
drm/amdgpu: fix error handling in ib_schedule()
If fence emit fails, free the fence if necessary. Fixes: db36632 ("drm/amdgpu: clean up and unify hw fence handling") Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com> (cherry picked from commit 5eb680a)
1 parent b6aff8b commit 82a401c

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

drivers/gpu/drm/amd/amdgpu/amdgpu_ib.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -302,7 +302,7 @@ int amdgpu_ib_schedule(struct amdgpu_ring *ring, unsigned int num_ibs,
302302
if (job && job->vmid)
303303
amdgpu_vmid_reset(adev, ring->vm_hub, job->vmid);
304304
amdgpu_ring_undo(ring);
305-
return r;
305+
goto free_fence;
306306
}
307307
*f = &af->base;
308308
/* get a ref for the job */

0 commit comments

Comments
 (0)