summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorvishnu Reddy <vmandalapu@nvidia.com>2017-02-14 21:17:43 -0500
committermobile promotions <svcmobile_promotions@nvidia.com>2017-03-02 21:15:47 -0500
commitf9b2c30b369ba13735e2c0168fd45bb7275bdebd (patch)
tree62c92172383a837b30bcbd3b16973dd4a19a69c2
parentf1072a28be09dc7f5433b5e1013a76d8a87c2505 (diff)
gpu: nvgpu: Add and move FECS trace flag
Added fecs trace characteristic flag to vgpu to determine for platform support Also moved fecs flag from ctxsw init to fecs init for native linux. This makes flag init uniform across both platforms. JIRA EVLR-993 Change-Id: Id62f31954cb5d7028ef01a199548f5f908b51eb0 Signed-off-by: Vishnu Reddy Mandalapu <vmandalapu@nvidia.com> Reviewed-on: http://git-master/r/1305045 Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
-rw-r--r--drivers/gpu/nvgpu/gk20a/ctxsw_trace_gk20a.c3
-rw-r--r--drivers/gpu/nvgpu/gk20a/fecs_trace_gk20a.c3
-rw-r--r--drivers/gpu/nvgpu/vgpu/fecs_trace_vgpu.c2
3 files changed, 5 insertions, 3 deletions
diff --git a/drivers/gpu/nvgpu/gk20a/ctxsw_trace_gk20a.c b/drivers/gpu/nvgpu/gk20a/ctxsw_trace_gk20a.c
index ffd15a37..4e265b81 100644
--- a/drivers/gpu/nvgpu/gk20a/ctxsw_trace_gk20a.c
+++ b/drivers/gpu/nvgpu/gk20a/ctxsw_trace_gk20a.c
@@ -518,9 +518,6 @@ int gk20a_ctxsw_trace_init(struct gk20a *g)
518 if (unlikely(err)) 518 if (unlikely(err))
519 goto fail; 519 goto fail;
520 520
521 g->gpu_characteristics.flags |=
522 NVGPU_GPU_FLAGS_SUPPORT_FECS_CTXSW_TRACE;
523
524 return 0; 521 return 0;
525 522
526fail: 523fail:
diff --git a/drivers/gpu/nvgpu/gk20a/fecs_trace_gk20a.c b/drivers/gpu/nvgpu/gk20a/fecs_trace_gk20a.c
index 8244403e..05c53a66 100644
--- a/drivers/gpu/nvgpu/gk20a/fecs_trace_gk20a.c
+++ b/drivers/gpu/nvgpu/gk20a/fecs_trace_gk20a.c
@@ -584,6 +584,9 @@ static int gk20a_fecs_trace_init(struct gk20a *g)
584 nvgpu_mutex_init(&trace->hash_lock); 584 nvgpu_mutex_init(&trace->hash_lock);
585 hash_init(trace->pid_hash_table); 585 hash_init(trace->pid_hash_table);
586 586
587 g->gpu_characteristics.flags |=
588 NVGPU_GPU_FLAGS_SUPPORT_FECS_CTXSW_TRACE;
589
587 gk20a_fecs_trace_debugfs_init(g); 590 gk20a_fecs_trace_debugfs_init(g);
588 return 0; 591 return 0;
589 592
diff --git a/drivers/gpu/nvgpu/vgpu/fecs_trace_vgpu.c b/drivers/gpu/nvgpu/vgpu/fecs_trace_vgpu.c
index c80da26d..6396ee4c 100644
--- a/drivers/gpu/nvgpu/vgpu/fecs_trace_vgpu.c
+++ b/drivers/gpu/nvgpu/vgpu/fecs_trace_vgpu.c
@@ -52,6 +52,8 @@ static int vgpu_fecs_trace_init(struct gk20a *g)
52 dev_info(dev_from_gk20a(g), "does not support fecs trace\n"); 52 dev_info(dev_from_gk20a(g), "does not support fecs trace\n");
53 goto fail; 53 goto fail;
54 } 54 }
55 g->gpu_characteristics.flags |=
56 NVGPU_GPU_FLAGS_SUPPORT_FECS_CTXSW_TRACE;
55 57
56 hv_np = args.np; 58 hv_np = args.np;
57 mempool = args.args[0]; 59 mempool = args.args[0];