Merge tag 'vfio-v4.17-rc1' of git://github.com/awilliam/linux-vfio
Pull VFIO updates from Alex Williamson: - Adopt iommu_unmap_fast() interface to type1 backend (Suravee Suthikulpanit) - mdev sample driver fixup (Shunyong Yang) - More efficient PFN mapping handling in type1 backend (Jason Cai) - VFIO device ioeventfd interface (Alex Williamson) - Tag new vfio-platform sub-maintainer (Alex Williamson) * tag 'vfio-v4.17-rc1' of git://github.com/awilliam/linux-vfio: MAINTAINERS: vfio/platform: Update sub-maintainer vfio/pci: Add ioeventfd support vfio/pci: Use endian neutral helpers vfio/pci: Pull BAR mapping setup from read-write path vfio/type1: Improve memory pinning process for raw PFN mapping vfio-mdev/samples: change RDI interrupt condition vfio/type1: Adopt fast IOTLB flush interface when unmap IOVAs
This commit is contained in:
@@ -575,6 +575,33 @@ struct vfio_device_gfx_plane_info {
|
||||
|
||||
#define VFIO_DEVICE_GET_GFX_DMABUF _IO(VFIO_TYPE, VFIO_BASE + 15)
|
||||
|
||||
/**
|
||||
* VFIO_DEVICE_IOEVENTFD - _IOW(VFIO_TYPE, VFIO_BASE + 16,
|
||||
* struct vfio_device_ioeventfd)
|
||||
*
|
||||
* Perform a write to the device at the specified device fd offset, with
|
||||
* the specified data and width when the provided eventfd is triggered.
|
||||
* vfio bus drivers may not support this for all regions, for all widths,
|
||||
* or at all. vfio-pci currently only enables support for BAR regions,
|
||||
* excluding the MSI-X vector table.
|
||||
*
|
||||
* Return: 0 on success, -errno on failure.
|
||||
*/
|
||||
struct vfio_device_ioeventfd {
|
||||
__u32 argsz;
|
||||
__u32 flags;
|
||||
#define VFIO_DEVICE_IOEVENTFD_8 (1 << 0) /* 1-byte write */
|
||||
#define VFIO_DEVICE_IOEVENTFD_16 (1 << 1) /* 2-byte write */
|
||||
#define VFIO_DEVICE_IOEVENTFD_32 (1 << 2) /* 4-byte write */
|
||||
#define VFIO_DEVICE_IOEVENTFD_64 (1 << 3) /* 8-byte write */
|
||||
#define VFIO_DEVICE_IOEVENTFD_SIZE_MASK (0xf)
|
||||
__u64 offset; /* device fd offset of write */
|
||||
__u64 data; /* data to be written */
|
||||
__s32 fd; /* -1 for de-assignment */
|
||||
};
|
||||
|
||||
#define VFIO_DEVICE_IOEVENTFD _IO(VFIO_TYPE, VFIO_BASE + 16)
|
||||
|
||||
/* -------- API for Type1 VFIO IOMMU -------- */
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user