From d8833c6da35c99d73f817e614f327e5617788860 Mon Sep 17 00:00:00 2001 From: Konsta Holtta Date: Tue, 26 Jun 2018 12:22:29 +0300 Subject: gpu: nvgpu: remove unnecessary nvgpu_memset calls Some graphics context buffers are explicitly cleared to zero after allocation. That's not necessary because the allocator gives zero-initialized memory already, so remove the clears. Change-Id: I8f9913605801e35082762e7743762d97f88e1d12 Signed-off-by: Konsta Holtta Reviewed-on: https://git-master.nvidia.com/r/1761578 Reviewed-by: svc-mobile-coverity GVS: Gerrit_Virtual_Submit Reviewed-by: Alex Waterman Reviewed-by: Terje Bergstrom Reviewed-by: mobile promotions Tested-by: mobile promotions --- drivers/gpu/nvgpu/gv11b/subctx_gv11b.c | 2 -- 1 file changed, 2 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 4f8de196..b0bcb585 100644 --- a/drivers/gpu/nvgpu/gv11b/subctx_gv11b.c +++ b/drivers/gpu/nvgpu/gv11b/subctx_gv11b.c @@ -79,8 +79,6 @@ int gv11b_alloc_subctx_header(struct channel_gk20a *c) nvgpu_dma_free(g, &ctx->mem); return -ENOMEM; } - /* Now clear the buffer */ - nvgpu_memset(g, &ctx->mem, 0, 0, ctx->mem.size); } return ret; } -- cgit v1.2.2