From 32987b224a0f309914a4ee63edda7dd4b71ddf16 Mon Sep 17 00:00:00 2001 From: Laxman Dewangan Date: Fri, 20 May 2022 09:57:13 +0000 Subject: [PATCH] nvgpu: Copy source file from kernel/nvgpu to build nvgpu module Copy the sources of nvgpu module from kernel/nvgpu to kernel/nvidia-oot to build nvgpu as OOT module. Files get copied at build time. Change-Id: I4053685edd5e3f8cec6e16aefb183a13c6210d0e Signed-off-by: Laxman Dewangan Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/2718331 GVS: Gerrit_Virtual_Submit --- drivers/gpu/Makefile | 1 + drivers/gpu/nvgpu/Makefile | 10 ++++++++++ kernel-src-files-copy-list.txt | 6 ++++++ 3 files changed, 17 insertions(+) create mode 100644 drivers/gpu/nvgpu/Makefile diff --git a/drivers/gpu/Makefile b/drivers/gpu/Makefile index 80457d09..a148b91c 100644 --- a/drivers/gpu/Makefile +++ b/drivers/gpu/Makefile @@ -4,3 +4,4 @@ obj-m += drm/tegra/ obj-m += host1x/ obj-m += host1x-nvhost/ +obj-m += nvgpu/ diff --git a/drivers/gpu/nvgpu/Makefile b/drivers/gpu/nvgpu/Makefile new file mode 100644 index 00000000..1b8572eb --- /dev/null +++ b/drivers/gpu/nvgpu/Makefile @@ -0,0 +1,10 @@ +# SPDX-License-Identifier: GPL-2.0 +# Copyright (c) 2022, NVIDIA CORPORATION. All rights reserved. + +# NOTE: Do not change or add anything in this makefile. +# The source code and makefile rules are copied from the +# kernel/nvgpu/drivers/gpu/nvgpu. This file is +# just place-holder for empty makefile to avoid any build +# issue when copy is not done from command line and building +# the tree independent of source copy. + diff --git a/kernel-src-files-copy-list.txt b/kernel-src-files-copy-list.txt index 5cd3cc08..fd5f1300 100644 --- a/kernel-src-files-copy-list.txt +++ b/kernel-src-files-copy-list.txt @@ -33,3 +33,9 @@ copy_file nvidia/include/uapi/linux/nvhost_ioctl.h include/uapi/linux/nvhost_ioc # Files/directories for DRM copy_dir nvidia/drivers/gpu/drm/tegra drivers/gpu/drm/tegra + +# Files/directories for NVGPU +copy_dir nvgpu/drivers/gpu/nvgpu drivers/gpu/nvgpu +copy_dir nvgpu/include include +copy_dir nvgpu/nvsched nvsched +copy_file nvidia/drivers/video/tegra/nvmap/include/linux/nvmap_exports.h include/linux/nvmap_exports.h