Skip to content

Commit 412a2a8

Browse files
committed
drm/panthor: Fail job creation when the group is dead
Userspace can use GROUP_SUBMIT errors as a trigger to check the group state and recreate the group if it became unusable. Make sure we report an error when the group became unusable. Changes in v3: - None Changes in v2: - Add R-bs Fixes: de85488 ("drm/panthor: Add the scheduler logical block") Signed-off-by: Boris Brezillon <[email protected]> Reviewed-by: Steven Price <[email protected]> Reviewed-by: Liviu Dudau <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
1 parent 5d01b56 commit 412a2a8

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

drivers/gpu/drm/panthor/panthor_sched.c

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3409,6 +3409,11 @@ panthor_job_create(struct panthor_file *pfile,
34093409
goto err_put_job;
34103410
}
34113411

3412+
if (!group_can_run(job->group)) {
3413+
ret = -EINVAL;
3414+
goto err_put_job;
3415+
}
3416+
34123417
if (job->queue_idx >= job->group->queue_count ||
34133418
!job->group->queues[job->queue_idx]) {
34143419
ret = -EINVAL;

0 commit comments

Comments
 (0)