All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Christian König" <christian.koenig@amd.com>
To: Tvrtko Ursulin <tvrtko.ursulin@igalia.com>,
	amd-gfx@lists.freedesktop.org
Cc: kernel-dev@igalia.com,
	"Pierre-Eric Pelloux-Prayer" <pierre-eric.pelloux-prayer@amd.com>,
	"Felix Kuehling" <felix.kuehling@amd.com>,
	"Alex Deucher" <alexander.deucher@amd.com>,
	"Timur Kristóf" <timur.kristof@gmail.com>
Subject: Re: [PATCH 1/3] drm/amdgpu: Size the buffer_funcs array by maximum number of SDMA instances
Date: Tue, 20 Oct 2026 15:37:20 +0200	[thread overview]
Message-ID: <af6a9ffd-9687-4c57-8d0b-d40aa611bd9a@amd.com> (raw)
In-Reply-To: <20261020132739.31852-2-tvrtko.ursulin@igalia.com>

On 10/20/26 15:27, Tvrtko Ursulin wrote:
> The array is populated from a loop capped by adev->sdma.num_instances so
> it makes sense to size it using AMDGPU_MAX_SDMA_INSTANCES and save some
> memory.
> 
> Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin@igalia.com>
> Cc: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
> Cc: Felix Kuehling <felix.kuehling@amd.com>
> Cc: Christian König <christian.koenig@amd.com>
> Cc: Alex Deucher <alexander.deucher@amd.com>
> Cc: Timur Kristóf <timur.kristof@gmail.com>

Reviewed-by: Christian König <christian.koenig@amd.com>

> ---
>  drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.h | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.h b/drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.h
> index adb6cfae5052..9856a2fc2d08 100644
> --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.h
> +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.h
> @@ -30,6 +30,7 @@
>  #include "amdgpu_vram_mgr.h"
>  #include "amdgpu_hmm.h"
>  #include "amdgpu_gmc.h"
> +#include "amdgpu_sdma_types.h"
>  
>  #define AMDGPU_PL_GDS		(TTM_PL_PRIV + 0)
>  #define AMDGPU_PL_GWS		(TTM_PL_PRIV + 1)
> @@ -89,7 +90,7 @@ struct amdgpu_mman {
>  
>  	/* buffer handling */
>  	const struct amdgpu_buffer_funcs	*buffer_funcs;
> -	struct drm_gpu_scheduler		*buffer_funcs_scheds[AMDGPU_MAX_RINGS];
> +	struct drm_gpu_scheduler		*buffer_funcs_scheds[AMDGPU_MAX_SDMA_INSTANCES];
>  	u32					num_buffer_funcs_scheds;
>  	bool					buffer_funcs_enabled;
>  


  reply	other threads:[~2026-10-20 13:37 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-10-20 13:27 [PATCH 0/3] Misc amdgpu cleanups Tvrtko Ursulin
2026-10-20 13:27 ` [PATCH 1/3] drm/amdgpu: Size the buffer_funcs array by maximum number of SDMA instances Tvrtko Ursulin
2026-10-20 13:37   ` Christian König [this message]
2026-10-20 13:27 ` [PATCH 2/3] drm/amdgpu: Size the vm_pte_scheds " Tvrtko Ursulin
2026-10-20 13:47   ` Christian König
2026-10-20 13:27 ` [PATCH 3/3] drm/amdgpu: Simplify amdgpu_ring_init Tvrtko Ursulin
2026-10-20 13:55   ` Christian König
2026-10-21 13:38 ` [PATCH 0/3] Misc amdgpu cleanups Alex Deucher

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=af6a9ffd-9687-4c57-8d0b-d40aa611bd9a@amd.com \
    --to=christian.koenig@amd.com \
    --cc=alexander.deucher@amd.com \
    --cc=amd-gfx@lists.freedesktop.org \
    --cc=felix.kuehling@amd.com \
    --cc=kernel-dev@igalia.com \
    --cc=pierre-eric.pelloux-prayer@amd.com \
    --cc=timur.kristof@gmail.com \
    --cc=tvrtko.ursulin@igalia.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.