Skip to content

Add vduse live migration features

Eugenio Pérez dpdk-dev 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest9 patches 7 repliesIn review

RFC v4 from the cover letter

* Sync headers with Linux's latest existing and proposed UAPI. Both files constants and new ioctl VDUSE_SET_FEATURES.
* Check for more error conditions and clarified some error messages in ready message processing.
* Add relevant release notes.
* Fix cosmetic whitespaces & checkpath errors.
* Fix error path of vhost_user_iotlb_init and vhost_user_iotlb_init_one.
* Fix commits author.

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/9uapi: import VDUSE and VFIO header from v7.3-rc3 kernelkernel/linux/uapi/linux/vduse.h kernel/linux/uapi/linux/vfio.h kernel/linux/uapi/version+199 -97 replies
2/9vhost: introduce ASID supportlib/vhost/iotlb.c lib/vhost/iotlb.h lib/vhost/vduse.c +3 more+177 -1210 replies
3/9vhost: add VDUSE API version negotiationlib/vhost/vduse.c lib/vhost/vhost.h+13 -20 replies
4/9vhost: add virtqueues groups support to VDUSElib/vhost/vduse.c+50 -20 replies
5/9vhost: add ASID support to VDUSE IOTLB operationslib/vhost/vduse.c+33 -60 replies
6/9vhost: claim VDUSE support for API version 1lib/vhost/vduse.c+1 -10 replies
7/9vhost: add net status feature to VDUSElib/vhost/vduse.c lib/vhost/vduse.h+3 -10 replies
8/9vhost: Support VDUSE QUEUE_READY featurelib/vhost/vduse.c lib/vhost/vhost.h+85 -20 replies
9/9vhost: Support vduse suspend featurelib/vhost/vduse.c lib/vhost/vhost.h+42 -10 replies

Reviews trailers per patch

No Reviewed-by, Acked-by or Tested-by trailers for v1 yet.

Read the v1 thread

Cover letter [PATCH 0/9] Add vduse live migration features

This series introduces features to the VDUSE (vDPA Device in Userspace) driver to support Live Migration.

Currently, DPDK does not support VDUSE devices live migration because the driver lacks a mechanism to suspend the device and quiesce the rings to initiate the switchover. This series implements the suspend operation to address this limitation.

Furthermore, enabling Live Migration for devices with control virtqueue requires two additional features. Both of them are included in this series.

* Address Spaces ID (ASID) support: This allows QEMU to isolate and intercept the device's CVQ. By doing so, QEMU is able to migrate the device status transparently, without requiring the device to support state save and restore.
* QUEUE_READY: This allows QEMU to control when the dataplane virtqueues are enabled. This ensures the dataplane is started after the device configuration has been fully restored via the CVQ.

It also enables the VIRTIO_NET_F_STATUS feature. This allows the device to signal the driver that it needs to send gratuitous ARP with VIRTIO_NET_S_ANNOUNCE, reducing the Live Migration downtime.

Note that kernel headers are update to v7.3-rc3, not a stable version.

PATCH v1:
* Move to VDUSE_SET_FEATURES ioctl instead of config space field.
* Add a few bounds control.
* Update kernel headers to v7.3-rc3.

RFC v4:
* Sync headers with Linux's latest existing and proposed UAPI. Both files constants and new ioctl VDUSE_SET_FEATURES.
* Check for more error conditions and clarified some error messages in ready message processing.
* Add relevant release notes.
* Fix cosmetic whitespaces & checkpath errors.
* Fix error path of vhost_user_iotlb_init and vhost_user_iotlb_init_one.
* Fix commits author.

RFC v3:
* Replace incorrect '%lx' DEBUG print format specifier with PRIx64

RFC v2:
* Following latest comments on kernel series about VDUSE features, not checking API version but only check if VDUSE_GET_FEATURES success.
* Move the start and last declarations in the braces as gcc 8 does not like them interleaved with statements. Actually, I think the move was a mistake in the first version.
https://mails.dpdk.org/archives/test-report/2026-February/958175.html

Eugenio Pérez (3):
uapi: import VDUSE and VFIO header from v7.3-rc3 kernel
vhost: Support VDUSE QUEUE_READY feature
vhost: Support vduse suspend feature

Maxime Coquelin (6):
vhost: introduce ASID support
vhost: add VDUSE API version negotiation
vhost: add virtqueues groups support to VDUSE
vhost: add ASID support to VDUSE IOTLB operations
vhost: claim VDUSE support for API version 1
vhost: add net status feature to VDUSE

 kernel/linux/uapi/linux/vduse.h | 115 ++++++++++++++-
 kernel/linux/uapi/linux/vfio.h  |  91 +++++++++++-
 kernel/linux/uapi/version       |   2 +-
 lib/vhost/iotlb.c               | 233 +++++++++++++++++++------------
 lib/vhost/iotlb.h               |  14 +-
 lib/vhost/vduse.c               | 239 ++++++++++++++++++++++++++++++--
 lib/vhost/vduse.h               |   3 +-
 lib/vhost/vhost.c               |  16 +--
 lib/vhost/vhost.h               |  16 +--
 lib/vhost/vhost_user.c          |  13 +-
 10 files changed, 600 insertions(+), 142 deletions(-)
Signature · 1 line
2.55.0