nvsciipc: Add support to build as module with OOT kernel

Add support to build the nvsciipc driver as module with
OOT kernel.

The source file and makefile for building the nvsccipc driver
as module is copied from kernel/nvidia in build time.

Bug 3583631

Change-Id: I70f16496948c69bc8cd4c96155f00d1ed03390e7
Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/2713487
Reviewed-by: Bitan Biswas <bbiswas@nvidia.com>
GVS: Gerrit_Virtual_Submit
This commit is contained in:
Laxman Dewangan
2022-05-16 17:53:30 +00:00
committed by mobile promotions
parent 4edf906c26
commit 995c108438
4 changed files with 20 additions and 0 deletions

View File

@@ -6,6 +6,7 @@ LINUXINCLUDE += -I$(srctree.nvidia-oot)/include
obj-m += hwmon/ obj-m += hwmon/
obj-m += i2c/busses/ obj-m += i2c/busses/
obj-m += mfd/ obj-m += mfd/
obj-m += misc/
obj-m += pinctrl/ obj-m += pinctrl/
obj-m += platform/tegra/ obj-m += platform/tegra/
obj-m += pwm/ obj-m += pwm/

4
drivers/misc/Makefile Normal file
View File

@@ -0,0 +1,4 @@
# SPDX-License-Identifier: GPL-2.0
# Copyright (c) 2022, NVIDIA CORPORATION. All rights reserved.
obj-m += nvsciipc/

View File

@@ -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/misc/nvsciipc. 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.

View File

@@ -0,0 +1,5 @@
#files/directory for the nvsciipc module
copy_dir nvidia/drivers/misc/nvsciipc drivers/misc/nvsciipc
copy_file nvidia/include/linux/nvscierror.h include/linux/nvscierror.h
copy_file nvidia/include/linux/nvsciipc_interface.h include/linux/nvsciipc_interface.h
copy_file nvidia/include/uapi/linux/nvsciipc_ioctl.h include/uapi/linux/nvsciipc_ioctl.h