At XDC, we discussed that drivers should avoid accessing DRM scheduler
internals, misusing DRM scheduler locks, and adopt a well-defined
pending job list iterator. This series proposes the necessary changes to
the DRM scheduler to bring Xe in line with that agreement and updates Xe
to use the new DRM scheduler API.
While here, cleanup LR queue handling and simplify GuC state machine in
Xe too.
v2:
- Fix checkpatch / naming issues
v3:
- Only allow pending job list iterator to be called on stopped schedulers
- Cleanup LR queue handling / fix a few misselanous Xe scheduler issues
v4:
- Address Niranjana's feedback
- Add patch to avoid toggling scheduler state in the TDR
Matt
Matthew Brost (8):
drm/sched: Add several job helpers to avoid drivers touching scheduler
state
drm/sched: Add pending job list iterator
drm/xe: Add dedicated message lock
drm/xe: Stop abusing DRM scheduler internals
drm/xe: Only toggle scheduling in TDR if GuC is running
drm/xe: Do not deregister queues in TDR
drm/xe: Remove special casing for LR queues in submission
drm/xe: Avoid toggling schedule state to check LRC timestamp in TDR
drivers/gpu/drm/scheduler/sched_main.c | 4 +-
drivers/gpu/drm/xe/xe_gpu_scheduler.c | 9 +-
drivers/gpu/drm/xe/xe_gpu_scheduler.h | 38 +-
drivers/gpu/drm/xe/xe_gpu_scheduler_types.h | 2 +
drivers/gpu/drm/xe/xe_guc_exec_queue_types.h | 2 -
drivers/gpu/drm/xe/xe_guc_submit.c | 362 +++----------------
drivers/gpu/drm/xe/xe_guc_submit_types.h | 11 -
drivers/gpu/drm/xe/xe_hw_fence.c | 16 -
drivers/gpu/drm/xe/xe_hw_fence.h | 2 -
drivers/gpu/drm/xe/xe_sched_job.c | 1 +
drivers/gpu/drm/xe/xe_sched_job_types.h | 2 +
drivers/gpu/drm/xe/xe_trace.h | 5 -
include/drm/gpu_scheduler.h | 82 +++++
13 files changed, 157 insertions(+), 379 deletions(-)
--
2.34.1