]> www.infradead.org Git - users/hch/misc.git/commit
drm/amdgpu: rework how isolation is enforced v2
authorChristian König <christian.koenig@amd.com>
Wed, 15 Jan 2025 12:44:26 +0000 (13:44 +0100)
committerAlex Deucher <alexander.deucher@amd.com>
Fri, 21 Mar 2025 16:16:34 +0000 (12:16 -0400)
commitbd22e44ad415ac22e3a4f9a983d2a085f6cb4427
treefb16198f66751ca2ad807bf57f4b31f010585121
parent7f11c59e0700721c849b81e565bf56a7d8ceaa2d
drm/amdgpu: rework how isolation is enforced v2

Limiting the number of available VMIDs to enforce isolation causes some
issues with gang submit and applying certain HW workarounds which
require multiple VMIDs to work correctly.

So instead start to track all submissions to the relevant engines in a
per partition data structure and use the dma_fences of the submissions
to enforce isolation similar to what a VMID limit does.

v2: use ~0l for jobs without isolation to distinct it from kernel
    submissions which uses NULL for the owner. Add some warning when we
    are OOM.

Signed-off-by: Christian König <christian.koenig@amd.com>
Acked-by: Srinivasan Shanmugam <srinivasan.shanmugam@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/amdgpu/amdgpu.h
drivers/gpu/drm/amd/amdgpu/amdgpu_device.c
drivers/gpu/drm/amd/amdgpu/amdgpu_ids.c
drivers/gpu/drm/amd/amdgpu/amdgpu_job.c
drivers/gpu/drm/amd/amdgpu/amdgpu_sync.c
drivers/gpu/drm/amd/amdgpu/amdgpu_sync.h