[PATCH] drm/amdgpu: remove preferred domain judgement in pt/pd creation

Christian König christian.koenig at amd.com
Wed Aug 25 07:46:32 UTC 2021


Am 25.08.21 um 09:44 schrieb Yifan Zhang:
> amdgpu_bo_get_preferred_pin_domain was added to handle system memory
> page tables. Since system memory pt/pd is disabled now, remove preferred
> domain judgement to avoid confusion.

Well I would rather keep that and enable system memory page tables again.

We should probably add IOMMU checks to 
amdgpu_bo_get_preferred_pin_domain() anyway. My last status is that this 
has been causing problems with DC as well.

Alex, what do you think?

Regards,
Christian.

>
> Signed-off-by: Yifan Zhang <yifan1.zhang at amd.com>
> ---
>   drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 1 -
>   1 file changed, 1 deletion(-)
>
> diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c
> index 0b893aa21ffe..764822edba18 100644
> --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c
> +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c
> @@ -926,7 +926,6 @@ static int amdgpu_vm_pt_create(struct amdgpu_device *adev,
>   	bp.size = amdgpu_vm_bo_size(adev, level);
>   	bp.byte_align = AMDGPU_GPU_PAGE_SIZE;
>   	bp.domain = AMDGPU_GEM_DOMAIN_VRAM;
> -	bp.domain = amdgpu_bo_get_preferred_pin_domain(adev, bp.domain);
>   	bp.flags = AMDGPU_GEM_CREATE_VRAM_CONTIGUOUS |
>   		AMDGPU_GEM_CREATE_CPU_GTT_USWC;
>   



More information about the amd-gfx mailing list