All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 0/8] vfio-user: live migration support
@ 2026-09-03 13:08 Hugo Komatsu
  2026-09-03 13:08 ` [PATCH 1/8] vfio-user: add live migration to vfio-user protocol specification Hugo Komatsu
                   ` (7 more replies)
  0 siblings, 8 replies; 17+ messages in thread
From: Hugo Komatsu @ 2026-09-03 13:08 UTC (permalink / raw)
  To: qemu-devel@nongnu.org
  Cc: qemu-s390x@nongnu.org, Alex Williamson, Cédric Le Goater,
	Cornelia Huck, Eric Farman, Halil Pasic, Jason Herne, John Levon,
	Mark Cave-Ayland, Matthew Rosato, Pierrick Bouvier,
	Rafael Castillo, Thanos Makatos, Tony Krowiak

This patch series introduces live migration support for vfio-user PCI
devices, built on top of the VFIO v2 migration interface.

To avoid duplicating the extensive migration logic already present in
QEMU, this series reuses the generic VFIO migration infrastructure
(hw/vfio/migration.c). We achieve this by abstracting the hardcoded
kernel ioctl() and read()/write() calls behind the existing
VFIODeviceIOOps table, allowing the vfio-user transport to supply its
own socket-based implementations.

Kernel VFIO transfers device migration data through a dedicated data_fd.
vfio-user instead uses its already-established UNIX socket. We introduce
three new wire commands (VFIO_USER_MIG_DATA_READ, VFIO_USER_MIG_DATA_WRITE,
and VFIO_USER_GET_PRECOPY_INFO) for streaming migration data and querying
pre-copy information. The protocol documentation and dirty-page logging
behaviors are updated accordingly.

The corresponding SPDK device-side implementation is available as a WIP
series:

https://review.spdk.io/q/topic:vfio-user-live-migration-v2

Current limitations:
1. Peer-to-Peer (P2P) migration states are not currently supported by
   the libvfio-user server, so P2P support is not included.
2. Device state pre-copy is not yet supported over vfio-user. This
   series explicitly strips the PRE_COPY bit from the advertised
   migration flags, forcing the generic migration code to execute a
   standard stop-and-copy migration.
3. Backward migration to older QEMU versions is not explicitly handled with
   compat properties in this series, as older destination binaries lack the
   underlying capability to receive the vfio-user migration state.

Hugo Komatsu (7):
  docs/vfio-user: clarify data_fd and DMA logging behaviors
  vfio: route device_feature through io_ops
  vfio: route device_reset through io_ops
  vfio: use io_ops abstraction for migration related ioctls
  vfio-user: enable DMA logging for dirty page tracking
  vfio-user: implement mig_data read/write socket operations
  vfio-user: enable live migration for pci devices

William Henderson (1):
  vfio-user: add live migration to vfio-user protocol specification

 docs/interop/vfio-user.rst    | 132 +++++++++++++---------
 hw/vfio-user/device.c         | 206 +++++++++++++++++++++++++++++++++-
 hw/vfio-user/pci.c            |  13 ++-
 hw/vfio-user/protocol.h       |  19 ++++
 hw/vfio-user/trace-events     |   3 +
 hw/vfio/ap.c                  |   4 +-
 hw/vfio/ccw.c                 |   2 +-
 hw/vfio/device.c              |  49 +++++++-
 hw/vfio/migration.c           |  79 ++++++-------
 hw/vfio/pci.c                 |  31 +++--
 hw/vfio/pci.h                 |   3 +
 include/hw/vfio/vfio-device.h |  50 +++++++++
 12 files changed, 479 insertions(+), 112 deletions(-)


base-commit: ef1e8668b9f3ab6d6e7826806db1de5326f9df7d
-- 
2.39.3


^ permalink raw reply	[flat|nested] 17+ messages in thread

end of thread, other threads:[~2026-09-08 14:59 UTC | newest]

Thread overview: 17+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-09-03 13:08 [PATCH 0/8] vfio-user: live migration support Hugo Komatsu
2026-09-03 13:08 ` [PATCH 1/8] vfio-user: add live migration to vfio-user protocol specification Hugo Komatsu
2026-09-08 14:41   ` John Levon
2026-09-03 13:08 ` [PATCH 2/8] docs/vfio-user: clarify data_fd and DMA logging behaviors Hugo Komatsu
2026-09-08 14:42   ` John Levon
2026-09-03 13:08 ` [PATCH 3/8] vfio: route device_feature through io_ops Hugo Komatsu
2026-09-03 15:35   ` Cédric Le Goater
2026-09-03 13:08 ` [PATCH 4/8] vfio: route device_reset " Hugo Komatsu
2026-09-03 15:44   ` Cédric Le Goater
2026-09-03 13:08 ` [PATCH 5/8] vfio: use io_ops abstraction for migration related ioctls Hugo Komatsu
2026-09-08 14:47   ` John Levon
2026-09-03 13:08 ` [PATCH 6/8] vfio-user: enable DMA logging for dirty page tracking Hugo Komatsu
2026-09-08 14:52   ` John Levon
2026-09-03 13:08 ` [PATCH 7/8] vfio-user: implement mig_data read/write socket operations Hugo Komatsu
2026-09-08 14:55   ` John Levon
2026-09-03 13:08 ` [PATCH 8/8] vfio-user: enable live migration for pci devices Hugo Komatsu
2026-09-08 14:58   ` John Levon

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.