]> git.proxmox.com Git - mirror_qemu.git/commit
vfio/migration: Add VFIO migration pre-copy support
authorAvihai Horon <avihaih@nvidia.com>
Wed, 21 Jun 2023 11:12:00 +0000 (14:12 +0300)
committerCédric Le Goater <clg@redhat.com>
Fri, 30 Jun 2023 04:02:51 +0000 (06:02 +0200)
commiteda7362af9595a9c6b1f1fefdd94b5ef711c250c
tree53fe4bd1738e3c95a5d18e58f17bfada5e48692d
parent6cd1fe11598a304b8d22203365f4fc39172ec9b2
vfio/migration: Add VFIO migration pre-copy support

Pre-copy support allows the VFIO device data to be transferred while the
VM is running. This helps to accommodate VFIO devices that have a large
amount of data that needs to be transferred, and it can reduce migration
downtime.

Pre-copy support is optional in VFIO migration protocol v2.
Implement pre-copy of VFIO migration protocol v2 and use it for devices
that support it. Full description of it can be found in the following
Linux commit: 4db52602a607 ("vfio: Extend the device migration protocol
with PRE_COPY").

Signed-off-by: Avihai Horon <avihaih@nvidia.com>
Reviewed-by: Cédric Le Goater <clg@redhat.com>
Tested-by: YangHang Liu <yanghliu@redhat.com>
Acked-by: Alex Williamson <alex.williamson@redhat.com>
Signed-off-by: Cédric Le Goater <clg@redhat.com>
docs/devel/vfio-migration.rst
hw/vfio/common.c
hw/vfio/migration.c
hw/vfio/trace-events
include/hw/vfio/vfio-common.h