[PATCH 2/3] drm/amdgpu: Initialize acpi mem ranges after TTM

Bhardwaj, Rajneesh rajneesh.bhardwaj at amd.com
Mon Oct 2 15:44:59 UTC 2023


I found an issue with this patch, that leads to performance drop. This 
leads to incorrectly initialize numa pools on a multi node system. I am 
working on the fix and will send another change set.

On 9/29/2023 2:18 PM, Rajneesh Bhardwaj wrote:
> Move ttm init before acpi mem range init so we can use ttm_pages_limit
> to override vram size for GFXIP 9.4.3. The vram size override change
> will be introduced in a future commit.
>
> Acked-by: Felix Kuehling <Felix.Kuehling at amd.com>
> Signed-off-by: Rajneesh Bhardwaj <rajneesh.bhardwaj at amd.com>
> ---
>   drivers/gpu/drm/amd/amdgpu/gmc_v9_0.c | 10 +++++-----
>   1 file changed, 5 insertions(+), 5 deletions(-)
>
> diff --git a/drivers/gpu/drm/amd/amdgpu/gmc_v9_0.c b/drivers/gpu/drm/amd/amdgpu/gmc_v9_0.c
> index 268ee533e7c1..005ea719d2fd 100644
> --- a/drivers/gpu/drm/amd/amdgpu/gmc_v9_0.c
> +++ b/drivers/gpu/drm/amd/amdgpu/gmc_v9_0.c
> @@ -2190,17 +2190,17 @@ static int gmc_v9_0_sw_init(void *handle)
>   
>   	amdgpu_gmc_get_vbios_allocations(adev);
>   
> +	/* Memory manager */
> +	r = amdgpu_bo_init(adev);
> +	if (r)
> +		return r;
> +
>   	if (amdgpu_ip_version(adev, GC_HWIP, 0) == IP_VERSION(9, 4, 3)) {
>   		r = gmc_v9_0_init_mem_ranges(adev);
>   		if (r)
>   			return r;
>   	}
>   
> -	/* Memory manager */
> -	r = amdgpu_bo_init(adev);
> -	if (r)
> -		return r;
> -
>   	r = gmc_v9_0_gart_init(adev);
>   	if (r)
>   		return r;


More information about the amd-gfx mailing list