]> git.baikalelectronics.ru Git - kernel.git/commitdiff
drm/amdgpu: rename amdgpu_ttm_bind to amdgpu_ttm_alloc_gart
authorChristian König <christian.koenig@amd.com>
Fri, 27 Oct 2017 13:43:14 +0000 (15:43 +0200)
committerAlex Deucher <alexander.deucher@amd.com>
Mon, 4 Dec 2017 21:41:43 +0000 (16:41 -0500)
We actually don't bind here, but rather allocate GART space if necessary.

Signed-off-by: Christian König <christian.koenig@amd.com>
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
drivers/gpu/drm/amd/amdgpu/amdgpu_object.c
drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c
drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.h

index 43df84c13f21e75119367e85bb58c5b6d894db96..bc3a7500fbbd098ccb5d62bea97c0fa174ed8992 100644 (file)
@@ -684,7 +684,7 @@ static int amdgpu_cs_parser_bos(struct amdgpu_cs_parser *p,
        if (!r && p->uf_entry.robj) {
                struct amdgpu_bo *uf = p->uf_entry.robj;
 
-               r = amdgpu_ttm_bind(&uf->tbo);
+               r = amdgpu_ttm_alloc_gart(&uf->tbo);
                p->job->uf_addr += amdgpu_bo_gpu_offset(uf);
        }
 
@@ -1601,5 +1601,5 @@ int amdgpu_cs_find_mapping(struct amdgpu_cs_parser *parser,
                        return r;
        }
 
-       return amdgpu_ttm_bind(&(*bo)->tbo);
+       return amdgpu_ttm_alloc_gart(&(*bo)->tbo);
 }
index ff6f842655d16c1e452167bddb654a40324eb4eb..a937c49590a978bca01ad2b7b6ff378f5bddf82b 100644 (file)
@@ -688,7 +688,7 @@ int amdgpu_bo_pin_restricted(struct amdgpu_bo *bo, u32 domain,
                goto error;
        }
 
-       r = amdgpu_ttm_bind(&bo->tbo);
+       r = amdgpu_ttm_alloc_gart(&bo->tbo);
        if (unlikely(r)) {
                dev_err(adev->dev, "%p bind failed\n", bo);
                goto error;
index 34dbe7afb6002f58149be5401e03541bea0f2208..793f41dd4ee4fe4259ecb9a0c1fa0f3fbdaf4a82 100644 (file)
@@ -875,7 +875,7 @@ static int amdgpu_ttm_backend_bind(struct ttm_tt *ttm,
        return r;
 }
 
-int amdgpu_ttm_bind(struct ttm_buffer_object *bo)
+int amdgpu_ttm_alloc_gart(struct ttm_buffer_object *bo)
 {
        struct amdgpu_device *adev = amdgpu_ttm_adev(bo->bdev);
        struct ttm_mem_reg tmp;
@@ -1601,7 +1601,7 @@ int amdgpu_fill_buffer(struct amdgpu_bo *bo,
        }
 
        if (bo->tbo.mem.mem_type == TTM_PL_TT) {
-               r = amdgpu_ttm_bind(&bo->tbo);
+               r = amdgpu_ttm_alloc_gart(&bo->tbo);
                if (r)
                        return r;
        }
index d2985def416804fef4653328aa4bb20f9e13480c..4f9433e6140622b5aff6569c8bf8c4941cbd375a 100644 (file)
@@ -91,7 +91,7 @@ int amdgpu_fill_buffer(struct amdgpu_bo *bo,
                        struct dma_fence **fence);
 
 int amdgpu_mmap(struct file *filp, struct vm_area_struct *vma);
-int amdgpu_ttm_bind(struct ttm_buffer_object *bo);
+int amdgpu_ttm_alloc_gart(struct ttm_buffer_object *bo);
 int amdgpu_ttm_recover_gart(struct ttm_buffer_object *tbo);
 
 int amdgpu_ttm_tt_get_user_pages(struct ttm_tt *ttm, struct page **pages);