drm/amdgpu: Add comment to function amdgpu_ttm_alloc_gart
Subsystems (2)
PATCH 1/2 drm/amdgpu: Add comment to function amdgpu_ttm_alloc_gart
Add comments to refect what function does
Signed-off-by Oak Zeng <[email protected]>
--- drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-)
drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c +6 -1
@@ -1210,7 +1210,12 @@ static int amdgpu_ttm_backend_bind(struct ttm_tt *ttm, }/** -* amdgpu_ttm_alloc_gart - Allocate GART memory for buffer object +* amdgpu_ttm_alloc_gart - Make sure buffer object is accessible either +* through AGP or GART aperture. +* +* If bo is accessible through AGP aperture, then use AGP aperture +* to access bo; otherwise allocate logical space in GART aperture +* and map bo to GART aperture. */ int amdgpu_ttm_alloc_gart (struct ttm_buffer_object *bo) {
Signature · 6 lines
2.7.4 _______________________________________________ amd-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/amd-gfx
PATCH 2/2 drm/amdgpu: More accurate description of a function param
Add more accurate description of the pe parameter of function amdgpu_vm_sdma_udpate and amdgpu_vm_cpu_update
Signed-off-by Oak Zeng <[email protected]>
--- drivers/gpu/drm/amd/amdgpu/amdgpu_vm_cpu.c | 2 +- drivers/gpu/drm/amd/amdgpu/amdgpu_vm_sdma.c | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-)
drivers/gpu/drm/amd/amdgpu/amdgpu_vm_cpu.c +1 -1
@@ -59,7 +59,7 @@ static int amdgpu_vm_cpu_prepare(struct amdgpu_vm_update_params *p,* * @p: see amdgpu_vm_update_params definition * @bo: PD/PT to update -* @pe: kmap addr of the page entry +* @pe: byte offset of the PDE/PTE, relative to start of PDB/PTB * @addr: dst addr to write into pe * @count: number of page entries to update * @incr: increase next addr by incr bytes
drivers/gpu/drm/amd/amdgpu/amdgpu_vm_sdma.c +2 -2
@@ -155,7 +155,7 @@ static void amdgpu_vm_sdma_copy_ptes(struct amdgpu_vm_update_params *p,* * @p: see amdgpu_vm_update_params definition * @bo: PD/PT to update -* @pe: addr of the page entry +* @pe: byte offset of the PDE/PTE, relative to start of PDB/PTB * @addr: dst addr to write into pe * @count: number of page entries to update * @incr: increase next addr by incr bytes
@@ -187,7 +187,7 @@ static void amdgpu_vm_sdma_set_ptes(struct amdgpu_vm_update_params *p,* * @p: see amdgpu_vm_update_params definition * @bo: PD/PT to update -* @pe: addr of the page entry +* @pe: byte offset of the PDE/PTE, relative to start of PDB/PTB * @addr: dst addr to write into pe * @count: number of page entries to update * @incr: increase next addr by incr bytes
Signature · 6 lines
2.7.4 _______________________________________________ amd-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/amd-gfx
Am 11.09.20 um 20:25 schrieb Oak Zeng:
Quoted 15 lines
Add comments to refect what function does
Signed-off-by Oak Zeng <[email protected]>--- drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-)drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c +0
-0@@ -1210,7 +1210,12 @@ static int amdgpu_ttm_backend_bind(struct ttm_tt *ttm, }/**
drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c static int amdgpu_ttm_backend_bind(struct ttm_tt *ttm, · line 1221
Quoted 10 lines
drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c +6
-1-* amdgpu_ttm_alloc_gart - Allocate GART memory for buffer object +* amdgpu_ttm_alloc_gart - Make sure buffer object is accessible either +* through AGP or GART aperture. +* +* If bo is accessible through AGP aperture, then use AGP aperture +* to access bo; otherwise allocate logical space in GART aperture +* and map bo to GART aperture. */ int amdgpu_ttm_alloc_gart (struct ttm_buffer_object *bo) {
_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx