diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_mes.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_mes.c index 1e3a23c81552..9af7c97af5be 100644 --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_mes.c +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_mes.c @@ -952,9 +952,11 @@ int amdgpu_mes_rs64mem_init(struct amdgpu_mes *mes) return 0; } -/** - * amdgpu_mes_rs64mem_fini - tear down RS64 local memory management - */ + /** + * amdgpu_mes_rs64mem_fini - tear down RS64 local memory management + * + * @mes: MES instance + */ void amdgpu_mes_rs64mem_fini(struct amdgpu_mes *mes) { if (mes->ctx_array_size_bo) { @@ -1038,9 +1040,10 @@ int amdgpu_mes_rs64mem_setup_bitmaps(struct amdgpu_mes *mes) * amdgpu_mes_alloc_proc_ctx_index - allocate a process context slot * * @mes: MES instance + * @queue: Usermode queue receiving the allocated process context index * - * Returns 0 on success, -ENOSPC if all slots are used (caller should - * fall back to system memory path). + * Returns 0 on success, -ENOSPC if all slots are used, or + * -EOPNOTSUPP if RS64 local memory is unavailable. */ int amdgpu_mes_alloc_proc_ctx_index(struct amdgpu_mes *mes, struct amdgpu_usermode_queue *queue) @@ -1064,9 +1067,12 @@ int amdgpu_mes_alloc_proc_ctx_index(struct amdgpu_mes *mes, return 0; } -/** - * amdgpu_mes_free_proc_ctx_index - free a process context slot - */ + /** + * amdgpu_mes_free_proc_ctx_index - free a process context slot + * + * @mes: MES instance + * @queue: Usermode queue whose process context index is released + */ void amdgpu_mes_free_proc_ctx_index(struct amdgpu_mes *mes, struct amdgpu_usermode_queue *queue) { @@ -1080,9 +1086,15 @@ void amdgpu_mes_free_proc_ctx_index(struct amdgpu_mes *mes, amdgpu_mes_unlock(mes); } -/** - * amdgpu_mes_alloc_gang_ctx_index - allocate a gang context slot - */ + /** + * amdgpu_mes_alloc_gang_ctx_index - allocate a gang context slot + * + * @mes: MES instance + * @queue: Usermode queue receiving the allocated gang context index + * + * Returns 0 on success, -ENOSPC if all slots are used, or + * -EOPNOTSUPP if RS64 local memory is unavailable. + */ int amdgpu_mes_alloc_gang_ctx_index(struct amdgpu_mes *mes, struct amdgpu_usermode_queue *queue) { @@ -1105,9 +1117,12 @@ int amdgpu_mes_alloc_gang_ctx_index(struct amdgpu_mes *mes, return 0; } -/** - * amdgpu_mes_free_gang_ctx_index - free a gang context slot - */ + /** + * amdgpu_mes_free_gang_ctx_index - free a gang context slot + * + * @mes: MES instance + * @queue: Usermode queue whose gang context index is released + */ void amdgpu_mes_free_gang_ctx_index(struct amdgpu_mes *mes, struct amdgpu_usermode_queue *queue) {