aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/amd/amdgpu/mes_userqueue.c
diff options
context:
space:
mode:
authorArunpravin Paneer Selvam <[email protected]>2024-11-26 14:51:08 +0000
committerAlex Deucher <[email protected]>2025-04-08 20:48:19 +0000
commitdd5a376cd234c3fff79667598a1e06300cf75026 (patch)
tree9b95ec97e20c53f10a8ead0890c24b0e3ae7d25e /drivers/gpu/drm/amd/amdgpu/mes_userqueue.c
parentdrm/amdgpu: enable userqueue support for GFX12 (diff)
downloadkernel-dd5a376cd234c3fff79667598a1e06300cf75026.tar.gz
kernel-dd5a376cd234c3fff79667598a1e06300cf75026.zip
drm/amdgpu: enable userqueue secure sem for GFX 12
- Add a field in struct amdgpu_mqd_prop for userqueue secure sem fence address since now we have a generic file for mes_userqueue.c - Add secure sem fence address mqd support to gfx12 into their corresponding init functions. - Enable secure semaphore IRQ handling V2: Address review comment from Alex: Use fence_address instead of fenceaddress (Shashank) Cc: Alex Deucher <[email protected]> Cc: Christian Koenig <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Arunpravin Paneer Selvam <[email protected]> Signed-off-by: Somalapuram Amaranath <[email protected]> Signed-off-by: Shashank Sharma <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu/mes_userqueue.c')
-rw-r--r--drivers/gpu/drm/amd/amdgpu/mes_userqueue.c11
1 files changed, 1 insertions, 10 deletions
diff --git a/drivers/gpu/drm/amd/amdgpu/mes_userqueue.c b/drivers/gpu/drm/amd/amdgpu/mes_userqueue.c
index 9c2fc8ae0d56..1dde099382ea 100644
--- a/drivers/gpu/drm/amd/amdgpu/mes_userqueue.c
+++ b/drivers/gpu/drm/amd/amdgpu/mes_userqueue.c
@@ -185,14 +185,6 @@ static int mes_userq_create_ctx_space(struct amdgpu_userq_mgr *uq_mgr,
return 0;
}
-static void mes_userq_set_fence_space(struct amdgpu_usermode_queue *queue)
-{
- struct v11_gfx_mqd *mqd = queue->mqd.cpu_ptr;
-
- mqd->fenceaddress_lo = lower_32_bits(queue->fence_drv->gpu_addr);
- mqd->fenceaddress_hi = upper_32_bits(queue->fence_drv->gpu_addr);
-}
-
static int mes_userq_mqd_create(struct amdgpu_userq_mgr *uq_mgr,
struct drm_amdgpu_userq_in *args_in,
struct amdgpu_usermode_queue *queue)
@@ -231,6 +223,7 @@ static int mes_userq_mqd_create(struct amdgpu_userq_mgr *uq_mgr,
userq_props->mqd_gpu_addr = queue->mqd.gpu_addr;
userq_props->use_doorbell = true;
userq_props->doorbell_index = queue->doorbell_index;
+ userq_props->fence_address = queue->fence_drv->gpu_addr;
if (queue->queue_type == AMDGPU_HW_IP_COMPUTE) {
struct drm_amdgpu_userq_mqd_compute_gfx11 *compute_mqd;
@@ -307,8 +300,6 @@ static int mes_userq_mqd_create(struct amdgpu_userq_mgr *uq_mgr,
goto free_mqd;
}
- mes_userq_set_fence_space(queue);
-
/* FW expects WPTR BOs to be mapped into GART */
r = mes_userq_create_wptr_mapping(uq_mgr, queue, userq_props->wptr_gpu_addr);
if (r) {