diff options
author | Thanos Makatos <thanos.makatos@nutanix.com> | 2022-07-04 12:16:08 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-07-04 12:16:08 +0100 |
commit | 36beb63be45ad1412562a98d9373a4c0bd91ab3d (patch) | |
tree | 61bb44f0befc0055292b120909251c0fc2d27b0e /include/vfio-user.h | |
parent | 1c274027bb4f9d68eee846036e8d50dcde2fd7e9 (diff) | |
download | libvfio-user-36beb63be45ad1412562a98d9373a4c0bd91ab3d.zip libvfio-user-36beb63be45ad1412562a98d9373a4c0bd91ab3d.tar.gz libvfio-user-36beb63be45ad1412562a98d9373a4c0bd91ab3d.tar.bz2 |
support for shadow ioeventfd (#698)
When an ioeventfd is written to, KVM discards the value since it has no
memory to write it to, and simply kicks the eventfd. This a problem for
devices such a NVMe controllers that need the value (e.g. doorbells on
BAR0). This patch allows the vfio-user server to pass a file descriptor
that can be mmap'ed and KVM can write the ioeventfd value to this
_shadow_ memory instead of discarding it. This shadow memory is not
exposed to the guest.
Signed-off-by: Thanos Makatos <thanos.makatos@nutanix.com>
Reviewed-by: John Levon <john.levon@nutanix.com>
Change-Id: Iad849c94076ffa5988e034c8bf7ec312d01f095f
Diffstat (limited to 'include/vfio-user.h')
-rw-r--r-- | include/vfio-user.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/include/vfio-user.h b/include/vfio-user.h index 7439484..dc6fafa 100644 --- a/include/vfio-user.h +++ b/include/vfio-user.h @@ -168,6 +168,7 @@ typedef struct vfio_user_region_io_fds_request { #define VFIO_USER_IO_FD_TYPE_IOEVENTFD 0 #define VFIO_USER_IO_FD_TYPE_IOREGIONFD 1 +#define VFIO_USER_IO_FD_TYPE_IOEVENTFD_SHADOW 2 typedef struct vfio_user_sub_region_ioeventfd { uint64_t offset; |