Files
linux-nv-oot/include/uapi/linux/tegra-ivc-dev.h
Joshua Cha 1b537bff19 nvsciipc: fix mixed license
Bug 4405013

Change-Id: I4c37c89b7dcc4c25e0b4e568b8d68d1a73c424f7
Signed-off-by: Joshua Cha <joshuac@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/3028570
(cherry picked from commit 21a661c58f)
Reviewed-on: https://git-master.nvidia.com/r/c/linux-nv-oot/+/3030718
Tested-by: Jonathan Hunter <jonathanh@nvidia.com>
Reviewed-by: svcacv <svcacv@nvidia.com>
Reviewed-by: Jonathan Hunter <jonathanh@nvidia.com>
GVS: Gerrit_Virtual_Submit <buildbot_gerritrpt@nvidia.com>
2023-12-13 01:39:30 -08:00

48 lines
1.1 KiB
C

/* SPDX-License-Identifier: GPL-2.0-only */
/*
* SPDX-FileCopyrightText: Copyright (c) 2022-2023 NVIDIA CORPORATION & AFFILIATES. All rights reserved.
*/
#ifndef __UAPI_TEGRA_IVC_DEV_H
#define __UAPI_TEGRA_IVC_DEV_H
#include <linux/ioctl.h>
#define IVC_INVALID_IPA 0U
#define IVC_TRAP_IPA 1U
#define IVC_MSI_IPA 2U
struct nvipc_ivc_info {
uint32_t nframes;
uint32_t frame_size;
uint32_t queue_offset;
uint32_t queue_size;
uint32_t area_size;
bool rx_first;
uint64_t noti_ipa;
uint16_t noti_irq;
uint16_t noti_type; /* IVC_TRAP_IPA, IVC_MSI_IPA */
};
/* IOCTL magic number */
#define NVIPC_IVC_IOCTL_MAGIC 0xAA
/* query ivc info */
#define NVIPC_IVC_IOCTL_GET_INFO \
_IOWR(NVIPC_IVC_IOCTL_MAGIC, 1, struct nvipc_ivc_info)
/* notify remote */
#define NVIPC_IVC_IOCTL_NOTIFY_REMOTE \
_IO(NVIPC_IVC_IOCTL_MAGIC, 2)
/* query vmid */
#define NVIPC_IVC_IOCTL_GET_VMID \
_IOR(NVIPC_IVC_IOCTL_MAGIC, 3, uint32_t)
#define NVIPC_IVC_IOCTL_NUMBER_MAX 3
int ivc_cdev_get_peer_vmid(uint32_t qid, uint32_t *peer_vmid);
int ivc_cdev_get_noti_type(uint32_t qid, uint32_t *noti_type);
#endif