diff options
author | Nicholas Bellinger <nab@linux-iscsi.org> | 2012-07-23 23:39:24 -0700 |
---|---|---|
committer | Nicholas Bellinger <nab@linux-iscsi.org> | 2012-07-24 13:57:45 -0700 |
commit | 32ed0dbb22586b285743110d5f865c32bdb33579 (patch) | |
tree | 772ea4e0a0d395307b5d6c76a09cbd4c05a1ffcf | |
parent | 1523ed9e1d46b0b54540049d491475ccac7e6421 (diff) | |
download | qemu-kvm-vhost-scsi-workaround.tar.gz |
msix: Work-around for vhost-scsi with KVM in-kernel MSI injectionvhost-scsi-workaround
This is required to get past the following assert with:
commit 1523ed9e1d46b0b54540049d491475ccac7e6421
Author: Jan Kiszka <jan.kiszka@siemens.com>
Date: Thu May 17 10:32:39 2012 -0300
virtio/vhost: Add support for KVM in-kernel MSI injection
Signed-off-by: Nicholas Bellinger <nab@linux-iscsi.org>
-rw-r--r-- | hw/msix.c | 5 | ||||
-rw-r--r-- | hw/virtio-pci.c | 3 |
2 files changed, 8 insertions, 0 deletions
diff --git a/hw/msix.c b/hw/msix.c index 59c7a8388fd..60369095868 100644 --- a/hw/msix.c +++ b/hw/msix.c @@ -511,6 +511,11 @@ void msix_unset_vector_notifiers(PCIDevice *dev) { int vector; + if (!dev->msix_vector_use_notifier && !dev->msix_vector_release_notifier) { + printf("Hit NULL msix_unset_vector_notifiers for: %s\n", dev->name); + return; + } + assert(dev->msix_vector_use_notifier && dev->msix_vector_release_notifier); diff --git a/hw/virtio-pci.c b/hw/virtio-pci.c index 0faf2db9662..b6c89eab995 100644 --- a/hw/virtio-pci.c +++ b/hw/virtio-pci.c @@ -698,6 +698,9 @@ static int virtio_pci_set_guest_notifiers(void *opaque, bool assign) VirtIODevice *vdev = proxy->vdev; int r, n; + printf("virtio_pci_set_guest_notifiers: %p, vdev: %p assign: %d\n", + opaque, vdev, assign); + /* Must unset vector notifier while guest notifier is still assigned */ if (kvm_irqchip_in_kernel() && !assign) { msix_unset_vector_notifiers(&proxy->pci_dev); |