linux/drivers/gpu
Lin.Cao f5ee8a39f0 drm/sched: Remove optimization that causes hang when killing dependent jobs
commit 15f77764e9 upstream.

When application A submits jobs and application B submits a job with a
dependency on A's fence, the normal flow wakes up the scheduler after
processing each job. However, the optimization in
drm_sched_entity_add_dependency_cb() uses a callback that only clears
dependencies without waking up the scheduler.

When application A is killed before its jobs can run, the callback gets
triggered but only clears the dependency without waking up the scheduler,
causing the scheduler to enter sleep state and application B to hang.

Remove the optimization by deleting drm_sched_entity_clear_dep() and its
usage, ensuring the scheduler is always woken up when dependencies are
cleared.

Fixes: 777dbd458c ("drm/amdgpu: drop a dummy wakeup scheduler")
Cc: stable@vger.kernel.org # v4.6+
Signed-off-by: Lin.Cao <lincao12@amd.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
Signed-off-by: Philipp Stanner <phasta@kernel.org>
Link: https://lore.kernel.org/r/20250717084453.921097-1-lincao12@amd.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
History 2025-08-01 09:48:42 +01:00
..
drm drm/sched: Remove optimization that causes hang when killing dependent jobs 2025-08-01 09:48:42 +01:00
host1x gpu: host1x: Do not assume that a NULL domain means no DMA IOMMU 2025-03-28 22:03:27 +01:00
ipu-v3 Driver core changes for 6.11-rc1 2024-07-25 10:42:22 -07:00
trace gpu/trace: add a gpu total memory usage tracepoint 2020-03-03 17:52:41 -05:00
vga drm: Do delayed switcheroo in drm_lastclose() 2024-08-13 16:21:07 +02:00
Makefile gpu: host1x: Add context bus 2022-06-01 11:50:42 +02:00