From 2eea2b23c5129663fb5e0e9a9031f91dd9c83c41 Mon Sep 17 00:00:00 2001 From: Debarshi Dutta Date: Tue, 5 Mar 2019 14:57:54 +0530 Subject: [PATCH] gpu: nvgpu: add non-safe compile flag NVGPU_ENGINE common.fifo.engine unit has both safe as well as non-safe functions. The build flag NVGPU_ENGINE is used to restrict the use of non-safe functions of the engine unit in safety builds. Jira NVGPU-1315 Change-Id: Ic363ad547e07136024a254c078fdf0194fafc265 Signed-off-by: Debarshi Dutta Reviewed-on: https://git-master.nvidia.com/r/2032605 Reviewed-by: mobile promotions Tested-by: mobile promotions --- drivers/gpu/nvgpu/Makefile | 2 ++ drivers/gpu/nvgpu/Makefile.tmk | 1 + 2 files changed, 3 insertions(+) diff --git a/drivers/gpu/nvgpu/Makefile b/drivers/gpu/nvgpu/Makefile index 8d8fed711..0ed7d9109 100644 --- a/drivers/gpu/nvgpu/Makefile +++ b/drivers/gpu/nvgpu/Makefile @@ -25,6 +25,8 @@ ifeq ($(CONFIG_NVGPU_LS_PMU),y) ccflags-y += -DNVGPU_LS_PMU endif +ccflags-y += -DNVGPU_ENGINE + obj-$(CONFIG_GK20A) := nvgpu.o # OS independent parts of nvgpu. The work to collect files here diff --git a/drivers/gpu/nvgpu/Makefile.tmk b/drivers/gpu/nvgpu/Makefile.tmk index 130decbf2..e2dd9fe3f 100644 --- a/drivers/gpu/nvgpu/Makefile.tmk +++ b/drivers/gpu/nvgpu/Makefile.tmk @@ -67,6 +67,7 @@ NVGPU_DEBUGGER := 1 NVGPU_LS_PMU := 1 NV_COMPONENT_CFLAGS += -DNVGPU_DEBUGGER NV_COMPONENT_CFLAGS += -DNVGPU_LS_PMU +NV_COMPONENT_CFLAGS += -DNVGPU_ENGINE endif _NV_TOOLCHAIN_CFLAGS += -rdynamic -g