]> git.proxmox.com Git - mirror_qemu.git/commit
virtio: introduce macro VIRTIO_CONFIG_IRQ_IDX
authorCindy Lu <lulu@redhat.com>
Thu, 22 Dec 2022 07:04:42 +0000 (15:04 +0800)
committerMichael S. Tsirkin <mst@redhat.com>
Sun, 8 Jan 2023 06:54:22 +0000 (01:54 -0500)
commit544f0278afcab2bebab61b14e4c2c58e65911f5b
treeba1f9052a42d1e1d0f714d8dd56598dabdcd5938
parentc9bdc449f97422e62dc802fd2cbe11b840195595
virtio: introduce macro VIRTIO_CONFIG_IRQ_IDX

To support configure interrupt for vhost-vdpa
Introduce VIRTIO_CONFIG_IRQ_IDX -1 as configure interrupt's queue index,
Then we can reuse the functions guest_notifier_mask and guest_notifier_pending.
Add the check of queue index in these drivers, if the driver does not support
configure interrupt, the function will just return

Signed-off-by: Cindy Lu <lulu@redhat.com>
Message-Id: <20221222070451.936503-2-lulu@redhat.com>
Acked-by: Jason Wang <jasowang@redhat.com>
Reviewed-by: Michael S. Tsirkin <mst@redhat.com>
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
hw/display/vhost-user-gpu.c
hw/net/virtio-net.c
hw/virtio/vhost-user-fs.c
hw/virtio/vhost-user-gpio.c
hw/virtio/vhost-vsock-common.c
hw/virtio/virtio-crypto.c
include/hw/virtio/virtio.h