]> www.infradead.org Git - users/jedix/linux-maple.git/commit
drm/amdgpu: Pop jobs from the queue more robustly
authorTvrtko Ursulin <tvrtko.ursulin@igalia.com>
Fri, 21 Feb 2025 10:50:34 +0000 (10:50 +0000)
committerPhilipp Stanner <phasta@kernel.org>
Mon, 24 Feb 2025 09:17:40 +0000 (10:17 +0100)
commit80b6ef8ae25ade45e6418df3ddf699a5a10a7ca4
tree0df66a68cd640735694f15f8591c2885f24318e5
parentb6eb664d89e7ed1e3369fe2860fea31e6dc45e34
drm/amdgpu: Pop jobs from the queue more robustly

Replace a copy of DRM scheduler's to_drm_sched_job with a copy of a newly
added drm_sched_entity_queue_pop.

This allows breaking the hidden dependency that queue_node has to be the
first element in struct drm_sched_job.

A comment is also added with a reference to the mailing list discussion
explaining the copied helper will be removed when the whole broken
amdgpu_job_stop_all_jobs_on_sched is removed.

Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@igalia.com>
Cc: Christian König <christian.koenig@amd.com>
Cc: Danilo Krummrich <dakr@kernel.org>
Cc: Matthew Brost <matthew.brost@intel.com>
Cc: Philipp Stanner <phasta@kernel.org>
Cc: Zhang, Hawking <Hawking.Zhang@amd.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
Signed-off-by: Philipp Stanner <phasta@kernel.org>
Link: https://patchwork.freedesktop.org/patch/msgid/20250221105038.79665-3-tvrtko.ursulin@igalia.com
drivers/gpu/drm/amd/amdgpu/amdgpu_job.c