Commit 8c392cd5 authored by Daniel Vetter's avatar Daniel Vetter

drm/amdkfd: fix ttm size refactor fallout

I guess Christian didn't compile test amdkfd.
Acked-by: default avatarAlex Deucher <alexander.deucher@amd.com>
Reviewed-by: default avatarFelix Kuehling <Felix.Kuehling@amd.com>
Fixes: e11bfb99 ("drm/ttm: cleanup BO size handling v3")
Cc: Christian König <christian.koenig@amd.com>
Cc: Huang Rui <ray.huang@amd.com> (v1)
Cc: Daniel Vetter <daniel.vetter@ffwll.ch>
Cc: Felix Kuehling <Felix.Kuehling@amd.com>
Cc: amd-gfx@lists.freedesktop.org
Signed-off-by: default avatarDaniel Vetter <daniel.vetter@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20201214191725.3899147-1-daniel.vetter@ffwll.ch
parent e11bfb99
...@@ -453,7 +453,7 @@ static int add_bo_to_vm(struct amdgpu_device *adev, struct kgd_mem *mem, ...@@ -453,7 +453,7 @@ static int add_bo_to_vm(struct amdgpu_device *adev, struct kgd_mem *mem,
struct amdgpu_bo *bo = mem->bo; struct amdgpu_bo *bo = mem->bo;
uint64_t va = mem->va; uint64_t va = mem->va;
struct list_head *list_bo_va = &mem->bo_va_list; struct list_head *list_bo_va = &mem->bo_va_list;
unsigned long bo_size = bo->tbo.mem.size; unsigned long bo_size = bo->tbo.base.size;
if (!va) { if (!va) {
pr_err("Invalid VA when adding BO to VM\n"); pr_err("Invalid VA when adding BO to VM\n");
...@@ -1281,7 +1281,7 @@ int amdgpu_amdkfd_gpuvm_free_memory_of_gpu( ...@@ -1281,7 +1281,7 @@ int amdgpu_amdkfd_gpuvm_free_memory_of_gpu(
struct kgd_dev *kgd, struct kgd_mem *mem, uint64_t *size) struct kgd_dev *kgd, struct kgd_mem *mem, uint64_t *size)
{ {
struct amdkfd_process_info *process_info = mem->process_info; struct amdkfd_process_info *process_info = mem->process_info;
unsigned long bo_size = mem->bo->tbo.mem.size; unsigned long bo_size = mem->bo->tbo.base.size;
struct kfd_bo_va_list *entry, *tmp; struct kfd_bo_va_list *entry, *tmp;
struct bo_vm_reservation_context ctx; struct bo_vm_reservation_context ctx;
struct ttm_validate_buffer *bo_list_entry; struct ttm_validate_buffer *bo_list_entry;
...@@ -1402,7 +1402,7 @@ int amdgpu_amdkfd_gpuvm_map_memory_to_gpu( ...@@ -1402,7 +1402,7 @@ int amdgpu_amdkfd_gpuvm_map_memory_to_gpu(
mutex_lock(&mem->lock); mutex_lock(&mem->lock);
domain = mem->domain; domain = mem->domain;
bo_size = bo->tbo.mem.size; bo_size = bo->tbo.base.size;
pr_debug("Map VA 0x%llx - 0x%llx to vm %p domain %s\n", pr_debug("Map VA 0x%llx - 0x%llx to vm %p domain %s\n",
mem->va, mem->va,
...@@ -1506,7 +1506,7 @@ int amdgpu_amdkfd_gpuvm_unmap_memory_from_gpu( ...@@ -1506,7 +1506,7 @@ int amdgpu_amdkfd_gpuvm_unmap_memory_from_gpu(
struct amdgpu_device *adev = get_amdgpu_device(kgd); struct amdgpu_device *adev = get_amdgpu_device(kgd);
struct amdkfd_process_info *process_info = struct amdkfd_process_info *process_info =
((struct amdgpu_vm *)vm)->process_info; ((struct amdgpu_vm *)vm)->process_info;
unsigned long bo_size = mem->bo->tbo.mem.size; unsigned long bo_size = mem->bo->tbo.base.size;
struct kfd_bo_va_list *entry; struct kfd_bo_va_list *entry;
struct bo_vm_reservation_context ctx; struct bo_vm_reservation_context ctx;
int ret; int ret;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment