summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/nvgpu/common/linux/debug.c
diff options
context:
space:
mode:
authorSunny He <suhe@nvidia.com>2017-06-21 15:08:08 -0400
committermobile promotions <svcmobile_promotions@nvidia.com>2017-08-24 12:34:52 -0400
commitcc64606a535edd9fd96487631f8ef583226fc575 (patch)
treee639f1496ab22b35fde90643abd2ddfc28a27bf5 /drivers/gpu/nvgpu/common/linux/debug.c
parent4b5b67d6d83430d8d670660b1dfc9cf024d60d88 (diff)
gpu: nvgpu: debugfs code to dump HAL functions
Prints addresses of device-specific HAL functions to debugfs file hal/gops. The list of functions is produced by dumping the contents of the gpu_ops substruct of the gk20a struct. This interface makes the assumption that there are only function pointers in gpu_ops. Companion Python script nvgpu_debug_hal.py analyzes gk20a.h to determine operation counts and prettyify debugfs interface's output. Jira NVGPU-107 Change-Id: I0910e86638d144979e8630bbc5b330bccfd3ad94 Signed-off-by: Sunny He <suhe@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/1542990 Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
Diffstat (limited to 'drivers/gpu/nvgpu/common/linux/debug.c')
-rw-r--r--drivers/gpu/nvgpu/common/linux/debug.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/gpu/nvgpu/common/linux/debug.c b/drivers/gpu/nvgpu/common/linux/debug.c
index 7dce74d6..abc8b907 100644
--- a/drivers/gpu/nvgpu/common/linux/debug.c
+++ b/drivers/gpu/nvgpu/common/linux/debug.c
@@ -21,6 +21,7 @@
21#include "debug_kmem.h" 21#include "debug_kmem.h"
22#include "debug_pmu.h" 22#include "debug_pmu.h"
23#include "debug_sched.h" 23#include "debug_sched.h"
24#include "debug_hal.h"
24#include "os_linux.h" 25#include "os_linux.h"
25 26
26#include "gk20a/gk20a.h" 27#include "gk20a/gk20a.h"
@@ -386,6 +387,7 @@ void gk20a_debug_init(struct gk20a *g, const char *debugfs_symlink)
386 gk20a_cde_debugfs_init(g); 387 gk20a_cde_debugfs_init(g);
387 gk20a_ce_debugfs_init(g); 388 gk20a_ce_debugfs_init(g);
388 nvgpu_alloc_debugfs_init(g); 389 nvgpu_alloc_debugfs_init(g);
390 nvgpu_hal_debugfs_init(g);
389 gk20a_mm_debugfs_init(g); 391 gk20a_mm_debugfs_init(g);
390 gk20a_fifo_debugfs_init(g); 392 gk20a_fifo_debugfs_init(g);
391 gk20a_sched_debugfs_init(g); 393 gk20a_sched_debugfs_init(g);