Skip to content

Commit 3d138c1

Browse files
ChristianKoenigAMDalexdeucher
authored andcommitted
drm/amdgpu: revert "fix deadlock of reservation between cs and gpu reset v2"
This reverts commit 10e709c. The patch doesn't work at all: 1. The CS can still be blocked because of amdgpu_ctx_add_fence(). 2. The order of submission isn't correct any more. 3. We could end up using freed up memory because we now drop the ctx reference to early. This needs to be fixed cleanly by doing the context handling after the BO handling, but this is a larger task just avoid the obvious crashes for now. Signed-off-by: Christian König <[email protected]> Reviewed-by: Monk Liu [email protected] Signed-off-by: Alex Deucher <[email protected]>
1 parent 403df1f commit 3d138c1

File tree

1 file changed

+0
-4
lines changed

1 file changed

+0
-4
lines changed

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

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1153,7 +1153,6 @@ static int amdgpu_cs_submit(struct amdgpu_cs_parser *p,
11531153
cs->out.handle = amdgpu_ctx_add_fence(p->ctx, ring, p->fence);
11541154
job->uf_sequence = cs->out.handle;
11551155
amdgpu_job_free_resources(job);
1156-
amdgpu_cs_parser_fini(p, 0, true);
11571156

11581157
trace_amdgpu_cs_ioctl(job);
11591158
amd_sched_entity_push_job(&job->base);
@@ -1211,10 +1210,7 @@ int amdgpu_cs_ioctl(struct drm_device *dev, void *data, struct drm_file *filp)
12111210
goto out;
12121211

12131212
r = amdgpu_cs_submit(&parser, cs);
1214-
if (r)
1215-
goto out;
12161213

1217-
return 0;
12181214
out:
12191215
amdgpu_cs_parser_fini(&parser, r, reserved_buffers);
12201216
return r;

0 commit comments

Comments
 (0)