From 7fe4b6572ba80dda58d513969b69e22437901077 Mon Sep 17 00:00:00 2001 From: Terje Bergstrom Date: Mon, 10 Apr 2017 11:09:13 -0700 Subject: gpu: nvgpu: gv11b: Use new error macros gk20a_err() and gk20a_warn() require a struct device pointer, which is not portable across operating systems. The new nvgpu_err() and nvgpu_warn() macros take struct gk20a pointer. Convert code to use the more portable macros. JIRA NVGPU-16 Change-Id: I8c0d8944f625e3c5b16a9f5a2a59d95a680f4e55 Signed-off-by: Terje Bergstrom Reviewed-on: http://git-master/r/1459822 Reviewed-by: Automatic_Commit_Validation_User Reviewed-by: svccoveritychecker Reviewed-by: Alex Waterman GVS: Gerrit_Virtual_Submit --- drivers/gpu/nvgpu/gv11b/subctx_gv11b.c | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) (limited to 'drivers/gpu/nvgpu/gv11b/subctx_gv11b.c') diff --git a/drivers/gpu/nvgpu/gv11b/subctx_gv11b.c b/drivers/gpu/nvgpu/gv11b/subctx_gv11b.c index 8b322296..4d68926f 100644 --- a/drivers/gpu/nvgpu/gv11b/subctx_gv11b.c +++ b/drivers/gpu/nvgpu/gv11b/subctx_gv11b.c @@ -16,12 +16,13 @@ * this program. */ -#include - #include "gk20a/gk20a.h" #include "gv11b/subctx_gv11b.h" +#include +#include + #include #include @@ -58,8 +59,7 @@ int gv11b_alloc_subctx_header(struct channel_gk20a *c) gr->ctx_vars.golden_image_size, &ctx->mem); if (ret) { - gk20a_err(dev_from_gk20a(g), - "failed to allocate sub ctx header"); + nvgpu_err(g, "failed to allocate sub ctx header"); return ret; } ctx->mem.gpu_va = gk20a_gmmu_map(c->vm, @@ -69,8 +69,7 @@ int gv11b_alloc_subctx_header(struct channel_gk20a *c) gk20a_mem_flag_none, true, ctx->mem.aperture); if (!ctx->mem.gpu_va) { - gk20a_err(dev_from_gk20a(g), - "failed to map ctx header"); + nvgpu_err(g, "failed to map ctx header"); nvgpu_dma_free(g, &ctx->mem); return -ENOMEM; } -- cgit v1.2.2