mirror of
https://github.com/Motorhead1991/qemu.git
synced 2025-08-03 07:43:54 -06:00
virtio: merge virtio_queue_aio_set_host_notifier_handler with virtio_queue_set_aio
Eliminating the reentrancy is actually a nice thing that we can do with the API that Michael proposed, so let's make it first class. This also hides the complex assign/set_handler conventions from callers of virtio_queue_aio_set_host_notifier_handler, which in fact was always called with assign=true. Reviewed-by: Cornelia Huck <cornelia.huck@de.ibm.com> Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Reviewed-by: Michael S. Tsirkin <mst@redhat.com> Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
This commit is contained in:
parent
a8f2e5c8ff
commit
a378b49a43
4 changed files with 14 additions and 28 deletions
|
@ -142,9 +142,6 @@ VirtQueue *virtio_add_queue(VirtIODevice *vdev, int queue_size,
|
|||
void (*handle_output)(VirtIODevice *,
|
||||
VirtQueue *));
|
||||
|
||||
void virtio_set_queue_aio(VirtQueue *vq,
|
||||
void (*handle_output)(VirtIODevice *, VirtQueue *));
|
||||
|
||||
void virtio_del_queue(VirtIODevice *vdev, int n);
|
||||
|
||||
void *virtqueue_alloc_element(size_t sz, unsigned out_num, unsigned in_num);
|
||||
|
@ -254,7 +251,8 @@ EventNotifier *virtio_queue_get_host_notifier(VirtQueue *vq);
|
|||
void virtio_queue_set_host_notifier_fd_handler(VirtQueue *vq, bool assign,
|
||||
bool set_handler);
|
||||
void virtio_queue_aio_set_host_notifier_handler(VirtQueue *vq, AioContext *ctx,
|
||||
bool assign, bool set_handler);
|
||||
void (*fn)(VirtIODevice *,
|
||||
VirtQueue *));
|
||||
void virtio_irq(VirtQueue *vq);
|
||||
VirtQueue *virtio_vector_first_queue(VirtIODevice *vdev, uint16_t vector);
|
||||
VirtQueue *virtio_vector_next_queue(VirtQueue *vq);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue