All of lore.kernel.org
 help / color / mirror / Atom feed
From: "Timur Kristóf" <timur.kristof@gmail.com>
To: natalie.vock@gmx.de, honghuan@amd.com, Alexander.Deucher@amd.com,
	Felix.Kuehling@amd.com, Philip.Yang@amd.com,
	christian.koenig@amd.com
Cc: amd-gfx@lists.freedesktop.org
Subject: Re: [PATCH 02/13] drm/amdgpu: give different sizes for each SA pool type
Date: Fri, 12 Jun 2026 08:13:02 +0200	[thread overview]
Message-ID: <2796234.vuYhMxLoTh@timur-max> (raw)
In-Reply-To: <20260529114031.3714-3-christian.koenig@amd.com>

On 2026. május 29., péntek 13:24:04 közép-európai nyári idő Christian König 
wrote:
> The IMMEDIATE (page fault) and DIRECT (reset) pool should be used only
> very rarely and by a single thread.
> 
> Saves roughly 1.25MiB of memory and GART space for each amdgpu device.
> 
> Signed-off-by: Christian König <christian.koenig@amd.com>
> ---
>  drivers/gpu/drm/amd/amdgpu/amdgpu_ib.c   | 8 +++++++-
>  drivers/gpu/drm/amd/amdgpu/amdgpu_ring.h | 2 --
>  2 files changed, 7 insertions(+), 3 deletions(-)
> 
> diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_ib.c
> b/drivers/gpu/drm/amd/amdgpu/amdgpu_ib.c index f1ed4a436f5b..334f95f8f339
> 100644
> --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_ib.c
> +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_ib.c
> @@ -351,14 +351,20 @@ int amdgpu_ib_schedule(struct amdgpu_ring *ring,
> unsigned int num_ibs, */
>  int amdgpu_ib_pool_init(struct amdgpu_device *adev)
>  {
> +	const int sizes[AMDGPU_IB_POOL_MAX] = {
> +		[AMDGPU_IB_POOL_DELAYED] = SZ_1M,
> +		[AMDGPU_IB_POOL_IMMEDIATE] = SZ_128K,
> +		[AMDGPU_IB_POOL_DIRECT] = SZ_512K
> +	};
>  	int r, i;
> 
>  	if (adev->ib_pool_ready)
>  		return 0;
> 
> +

There is a spurious newline here.

Otherwise the patch makes good sense.
Reviewed-by: Timur Kristóf <timur.kristof@gmail.com>

>  	for (i = 0; i < AMDGPU_IB_POOL_MAX; i++) {
>  		r = amdgpu_sa_bo_manager_init(adev, &adev->ib_pools[i],
> -					      
AMDGPU_IB_POOL_SIZE, 256,
> +					      sizes[i], 256,
>  					      
AMDGPU_GEM_DOMAIN_GTT);
>  		if (r)
>  			goto error;
> diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_ring.h
> b/drivers/gpu/drm/amd/amdgpu/amdgpu_ring.h index 8f28b3bd7010..1a063a0a4280
> 100644
> --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_ring.h
> +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_ring.h
> @@ -68,8 +68,6 @@ enum amdgpu_ring_priority_level {
> 
>  #define to_amdgpu_ring(s) container_of((s), struct amdgpu_ring, sched)
> 
> -#define AMDGPU_IB_POOL_SIZE	(1024 * 1024)
> -
>  enum amdgpu_ring_type {
>  	AMDGPU_RING_TYPE_GFX		= AMDGPU_HW_IP_GFX,
>  	AMDGPU_RING_TYPE_COMPUTE	= AMDGPU_HW_IP_COMPUTE,





  reply	other threads:[~2026-06-12  6:13 UTC|newest]

Thread overview: 33+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-05-29 11:24 Christian König
2026-05-29 11:24 ` [PATCH 01/13] drm/amdgpu: move suballoc defines into own header Christian König
2026-06-10  7:53   ` Christian König
2026-06-10 16:14   ` Kuehling, Felix
2026-06-12  6:12   ` Timur Kristóf
2026-05-29 11:24 ` [PATCH 02/13] drm/amdgpu: give different sizes for each SA pool type Christian König
2026-06-12  6:13   ` Timur Kristóf [this message]
2026-05-29 11:24 ` [PATCH 03/13] drm/amdgpu: add gfp_flags to amdgpu_sa_manager Christian König
2026-06-12  6:18   ` Timur Kristóf
2026-05-29 11:24 ` [PATCH 04/13] drm/amdgpu: move job parameter to the end in amdgpu_job_alloc() and *_with_ib() Christian König
2026-06-12  6:21   ` Timur Kristóf
2026-05-29 11:24 ` [PATCH 05/13] drm/amdgpu: use correct gfp_t for job allocation Christian König
2026-06-12  6:33   ` Timur Kristóf
2026-05-29 11:24 ` [PATCH 06/13] drm/amdgpu: add amdgpu_vm_update_leaves() Christian König
2026-06-12  6:54   ` Timur Kristóf
2026-05-29 11:24 ` [PATCH 07/13] drm/amdgpu: drop immediate updates from amdgpu_vm_update_range Christian König
2026-06-12  6:58   ` Timur Kristóf
2026-05-29 11:24 ` [PATCH 08/13] drm/amdgpu: split amdgpu_vm_update_range Christian König
2026-06-01 13:51   ` Pierre-Eric Pelloux-Prayer
2026-06-01 13:58     ` Christian König
2026-06-03 17:54   ` Kuehling, Felix
2026-06-05  9:21     ` Christian König
2026-06-05 19:21       ` Kuehling, Felix
2026-06-04 10:03   ` Huang, Honglei
2026-05-29 11:24 ` [PATCH 09/13] drm/amdgpu: start to move VM internals into amdgpu_vm_internal.h Christian König
2026-05-29 11:24 ` [PATCH 10/13] drm/amdgpu: remove unecessary parameters from trace_amdgpu_vm_update_ptes Christian König
2026-05-29 11:24 ` [PATCH 11/13] drm/amdgpu: nuke most amdgpu_vm_eviction_(try)lock uses Christian König
2026-06-03 18:00   ` Kuehling, Felix
2026-05-29 11:24 ` [PATCH 12/13] drm/amdgpu: rework eviction lock handling into critical section Christian König
2026-05-29 11:24 ` [PATCH 13/13] drm/amdgpu: fix the HMM range handling for KFD SVM Christian König
2026-06-03 19:23   ` Kuehling, Felix
2026-05-29 13:35 ` VM reworks Natalie Vock
2026-06-01  2:46 ` Huang, Honglei1

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=2796234.vuYhMxLoTh@timur-max \
    --to=timur.kristof@gmail.com \
    --cc=Alexander.Deucher@amd.com \
    --cc=Felix.Kuehling@amd.com \
    --cc=Philip.Yang@amd.com \
    --cc=amd-gfx@lists.freedesktop.org \
    --cc=christian.koenig@amd.com \
    --cc=honghuan@amd.com \
    --cc=natalie.vock@gmx.de \
    /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.