From b2bf35ce6d85a55b1764d346b8bd6d6df01b5b22 Mon Sep 17 00:00:00 2001 From: Laxman Dewangan Date: Fri, 20 May 2022 07:30:36 +0000 Subject: [PATCH] host1x-nvhost: Copy source file from kernel/nvidia to build host1x-nvhost module Copy the sources of host1x-nvhost module from kernel/nvidia to kernel/nvidia-oot to build host1x-nvhost as OOT module. Files get copied at build time. Change-Id: I86a8757d9beb3e760fbaef85ccf46974d1bbc303 Signed-off-by: Laxman Dewangan Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/2715739 Reviewed-by: Bitan Biswas GVS: Gerrit_Virtual_Submit --- drivers/gpu/Makefile | 1 + drivers/gpu/host1x-nvhost/Makefile | 10 ++++++++++ kernel-src-files-copy-list.txt | 6 ++++++ 3 files changed, 17 insertions(+) create mode 100644 drivers/gpu/host1x-nvhost/Makefile diff --git a/drivers/gpu/Makefile b/drivers/gpu/Makefile index 6416de75..097f6fe5 100644 --- a/drivers/gpu/Makefile +++ b/drivers/gpu/Makefile @@ -2,3 +2,4 @@ # Copyright (c) 2022, NVIDIA CORPORATION. All rights reserved. obj-m += host1x/ +obj-m += host1x-nvhost/ diff --git a/drivers/gpu/host1x-nvhost/Makefile b/drivers/gpu/host1x-nvhost/Makefile new file mode 100644 index 00000000..2a76c04d --- /dev/null +++ b/drivers/gpu/host1x-nvhost/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/nvidia/drivers/gpu/host1x-nvhost. 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 dfd01c2e..c01a7f86 100644 --- a/kernel-src-files-copy-list.txt +++ b/kernel-src-files-copy-list.txt @@ -18,3 +18,9 @@ copy_file nvidia/include/soc/tegra/fuse-helper.h include/soc/tegra/fuse-helper.h # Files/directories for host1x module copy_dir nvidia/drivers/gpu/host1x drivers/gpu/host1x + +# Files/directories for host1x-nvhost module +copy_dir nvidia/drivers/gpu/host1x-nvhost drivers/gpu/host1x-nvhost +copy_file nvidia/drivers/gpu/host1x/include/linux/host1x-next.h include/linux/host1x-next.h +copy_file nvidia/include/linux/nvhost.h include/linux/nvhost.h +copy_file nvidia/include/uapi/linux/nvdev_fence.h include/uapi/linux/nvdev_fence.h