diff options
author | Halil Pasic <pasic@linux.ibm.com> | 2024-04-29 13:33:34 +0200 |
---|---|---|
committer | Michael S. Tsirkin <mst@redhat.com> | 2024-07-01 14:56:23 -0400 |
commit | a0eebd790ca4f90fc1e3662cb38542ccc21963bf (patch) | |
tree | 49b081f743571fbfffe85084a0115e61f25db78a /hw/virtio/vhost-vsock-common.c | |
parent | 5093bee0fa8a6c9712c96653da3a79bc37a4e45d (diff) | |
download | qemu-a0eebd790ca4f90fc1e3662cb38542ccc21963bf.zip qemu-a0eebd790ca4f90fc1e3662cb38542ccc21963bf.tar.gz qemu-a0eebd790ca4f90fc1e3662cb38542ccc21963bf.tar.bz2 |
vhost-vsock: add VIRTIO_F_RING_PACKED to feature_bits
Not having VIRTIO_F_RING_PACKED in feature_bits[] is a problem when the
vhost-vsock device does not offer the feature bit VIRTIO_F_RING_PACKED
but the in QEMU device is configured to try to use the packed layout
(the virtio property "packed" is on).
As of today, the Linux kernel vhost-vsock device does not support the
packed queue layout (as vhost does not support packed), and does not
offer VIRTIO_F_RING_PACKED. Thus when for example a vhost-vsock-ccw is
used with packed=on, VIRTIO_F_RING_PACKED ends up being negotiated,
despite the fact that the device does not actually support it, and
one gets to keep the pieces.
Fixes: 74b3e46630 ("virtio: add property to enable packed virtqueue")
Reported-by: Marc Hartmayer <mhartmay@linux.ibm.com>
Signed-off-by: Halil Pasic <pasic@linux.ibm.com>
Message-Id: <20240429113334.2454197-1-pasic@linux.ibm.com>
Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Diffstat (limited to 'hw/virtio/vhost-vsock-common.c')
-rw-r--r-- | hw/virtio/vhost-vsock-common.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/hw/virtio/vhost-vsock-common.c b/hw/virtio/vhost-vsock-common.c index 12ea87d..fd88df2 100644 --- a/hw/virtio/vhost-vsock-common.c +++ b/hw/virtio/vhost-vsock-common.c @@ -22,6 +22,7 @@ const int feature_bits[] = { VIRTIO_VSOCK_F_SEQPACKET, VIRTIO_F_RING_RESET, + VIRTIO_F_RING_PACKED, VHOST_INVALID_FEATURE_BIT }; |