Files
linux-nvgpu/drivers/gpu/nvgpu/os/linux/vgpu/vgpu_common.h
Richard Zhao 03da61c9ce gpu: nvgpu: vgpu: create vgpu_common file
vgpu_common file contains common functions that could be shared by
legacy vgpu and vf.

Jira GVSCI-15779

Change-Id: Ie301eb29dfceed95bcd96a1024663f31eb7558fd
Signed-off-by: Richard Zhao <rizhao@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvgpu/+/2884175
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
2023-05-01 00:24:28 -07:00

42 lines
1.1 KiB
C

/*
* Copyright (c) 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,
* version 2, as published by the Free Software Foundation.
*
* This program is distributed in the hope it will be useful, but WITHOUT
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
* more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#ifndef LINUX_VGPU_COMMON_H
#define LINUX_VGPU_COMMON_H
struct device;
struct nvgpu_os_linux;
#ifdef CONFIG_NVGPU_GR_VIRTUALIZATION
int vgpu_pm_prepare_poweroff(struct device *dev);
int vgpu_pm_finalize_poweron(struct device *dev);
int vgpu_probe_common(struct nvgpu_os_linux *l);
#else
static inline int vgpu_pm_prepare_poweroff(struct device *dev)
{
return -ENOSYS;
}
static inline int vgpu_pm_finalize_poweron(struct device *dev)
{
return -ENOSYS;
}
#endif
#endif