diff options
author | Jason Wang <jasowang@redhat.com> | 2020-07-01 22:55:27 +0800 |
---|---|---|
committer | Michael S. Tsirkin <mst@redhat.com> | 2020-07-03 07:57:04 -0400 |
commit | b2a5f62a2284a8933f6f6cda48797b7263b96970 (patch) | |
tree | 91f7c200775f4c44672db6d9d1a184910bfe7722 /include | |
parent | 92fbc3e07eb924bd5e03d22764e637b2e02e46bd (diff) |
virtio-bus: introduce queue_enabled method
This patch introduces queue_enabled() method which allows the
transport to implement its own way to report whether or not a queue is
enabled.
Signed-off-by: Jason Wang <jasowang@redhat.com>
Signed-off-by: Cindy Lu <lulu@redhat.com>
Message-Id: <20200701145538.22333-4-lulu@redhat.com>
Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
Acked-by: Jason Wang <jasowang@redhat.com>
Diffstat (limited to 'include')
-rw-r--r-- | include/hw/virtio/virtio-bus.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/include/hw/virtio/virtio-bus.h b/include/hw/virtio/virtio-bus.h index 38c9399cd4..0f6f215925 100644 --- a/include/hw/virtio/virtio-bus.h +++ b/include/hw/virtio/virtio-bus.h @@ -84,6 +84,10 @@ typedef struct VirtioBusClass { int (*ioeventfd_assign)(DeviceState *d, EventNotifier *notifier, int n, bool assign); /* + * Whether queue number n is enabled. + */ + bool (*queue_enabled)(DeviceState *d, int n); + /* * Does the transport have variable vring alignment? * (ie can it ever call virtio_queue_set_align()?) * Note that changing this will break migration for this transport. |