drm/sched: Store the drm client_id in drm_sched_fence
authorPierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Mon, 26 May 2025 12:54:44 +0000 (14:54 +0200)
committerPhilipp Stanner <phasta@kernel.org>
Wed, 28 May 2025 14:15:58 +0000 (16:15 +0200)
commit2956554823cedb390b7ec4534afa898176317638
tree037e00699ac4ce4b6c9e90ec6c7396a178b6009a
parent18c44fb647beb53d5c9dcd926d733bf931fbfca8
drm/sched: Store the drm client_id in drm_sched_fence

This will be used in a later commit to trace the drm client_id in
some of the gpu_scheduler trace events.

This requires changing all the users of drm_sched_job_init to
add an extra parameter.

The newly added drm_client_id field in the drm_sched_fence is a bit
of a duplicate of the owner one. One suggestion I received was to
merge those 2 fields - this can't be done right now as amdgpu uses
some special values (AMDGPU_FENCE_OWNER_*) that can't really be
translated into a client id. Christian is working on getting rid of
those; when it's done we should be able to squash owner/drm_client_id
together.

Reviewed-by: Christian König <christian.koenig@amd.com>
Signed-off-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Signed-off-by: Philipp Stanner <phasta@kernel.org>
Link: https://lore.kernel.org/r/20250526125505.2360-3-pierre-eric.pelloux-prayer@amd.com
26 files changed:
drivers/accel/amdxdna/aie2_ctx.c
drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd.c
drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
drivers/gpu/drm/amd/amdgpu/amdgpu_job.c
drivers/gpu/drm/amd/amdgpu/amdgpu_job.h
drivers/gpu/drm/etnaviv/etnaviv_gem_submit.c
drivers/gpu/drm/imagination/pvr_job.c
drivers/gpu/drm/imagination/pvr_queue.c
drivers/gpu/drm/imagination/pvr_queue.h
drivers/gpu/drm/lima/lima_gem.c
drivers/gpu/drm/lima/lima_sched.c
drivers/gpu/drm/lima/lima_sched.h
drivers/gpu/drm/msm/msm_gem_submit.c
drivers/gpu/drm/nouveau/nouveau_sched.c
drivers/gpu/drm/panfrost/panfrost_drv.c
drivers/gpu/drm/panthor/panthor_drv.c
drivers/gpu/drm/panthor/panthor_mmu.c
drivers/gpu/drm/panthor/panthor_sched.c
drivers/gpu/drm/panthor/panthor_sched.h
drivers/gpu/drm/scheduler/sched_fence.c
drivers/gpu/drm/scheduler/sched_internal.h
drivers/gpu/drm/scheduler/sched_main.c
drivers/gpu/drm/scheduler/tests/mock_scheduler.c
drivers/gpu/drm/v3d/v3d_submit.c
drivers/gpu/drm/xe/xe_sched_job.c
include/drm/gpu_scheduler.h