virtio/vhost: Add checks for uninitialized VQs
Get series with b4
b4 am [email protected]Versions newest first · linked by author and title
- v2 Latest3 patches 3 repliesIn review
- v13 patches 11 repliesSuperseded
Changes in v2 from the cover letter
- Remove now unnecessary virtio_queue_get_num() calls in virtio-pci.c
- Add virtio_queue_valid() calls in vhost_virtqueue_[start,stop]()
Patches in v2 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/3 | virtio: add API to check that ring is setuphw/ hw/ | +6 | 0 replies | |
| 2/3 | virtio-pci: Add virtio_queue_valid checks ahead of virtio_queue_get_numhw/ | +15 | 0 replies | |
| 3/3 | vhost: Skip uninitialized VQs in vhost_virtqueue_[start,stop]hw/ | +12 | 0 replies | |
| 3/3 | vhost: Skip uninitialized VQs in vhost_virtqueue_[start, stop]hw/ | +12 | 0 replies |
Reviews trailers per patch
None of the 4 patches has a Reviewed-by or Acked-by of their own; the series has one for all of them.
| Patch | Michael S. Tsirkin |
|---|---|
| Series | A-b A-b |
| 1/3 | |
| 2/3 | |
| 3/3 | |
| 3/3 |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.
Cover letter [PATCH-v2 0/3] virtio/vhost: Add checks for uninitialized VQs
From: Nicholas Bellinger <[email protected]>
Hi folks,
This series adds a virtio_queue_valid() for use by virtio-pci code in order to prevent opreations upon uninitialized VQs, which is currently expected to occur during seabios setup of virtio-scsi with in-flight vhost-scsi-pci device code.
On the vhost side, it also adds virtio_queue_valid() sanity checks in vhost_virtqueue_[start,stop]() and vhost_verify_ring_mappings() in order to skip the same uninitialized VQs.
Changes from v1:
- Remove now unnecessary virtio_queue_get_num() calls in virtio-pci.c
- Add virtio_queue_valid() calls in vhost_virtqueue_[start,stop]()
Please review.
--nab
Michael S. Tsirkin (1):
virtio: add API to check that ring is setup
Nicholas Bellinger (2):
virtio-pci: Add virtio_queue_valid checks ahead of
virtio_queue_get_num
vhost: Skip uninitialized VQs in vhost_virtqueue_[start,stop]
hw/vhost.c | 12 ++++++++++++ hw/virtio-pci.c | 34 +++++++++++++++------------------- hw/virtio.c | 5 +++++ hw/virtio.h | 1 + 4 files changed, 33 insertions(+), 19 deletions(-)
Signature · 1 line
1.7.2.5