diff options
author | Konsta Holtta <kholtta@nvidia.com> | 2016-07-15 08:52:52 -0400 |
---|---|---|
committer | Vijayakumar Subbu <vsubbu@nvidia.com> | 2016-07-21 08:55:26 -0400 |
commit | 13231006671a1da11cfaf7a67e69430199820788 (patch) | |
tree | 6b4053838d672b158fe636b60768240585a21eb0 /drivers/gpu/nvgpu/gk20a/gk20a.c | |
parent | 83071083d779b67ad73172675a6dfa34ed19b414 (diff) |
gpu: nvgpu: add vidmem allocation ioctl
Add NVGPU_GPU_IOCTL_ALLOC_VIDMEM to the ctrl fd for letting userspace
allocate on-board GPU memory (aka vidmem). The allocations are returned
as dmabuf fds.
Also, report the amount of local video memory in the gpu
characteristics.
Jira DNVGPU-19
Jira DNVGPU-38
Change-Id: I28e361d31bb630b96d06bb1c86d022d91c7592bc
Signed-off-by: Konsta Holtta <kholtta@nvidia.com>
Reviewed-on: http://git-master/r/1181152
GVS: Gerrit_Virtual_Submit
Reviewed-by: Vijayakumar Subbu <vsubbu@nvidia.com>
Diffstat (limited to 'drivers/gpu/nvgpu/gk20a/gk20a.c')
-rw-r--r-- | drivers/gpu/nvgpu/gk20a/gk20a.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/gpu/nvgpu/gk20a/gk20a.c b/drivers/gpu/nvgpu/gk20a/gk20a.c index 04f82033..bb8cb33f 100644 --- a/drivers/gpu/nvgpu/gk20a/gk20a.c +++ b/drivers/gpu/nvgpu/gk20a/gk20a.c | |||
@@ -2148,6 +2148,7 @@ int gk20a_init_gpu_characteristics(struct gk20a *g) | |||
2148 | gpu->default_compute_preempt_mode = | 2148 | gpu->default_compute_preempt_mode = |
2149 | g->gr.preemption_mode_rec.default_compute_preempt_mode; | 2149 | g->gr.preemption_mode_rec.default_compute_preempt_mode; |
2150 | 2150 | ||
2151 | gpu->local_video_memory_size = g->mm.vidmem.size; | ||
2151 | 2152 | ||
2152 | return 0; | 2153 | return 0; |
2153 | } | 2154 | } |