diff options
author | Konsta Holtta <kholtta@nvidia.com> | 2016-07-07 03:36:46 -0400 |
---|---|---|
committer | Terje Bergstrom <tbergstrom@nvidia.com> | 2016-07-08 07:19:04 -0400 |
commit | d33fb5a9645ef95a97fcf6b3f8f10d9a812ade6d (patch) | |
tree | cfd53a1fb88e044b8b7004ff9b32f1093efd4f1c /drivers/gpu/nvgpu/gk20a/cde_gk20a.c | |
parent | e27c72446bf09196d6d66f28389f00565273a13f (diff) |
gpu: nvgpu: use vidmem by default in gmmu_alloc variants
For devices that have vidmem available, use the vidmem allocator in
gk20a_gmmu_alloc{,attr,_map,_map_attr}. For others, use sysmem.
Because all of the buffers haven't been tested to work in vidmem yet,
rename calls to gk20a_gmmu_alloc{,attr,_map,_map_attr} to have _sys at
the end to declare explicitly that vidmem is used. Enabling vidmem for
each now is a matter of removing "_sys" from the function call.
Jira DNVGPU-18
Change-Id: Ibe42f67eff2c2b68c36582e978ace419dc815dc5
Signed-off-by: Konsta Holtta <kholtta@nvidia.com>
Reviewed-on: http://git-master/r/1176805
GVS: Gerrit_Virtual_Submit
Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com>
Diffstat (limited to 'drivers/gpu/nvgpu/gk20a/cde_gk20a.c')
-rw-r--r-- | drivers/gpu/nvgpu/gk20a/cde_gk20a.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/nvgpu/gk20a/cde_gk20a.c b/drivers/gpu/nvgpu/gk20a/cde_gk20a.c index 02b1938a..4b84dc69 100644 --- a/drivers/gpu/nvgpu/gk20a/cde_gk20a.c +++ b/drivers/gpu/nvgpu/gk20a/cde_gk20a.c | |||
@@ -241,7 +241,7 @@ static int gk20a_init_cde_buf(struct gk20a_cde_ctx *cde_ctx, | |||
241 | 241 | ||
242 | /* allocate buf */ | 242 | /* allocate buf */ |
243 | mem = cde_ctx->mem + cde_ctx->num_bufs; | 243 | mem = cde_ctx->mem + cde_ctx->num_bufs; |
244 | err = gk20a_gmmu_alloc_map(cde_ctx->vm, buf->num_bytes, mem); | 244 | err = gk20a_gmmu_alloc_map_sys(cde_ctx->vm, buf->num_bytes, mem); |
245 | if (err) { | 245 | if (err) { |
246 | gk20a_warn(cde_ctx->dev, "cde: could not allocate device memory. buffer idx = %d", | 246 | gk20a_warn(cde_ctx->dev, "cde: could not allocate device memory. buffer idx = %d", |
247 | cde_ctx->num_bufs); | 247 | cde_ctx->num_bufs); |