RE: [PATCH] drm/amdgpu: Add missing MES helper parameter descriptions

"Liang, Prike" <[email protected]>
Newsgroups org.freedesktop.lists.amd-gfx
Message-ID <DS7PR12MB6005C8C9C61904AF2C242129FBC22@DS7PR12MB6005.namprd12.prod.outlook.com>
AMD General

Thanks for the fix, but I already had a fix for documenting the MES rs64mem a few days ago.

Regards,
      Prike

> -----Original Message-----
> From: SHANMUGAM, SRINIVASAN <[email protected]>
> Sent: Monday, July 20, 2026 1:36 AM
> To: Koenig, Christian <[email protected]>; Deucher, Alexander
> <[email protected]>
> Cc: [email protected]; SHANMUGAM, SRINIVASAN
> <[email protected]>; Liang, Prike <[email protected]>;
> Chen, Michael <[email protected]>
> Subject: [PATCH] drm/amdgpu: Add missing MES helper parameter descriptions
>
> Complete the kernel-doc comments for the MES RS64 memory, process context,
> and gang context helper functions by documenting the missing function parameters
> to keep the kernel-doc comments consistent with their function signatures.
>
> Fixes: d160cbf3e4db ("drm/amdgpu: add RS64 local memory context array init/fini")
> Fixes: dded4c22699e ("drm/amdgpu: add mes process context alloc/free")
> Fixes: a755b0cf3ef3 ("drm/amdgpu: add mes gang contex alloc/free helper")
> Cc: Prike Liang <[email protected]>
> Cc: Michael Chen <[email protected]>
> Signed-off-by: Srinivasan Shanmugam <[email protected]>
> ---
>  drivers/gpu/drm/amd/amdgpu/amdgpu_mes.c | 43 +++++++++++++++++--------
>  1 file changed, 29 insertions(+), 14 deletions(-)
>
> 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)  {
> --
> 2.34.1
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.