diff options
author | Alex Waterman <alexw@nvidia.com> | 2017-10-10 14:28:03 -0400 |
---|---|---|
committer | mobile promotions <svcmobile_promotions@nvidia.com> | 2017-10-13 18:20:24 -0400 |
commit | 2ecd18902e29b8a3615f49afe3c51b2526816be7 (patch) | |
tree | 685910de59f9f21542ae9a4c8e32b8a6cba864e1 /drivers/gpu/nvgpu/common/linux/debug_kmem.c | |
parent | 57fb527a7e33384341fc18f1f918d5a8225057f5 (diff) |
gpu: nvgpu: Use config in makefile for debug_kmem.c
Conditionally compile debug_kmem.c in the Makefile since the entire
file is not needed when CONFIG_NVGPU_TRACK_KMEM_USAGE is not enabled.
Removing as many conditional compilation flags from the C code itself
is highly desirable from a code complexity standard.
Change-Id: If1e87986ca1ee6d71485f1ab40f10c1645c1a628
Signed-off-by: Alex Waterman <alexw@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/1576543
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_kmem.c')
-rw-r--r-- | drivers/gpu/nvgpu/common/linux/debug_kmem.c | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/drivers/gpu/nvgpu/common/linux/debug_kmem.c b/drivers/gpu/nvgpu/common/linux/debug_kmem.c index 04fb8b68..a0c7d47d 100644 --- a/drivers/gpu/nvgpu/common/linux/debug_kmem.c +++ b/drivers/gpu/nvgpu/common/linux/debug_kmem.c | |||
@@ -18,7 +18,6 @@ | |||
18 | #include "debug_kmem.h" | 18 | #include "debug_kmem.h" |
19 | #include "kmem_priv.h" | 19 | #include "kmem_priv.h" |
20 | 20 | ||
21 | #ifdef CONFIG_NVGPU_TRACK_MEM_USAGE | ||
22 | /** | 21 | /** |
23 | * to_human_readable_bytes - Determine suffix for passed size. | 22 | * to_human_readable_bytes - Determine suffix for passed size. |
24 | * | 23 | * |
@@ -311,4 +310,3 @@ void nvgpu_kmem_debugfs_init(struct gk20a *g) | |||
311 | l->debugfs_kmem, | 310 | l->debugfs_kmem, |
312 | g, &__kmem_traces_fops); | 311 | g, &__kmem_traces_fops); |
313 | } | 312 | } |
314 | #endif | ||