0a122b
From d52f76a894c5a6663ffbee71e020069a86a52989 Mon Sep 17 00:00:00 2001
0a122b
Message-Id: <d52f76a894c5a6663ffbee71e020069a86a52989.1387385113.git.minovotn@redhat.com>
0a122b
From: Stefan Hajnoczi <stefanha@redhat.com>
0a122b
Date: Wed, 11 Dec 2013 09:55:07 +0100
0a122b
Subject: [PATCH] virtio_pci: fix level interrupts with irqfd
0a122b
0a122b
RH-Author: Stefan Hajnoczi <stefanha@redhat.com>
0a122b
Message-id: <1386755707-8033-1-git-send-email-stefanha@redhat.com>
0a122b
Patchwork-id: 56157
0a122b
O-Subject: [RHEL7 qemu-kvm PATCH] virtio_pci: fix level interrupts with irqfd
0a122b
Bugzilla: 1035132
0a122b
RH-Acked-by: Paolo Bonzini <pbonzini@redhat.com>
0a122b
RH-Acked-by: Michael S. Tsirkin <mst@redhat.com>
0a122b
RH-Acked-by: Alex Williamson <alex.williamson@redhat.com>
0a122b
0a122b
From: "Michael S. Tsirkin" <mst@redhat.com>
0a122b
0a122b
BZ: 1035132
0a122b
BZ: 1035150
0a122b
Brew: https://brewweb.devel.redhat.com/taskinfo?taskID=6700088
0a122b
Upstream: merged
0a122b
0a122b
commit 62c96360ae7f2c7a8b029277fbb7cb082fdef7fd
0a122b
    virtio-pci: fix level interrupts
0a122b
only helps systems without irqfd: on systems with irqfd support we
0a122b
passed in flag requesting irqfd even when msix is disabled.
0a122b
0a122b
As a result, for level interrupts we didn't install an fd handler so
0a122b
unmasking an fd had no effect.
0a122b
0a122b
Fix this up.
0a122b
0a122b
Cc: qemu-stable@nongnu.org
0a122b
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
0a122b
0a122b
(cherry picked from commit 23fe2b3f9e7df8da53ac1bc32c6875254911d7f4)
0a122b
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
0a122b
---
0a122b
 hw/virtio/virtio-pci.c | 3 +--
0a122b
 1 file changed, 1 insertion(+), 2 deletions(-)
0a122b
0a122b
Signed-off-by: Michal Novotny <minovotn@redhat.com>
0a122b
---
0a122b
 hw/virtio/virtio-pci.c | 3 +--
0a122b
 1 file changed, 1 insertion(+), 2 deletions(-)
0a122b
0a122b
diff --git a/hw/virtio/virtio-pci.c b/hw/virtio/virtio-pci.c
0a122b
index ba8848f..6f5c434 100644
0a122b
--- a/hw/virtio/virtio-pci.c
0a122b
+++ b/hw/virtio/virtio-pci.c
0a122b
@@ -805,8 +805,7 @@ static int virtio_pci_set_guest_notifiers(DeviceState *d, int nvqs, bool assign)
0a122b
             break;
0a122b
         }
0a122b
 
0a122b
-        r = virtio_pci_set_guest_notifier(d, n, assign,
0a122b
-                                          kvm_msi_via_irqfd_enabled());
0a122b
+        r = virtio_pci_set_guest_notifier(d, n, assign, with_irqfd);
0a122b
         if (r < 0) {
0a122b
             goto assign_error;
0a122b
         }
0a122b
-- 
0a122b
1.7.11.7
0a122b