From b22c5911dd2d6f1c4bc218f020228ec23e7e0802 Mon Sep 17 00:00:00 2001 From: David Gilhooley Date: Sun, 12 Nov 2017 21:38:58 -0800 Subject: gpu: nvgpu: Pass DMA allocation flags correctly There are flags that need to be passed to both dma_alloc and sg_alloc together. Update nvgpu_dma_alloc_flags_sys to always pass flags. Bug 1930032 Change-Id: I10c4c07d7b518d9ab6c48dd7a0758c68750d02a6 Signed-off-by: David Gilhooley Reviewed-on: https://git-master.nvidia.com/r/1596848 Reviewed-by: Richard Zhao Reviewed-by: Alex Waterman Reviewed-by: Automatic_Commit_Validation_User Reviewed-by: svc-mobile-coverity Reviewed-by: Konsta Holtta GVS: Gerrit_Virtual_Submit Reviewed-by: Terje Bergstrom Reviewed-by: mobile promotions Tested-by: mobile promotions --- drivers/gpu/nvgpu/include/nvgpu/linux/dma.h | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'drivers/gpu/nvgpu/include') diff --git a/drivers/gpu/nvgpu/include/nvgpu/linux/dma.h b/drivers/gpu/nvgpu/include/nvgpu/linux/dma.h index 3960e654..342b278e 100644 --- a/drivers/gpu/nvgpu/include/nvgpu/linux/dma.h +++ b/drivers/gpu/nvgpu/include/nvgpu/linux/dma.h @@ -21,9 +21,13 @@ * Functions used internally for building the backing SGTs for nvgpu_mems. */ -int nvgpu_get_sgtable(struct gk20a *g, struct sg_table **sgt, + +int nvgpu_get_sgtable_attrs(struct gk20a *g, struct sg_table **sgt, void *cpuva, u64 iova, - size_t size); + size_t size, unsigned long flags); + +int nvgpu_get_sgtable(struct gk20a *g, struct sg_table **sgt, + void *cpuva, u64 iova, size_t size); int nvgpu_get_sgtable_from_pages(struct gk20a *g, struct sg_table **sgt, struct page **pages, u64 iova, -- cgit v1.2.2