Skip to content

vhost: add device op to offload the interrupt kick

Eelco Chaudron dpdk-dev 3 versions – Applied

Status from this message: Applied to dpdk-next-virtio/main.

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v3 Latest4 patches 30 repliesApplied
  2. v23 patches 8 repliesSuperseded
  3. v11 patch 8 repliesSuperseded

Changes in v3 from the cover letter

- Changed ABI compatibility code to no longer use a boolean to avoid having to disable specific GCC warnings.
- Moved the fd check fix to a separate patch (patch 3/4).
- Fixed some coding style issues.

Patches in v3 Applied

#Subject and filesSizeRepliesApplied
1/4vhost: change vhost_virtqueue access lock to a read/write onelib/eal/include/generic/rte_rwlock.h lib/vhost/vhost.c lib/vhost/vhost.h +2 more+94 -776 replies
2/4vhost: make the guest_notifications statistic counter atomiclib/vhost/vhost.c lib/vhost/vhost.h+14 -32 replies
3/4vhost: fix invalid call FD handlinglib/vhost/vhost.h+4 -43 replies
4/4vhost: add device op to offload the interrupt kicklib/vhost/meson.build lib/vhost/rte_vhost.h lib/vhost/socket.c +3 more+171 -2217 replies

Reviews trailers per patch

All 4 patches have a Reviewed-by or Acked-by.

PatchMaxime CoquelinChenbo Xia
1/4T-b R-b R-b
2/4R-b R-b
3/4R-b
4/4R-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v3 thread

Cover letter [PATCH v3 0/4] vhost: add device op to offload the interrupt kick

This series adds an operation callback which gets called every time the library wants to call eventfd_write(). This eventfd_write() call could result in a system call, which could potentially block the PMD thread.

The callback function can decide whether it's ok to handle the eventfd_write() now or have the newly introduced function, rte_vhost_notify_guest(), called at a later time.

This can be used by 3rd party applications, like OVS, to avoid system calls being called as part of the PMD threads.

v3:
- Changed ABI compatibility code to no longer use a boolean to avoid having to disable specific GCC warnings.
- Moved the fd check fix to a separate patch (patch 3/4).
- Fixed some coding style issues.

v2: - Used vhost_virtqueue->index to find index for operation.
- Aligned function name to VDUSE RFC patchset.
- Added error and offload statistics counter.
- Mark new API as experimental.
- Change the virtual queue spin lock to read/write spin lock.
- Made shared counters atomic.
- Add versioned rte_vhost_driver_callback_register() for ABI compliance.

Eelco Chaudron (4):
vhost: change vhost_virtqueue access lock to a read/write one
vhost: make the guest_notifications statistic counter atomic
vhost: fix invalid call FD handling
vhost: add device op to offload the interrupt kick

 lib/eal/include/generic/rte_rwlock.h | 17 +++++
 lib/vhost/meson.build                |  2 +
 lib/vhost/rte_vhost.h                | 23 ++++++-
 lib/vhost/socket.c                   | 63 +++++++++++++++++--
 lib/vhost/version.map                |  9 +++
 lib/vhost/vhost.c                    | 92 +++++++++++++++++++++-------
 lib/vhost/vhost.h                    | 69 ++++++++++++++-------
 lib/vhost/vhost_user.c               | 14 ++---
 lib/vhost/virtio_net.c               | 90 +++++++++++++--------------
 9 files changed, 278 insertions(+), 101 deletions(-)