summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/nvgpu/include/nvgpu/vidmem.h
diff options
context:
space:
mode:
authorAlex Waterman <alexw@nvidia.com>2017-08-17 19:51:03 -0400
committermobile promotions <svcmobile_promotions@nvidia.com>2017-10-13 18:19:34 -0400
commitff9c3fc20a27444cd1ff7d9402965023e425f404 (patch)
treedbb511c48a4cc0068618c8a34a69ae8305e18747 /drivers/gpu/nvgpu/include/nvgpu/vidmem.h
parent59e4089278bd052b440293356605ce524e4944db (diff)
gpu: nvgpu: Reduce usage of nvgpu_vidmem_get_page_alloc
Reduce the usage of nvgpu_vidmem_get_page_alloc() and friends as much as possible. This reduces the dependency of nvgpu on Linux SGLs. SGLs still need to be used, however, since sharing buffers in userspace is done by dma_buf FD. The best way to pass the vidmem buf through the dma_buf is by SGL pointer. JIRA NVGPU-30 JIRA NVGPU-138 Change-Id: Ide0e9e5a557f00aa63b063be085042101a5b34ee Signed-off-by: Alex Waterman <alexw@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/1540709 Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
Diffstat (limited to 'drivers/gpu/nvgpu/include/nvgpu/vidmem.h')
-rw-r--r--drivers/gpu/nvgpu/include/nvgpu/vidmem.h13
1 files changed, 0 insertions, 13 deletions
diff --git a/drivers/gpu/nvgpu/include/nvgpu/vidmem.h b/drivers/gpu/nvgpu/include/nvgpu/vidmem.h
index b89c710d..9e9f8301 100644
--- a/drivers/gpu/nvgpu/include/nvgpu/vidmem.h
+++ b/drivers/gpu/nvgpu/include/nvgpu/vidmem.h
@@ -27,7 +27,6 @@
27#include <nvgpu/errno.h> 27#include <nvgpu/errno.h>
28#include <nvgpu/nvgpu_mem.h> 28#include <nvgpu/nvgpu_mem.h>
29 29
30struct scatterlist;
31struct work_struct; 30struct work_struct;
32 31
33struct gk20a; 32struct gk20a;
@@ -74,8 +73,6 @@ struct nvgpu_vidmem_buf *nvgpu_vidmem_user_alloc(struct gk20a *g, size_t bytes);
74 73
75void nvgpu_vidmem_buf_free(struct gk20a *g, struct nvgpu_vidmem_buf *buf); 74void nvgpu_vidmem_buf_free(struct gk20a *g, struct nvgpu_vidmem_buf *buf);
76 75
77struct nvgpu_page_alloc *nvgpu_vidmem_get_page_alloc(struct scatterlist *sgl);
78void nvgpu_vidmem_set_page_alloc(struct scatterlist *sgl, u64 addr);
79bool nvgpu_addr_is_vidmem_page_alloc(u64 addr); 76bool nvgpu_addr_is_vidmem_page_alloc(u64 addr);
80int nvgpu_vidmem_get_space(struct gk20a *g, u64 *space); 77int nvgpu_vidmem_get_space(struct gk20a *g, u64 *space);
81 78
@@ -93,16 +90,6 @@ int nvgpu_vidmem_clear(struct gk20a *g, struct nvgpu_mem *mem);
93 * When VIDMEM support is not present this interface is used. 90 * When VIDMEM support is not present this interface is used.
94 */ 91 */
95 92
96static inline struct nvgpu_page_alloc *
97nvgpu_vidmem_get_page_alloc(struct scatterlist *sgl)
98{
99 return NULL;
100}
101
102static inline void nvgpu_vidmem_set_page_alloc(struct scatterlist *sgl, u64 addr)
103{
104}
105
106static inline bool nvgpu_addr_is_vidmem_page_alloc(u64 addr) 93static inline bool nvgpu_addr_is_vidmem_page_alloc(u64 addr)
107{ 94{
108 return false; 95 return false;