From 38fc3a48a0c2fbdda4f2e69dc7c4c619a534e468 Mon Sep 17 00:00:00 2001 From: Deepak Nibade Date: Tue, 3 Mar 2015 12:12:58 +0530 Subject: gpu: nvgpu: add platform specific get_iova_addr() Add platform specific API pointer (*get_iova_addr)() which can be used to get iova/physical address from given scatterlist and flags Use this API with g->ops.mm.get_iova_addr() instead of calling API gk20a_mm_iova_addr() which makes it platform specific Bug 1605653 Change-Id: I798763db1501bd0b16e84daab68f6093a83caac2 Signed-off-by: Deepak Nibade Reviewed-on: http://git-master/r/713089 GVS: Gerrit_Virtual_Submit Reviewed-by: Terje Bergstrom --- drivers/gpu/nvgpu/gk20a/mm_gk20a.h | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'drivers/gpu/nvgpu/gk20a/mm_gk20a.h') diff --git a/drivers/gpu/nvgpu/gk20a/mm_gk20a.h b/drivers/gpu/nvgpu/gk20a/mm_gk20a.h index ea3a2052..b510b472 100644 --- a/drivers/gpu/nvgpu/gk20a/mm_gk20a.h +++ b/drivers/gpu/nvgpu/gk20a/mm_gk20a.h @@ -223,7 +223,7 @@ struct gk20a_mmu_level { u64 iova, u32 kind_v, u32 *ctag, bool cacheable, bool unmapped_pte, - int rw_flag, bool sparse); + int rw_flag, bool sparse, u32 flags); size_t entry_size; }; @@ -375,7 +375,8 @@ int gk20a_get_sgtable_from_pages(struct device *d, struct sg_table **sgt, void gk20a_free_sgtable(struct sg_table **sgt); -u64 gk20a_mm_iova_addr(struct gk20a *g, struct scatterlist *sgl); +u64 gk20a_mm_iova_addr(struct gk20a *g, struct scatterlist *sgl, + u32 flags); u64 gk20a_mm_smmu_vaddr_translate(struct gk20a *g, dma_addr_t iova); void gk20a_mm_ltc_isr(struct gk20a *g); -- cgit v1.2.2