summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/nvgpu/Makefile.nvgpu
diff options
context:
space:
mode:
authorAlex Waterman <alexw@nvidia.com>2017-10-10 14:28:03 -0400
committermobile promotions <svcmobile_promotions@nvidia.com>2017-10-13 18:20:24 -0400
commit2ecd18902e29b8a3615f49afe3c51b2526816be7 (patch)
tree685910de59f9f21542ae9a4c8e32b8a6cba864e1 /drivers/gpu/nvgpu/Makefile.nvgpu
parent57fb527a7e33384341fc18f1f918d5a8225057f5 (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/Makefile.nvgpu')
-rw-r--r--drivers/gpu/nvgpu/Makefile.nvgpu6
1 files changed, 5 insertions, 1 deletions
diff --git a/drivers/gpu/nvgpu/Makefile.nvgpu b/drivers/gpu/nvgpu/Makefile.nvgpu
index 9ba6f49a..e059002a 100644
--- a/drivers/gpu/nvgpu/Makefile.nvgpu
+++ b/drivers/gpu/nvgpu/Makefile.nvgpu
@@ -137,10 +137,14 @@ nvgpu-$(CONFIG_DEBUG_FS) += \
137 common/linux/debug_mm.o \ 137 common/linux/debug_mm.o \
138 common/linux/debug_allocator.o \ 138 common/linux/debug_allocator.o \
139 common/linux/debug_hal.o \ 139 common/linux/debug_hal.o \
140 common/linux/debug_kmem.o \
141 common/linux/debug_clk.o \ 140 common/linux/debug_clk.o \
142 common/linux/debug_xve.o 141 common/linux/debug_xve.o
143 142
143ifeq ($(CONFIG_NVGPU_TRACK_MEM_USAGE),y)
144nvgpu-$(CONFIG_DEBUG_FS) += \
145 common/linux/debug_kmem.o
146endif
147
144nvgpu-$(CONFIG_TEGRA_GK20A) += common/linux/platform_gk20a_tegra.o 148nvgpu-$(CONFIG_TEGRA_GK20A) += common/linux/platform_gk20a_tegra.o
145nvgpu-$(CONFIG_SYNC) += gk20a/sync_gk20a.o 149nvgpu-$(CONFIG_SYNC) += gk20a/sync_gk20a.o
146nvgpu-$(CONFIG_GK20A_PCI) += common/linux/pci.o 150nvgpu-$(CONFIG_GK20A_PCI) += common/linux/pci.o