diff options
Diffstat (limited to 'common/recipes-kernel/linux/linux-yocto-4.19.8/0178-drm-amdgpu-validate-the-VM-root-PD-from-the-VM-code.patch')
-rw-r--r-- | common/recipes-kernel/linux/linux-yocto-4.19.8/0178-drm-amdgpu-validate-the-VM-root-PD-from-the-VM-code.patch | 42 |
1 files changed, 42 insertions, 0 deletions
diff --git a/common/recipes-kernel/linux/linux-yocto-4.19.8/0178-drm-amdgpu-validate-the-VM-root-PD-from-the-VM-code.patch b/common/recipes-kernel/linux/linux-yocto-4.19.8/0178-drm-amdgpu-validate-the-VM-root-PD-from-the-VM-code.patch new file mode 100644 index 00000000..5690b179 --- /dev/null +++ b/common/recipes-kernel/linux/linux-yocto-4.19.8/0178-drm-amdgpu-validate-the-VM-root-PD-from-the-VM-code.patch @@ -0,0 +1,42 @@ +From e6a0a522bb4151d059ed1843aaa25d2dad3a4179 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Christian=20K=C3=B6nig?= <christian.koenig@amd.com> +Date: Wed, 15 Aug 2018 19:10:40 +0200 +Subject: [PATCH 0178/2940] drm/amdgpu: validate the VM root PD from the VM + code +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +Preparation for following changes. This validates the root PD twice, +but the overhead of that should be minimal. + +Signed-off-by: Christian König <christian.koenig@amd.com> +Reviewed-by: Junwei Zhang <Jerry.Zhang@amd.com> +Signed-off-by: Alex Deucher <alexander.deucher@amd.com> +--- + drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 8 ++++---- + 1 file changed, 4 insertions(+), 4 deletions(-) + +diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c +index 82c2af1e13d9..95e1592078aa 100644 +--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c ++++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c +@@ -292,11 +292,11 @@ int amdgpu_vm_validate_pt_bos(struct amdgpu_device *adev, struct amdgpu_vm *vm, + list_for_each_entry_safe(bo_base, tmp, &vm->evicted, vm_status) { + struct amdgpu_bo *bo = bo_base->bo; + +- if (bo->parent) { +- r = validate(param, bo); +- if (r) +- break; ++ r = validate(param, bo); ++ if (r) ++ break; + ++ if (bo->parent) { + spin_lock(&glob->lru_lock); + ttm_bo_move_to_lru_tail(&bo->tbo); + if (bo->shadow) +-- +2.17.1 + |