video: tegra: virt: enable gr_comm for oot kernel

- enable config for oot
- add GPL license
- include different tegra hv header for oot

Jira GVSCI-16046

Change-Id: I8358b15cec33fbd5fd98265adc9152d8e335511d
Signed-off-by: Richard Zhao <rizhao@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvidia/+/2866154
Reviewed-by: svcacv <svcacv@nvidia.com>
Reviewed-by: svc-mobile-coverity <svc-mobile-coverity@nvidia.com>
Reviewed-by: svc-mobile-cert <svc-mobile-cert@nvidia.com>
Reviewed-by: svc_kernel_abi <svc_kernel_abi@nvidia.com>
Reviewed-by: Sagar Kamble <skamble@nvidia.com>
Reviewed-by: Aparna Das <aparnad@nvidia.com>
Reviewed-by: Manish Bhardwaj <mbhardwaj@nvidia.com>
GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com>
This commit is contained in:
Richard Zhao
2023-03-05 18:28:00 -08:00
committed by Laxman Dewangan
parent 4636d2781e
commit 7a0ea85184
2 changed files with 14 additions and 2 deletions

View File

@@ -1 +1,6 @@
ifeq ($(CONFIG_TEGRA_OOT_MODULE),m)
ccflags-y += -DCONFIG_TEGRA_GR_VIRTUALIZATION -DCONFIG_TEGRA_OOT_MODULE
obj-m = tegra_gr_comm.o
else
obj-$(CONFIG_TEGRA_GR_VIRTUALIZATION) += tegra_gr_comm.o
endif

View File

@@ -1,7 +1,7 @@
/*
* Tegra Graphics Virtualization Communication Framework
*
* Copyright (c) 2013-2022, NVIDIA Corporation. All rights reserved.
* Copyright (c) 2013-2023, NVIDIA Corporation. All rights reserved.
*
* This program is free software; you can redistribute it and/or modify it
* under the terms and conditions of the GNU General Public License,
@@ -29,10 +29,15 @@
#include <linux/kthread.h>
#include <linux/io.h>
#include <linux/interrupt.h>
#include <linux/tegra-ivc.h>
#include <linux/tegra_gr_comm.h>
#include <linux/module.h>
#ifdef CONFIG_TEGRA_OOT_MODULE
#include <soc/tegra/virt/hv-ivc.h>
#else
#include <linux/tegra-ivc.h>
#endif
#define NUM_QUEUES 5
#define NUM_CONTEXTS 1
@@ -625,3 +630,5 @@ void tegra_gr_comm_oob_put_ptr(void *handle)
mutex_unlock(&queue->mempool_lock);
}
EXPORT_SYMBOL(tegra_gr_comm_oob_put_ptr);
MODULE_LICENSE("GPL v2");