[PATCH v3] drm/amdgpu: Verify root PD is mapped into kernel address space.

Christian König ckoenig.leichtzumerken at gmail.com
Sat Jul 7 09:21:04 UTC 2018


Am 06.07.2018 um 22:12 schrieb Andrey Grodzovsky:
> Problem: When PD/PT update made by CPU root PD was not yet mapped causing
> page fault.
>
> Fix: Verify root PD is mapped into CPU address space.
>
> v2:
> Make sure that we add the root PD to the relocated list
> since then it's get mapped into CPU address space bt default
> in amdgpu_vm_update_directories.
>
> v3:
> Drop change to not move kernel type BOs to evicted list.
>
> Link: https://bugs.freedesktop.org/show_bug.cgi?id=107065
> Signed-off-by: Andrey Grodzovsky <andrey.grodzovsky at amd.com>
>
> Signed-off-by: Andrey Grodzovsky <andrey.grodzovsky at amd.com>

Double Signed-off-by line, but apart of that Reviewed-by: Christian 
König <christian.koenig at amd.com>.

Regards,
Christian.

> ---
>   drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 3 +++
>   1 file changed, 3 insertions(+)
>
> diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c
> index d18f247..316a501 100644
> --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c
> +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c
> @@ -156,6 +156,9 @@ static void amdgpu_vm_bo_base_init(struct amdgpu_vm_bo_base *base,
>   		return;
>   	list_add_tail(&base->bo_list, &bo->va);
>   
> +	if (bo->tbo.type == ttm_bo_type_kernel)
> +		list_move(&base->vm_status, &vm->relocated);
> +
>   	if (bo->tbo.resv != vm->root.base.bo->tbo.resv)
>   		return;
>   



More information about the amd-gfx mailing list