From 1b7b271980094637cf34a9d8ad14cb36f2c36363 Mon Sep 17 00:00:00 2001 From: Terje Bergstrom Date: Fri, 20 Mar 2015 12:59:09 -0700 Subject: gpu: nvgpu: Use common allocator for context Reduce amount of duplicate code around memory allocation by using common helpers, and common data structure for storing results of allocations. Bug 1605769 Change-Id: I10c226e2377aa867a5cf11be61d08a9d67206b1d Signed-off-by: Terje Bergstrom Reviewed-on: http://git-master/r/720507 --- drivers/gpu/nvgpu/gm20b/gr_gm20b.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'drivers/gpu/nvgpu/gm20b/gr_gm20b.c') diff --git a/drivers/gpu/nvgpu/gm20b/gr_gm20b.c b/drivers/gpu/nvgpu/gm20b/gr_gm20b.c index c7479078..e318f002 100644 --- a/drivers/gpu/nvgpu/gm20b/gr_gm20b.c +++ b/drivers/gpu/nvgpu/gm20b/gr_gm20b.c @@ -978,8 +978,8 @@ static int gr_gm20b_update_pc_sampling(struct channel_gk20a *c, if (!ch_ctx || !ch_ctx->gr_ctx || c->vpr) return -EINVAL; - ctx_ptr = vmap(ch_ctx->gr_ctx->pages, - PAGE_ALIGN(ch_ctx->gr_ctx->size) >> PAGE_SHIFT, + ctx_ptr = vmap(ch_ctx->gr_ctx->mem.pages, + PAGE_ALIGN(ch_ctx->gr_ctx->mem.size) >> PAGE_SHIFT, 0, pgprot_writecombine(PAGE_KERNEL)); if (!ctx_ptr) return -ENOMEM; -- cgit v1.2.2