linux/drivers/iommu/iommufd/iommufd_test.h

/* SPDX-License-Identifier: GPL-2.0 */
/* Copyright (c) 2021-2022, NVIDIA CORPORATION & AFFILIATES.
 */
#ifndef _UAPI_IOMMUFD_TEST_H
#define _UAPI_IOMMUFD_TEST_H

#include <linux/iommufd.h>
#include <linux/types.h>

enum {};

enum {};

enum {};

enum {};

enum {};

enum {};

enum {};

struct iommu_test_cmd {};
#define IOMMU_TEST_CMD

/* Mock structs for IOMMU_DEVICE_GET_HW_INFO ioctl */
#define IOMMU_HW_INFO_TYPE_SELFTEST
#define IOMMU_HW_INFO_SELFTEST_REGVAL

struct iommu_test_hw_info {};

/* Should not be equal to any defined value in enum iommu_hwpt_data_type */
#define IOMMU_HWPT_DATA_SELFTEST
#define IOMMU_TEST_IOTLB_DEFAULT

/**
 * struct iommu_hwpt_selftest
 *
 * @iotlb: default mock iotlb value, IOMMU_TEST_IOTLB_DEFAULT
 */
struct iommu_hwpt_selftest {};

/* Should not be equal to any defined value in enum iommu_hwpt_invalidate_data_type */
#define IOMMU_HWPT_INVALIDATE_DATA_SELFTEST
#define IOMMU_HWPT_INVALIDATE_DATA_SELFTEST_INVALID

/**
 * struct iommu_hwpt_invalidate_selftest - Invalidation data for Mock driver
 *                                         (IOMMU_HWPT_INVALIDATE_DATA_SELFTEST)
 * @flags: Invalidate flags
 * @iotlb_id: Invalidate iotlb entry index
 *
 * If IOMMU_TEST_INVALIDATE_ALL is set in @flags, @iotlb_id will be ignored
 */
struct iommu_hwpt_invalidate_selftest {};

#endif