Add VIRTIO_F_IN_ORDER support to vhost shadow virtqueue
Get series with b4
b4 am [email protected]Versions newest first
- v1 Latest7 patches 20 repliesIn review
Patches in v1 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/7 | virtio: Allow to fill a whole virtqueue in orderhw/ | +1 | 7 replies | |
| 2/7 | vhost: move svq next desc array to descs state structhw/ hw/ | +12 | 1 reply | |
| 3/7 | vhost: factor out the descriptor next fetchinghw/ | +20 | 1 reply | |
| 4/7 | vhost: factor out the get of last used desc in SVQhw/ | +29 | 1 reply | |
| 5/7 | vhost: factor out the detach buf logic in SVQhw/ | +16 | 4 replies | |
| 6/7 | vhost: add in_order feature to shadow virtqueuehw/ hw/ | +160 | 1 reply | |
| 7/7 | vhost: accept in order feature flaghw/ | +1 | 1 reply |
Reviews trailers per patch
4 of 7 patches have a Reviewed-by or Acked-by.
| Patch | Jason Wang |
|---|---|
| 1/7 | |
| 2/7 | A-b |
| 3/7 | A-b |
| 4/7 | |
| 5/7 | |
| 6/7 | A-b |
| 7/7 | A-b |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.
Cover letter [PATCH 0/7] Add VIRTIO_F_IN_ORDER support to vhost shadow virtqueue
This series adds support for the VIRTIO_F_IN_ORDER feature flag to vhost shadow virtqueue (SVQ), enabling migration of vDPA devices that offer this feature. As SVQ acts as a virtio driver, the series follows the Linux kernel implementation for the feature by Jason Wang. This enables the live migration of vhost-vdpa devices that supports IN_ORDER.
The IN_ORDER feature allows virtio devices to use many descriptors in batch, just by marking the last one of the set as used.
The series is structured in three parts. First, max_steps calculation in virtqueue_ordered_fill is fixed to allow filling the entire virtqueue at once. Otherwise, a full queue cannot be used with just one used entry.
Afterwards, the series extracts helper functions for descriptor processing to prepare for in order changes:
Finally, the series adds IN_ORDER support, first adding conditional logic for in-order vs regular processing and whitelisting the feature flag in SVQ.
Eugenio Pérez (7):
virtio: Allow to fill a whole virtqueue in order
vhost: move svq next desc array to descs state struct
vhost: factor out the descriptor next fetching
vhost: factor out the get of last used desc in SVQ
vhost: factor out the detach buf logic in SVQ
vhost: add in_order feature to shadow virtqueue
vhost: accept in order feature flag
hw/virtio/vhost-shadow-virtqueue.c | 215 +++++++++++++++++++++++++---- hw/virtio/vhost-shadow-virtqueue.h | 38 ++++- hw/virtio/virtio.c | 2 +- 3 files changed, 219 insertions(+), 36 deletions(-)
Signature · 1 line
2.53.0