qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] [PULL] virtio-ccw build fix
@ 2013-07-01  9:05 Cornelia Huck
  2013-07-01  9:05 ` [Qemu-devel] [PULL] virtio-ccw: fix build breakage on windows Cornelia Huck
  2013-07-10 16:53 ` [Qemu-devel] [PULL] virtio-ccw build fix Anthony Liguori
  0 siblings, 2 replies; 3+ messages in thread
From: Cornelia Huck @ 2013-07-01  9:05 UTC (permalink / raw)
  To: qemu-devel
  Cc: Blue Swirl, Cornelia Huck, Anthony Liguori, Aurélien Jarno

The following changes since commit ffeec223b55ea696567ed544016824199cd7c7bc:

  Merge remote-tracking branch 'mjt/trivial-patches' into staging (2013-06-28 15:48:35 -0500)

are available in the git repository at:


  git://github.com/cohuck/qemu virtio-ccw-upstr

for you to fetch changes up to cc3ac9c4a6fd0574b767c599e4a582be8f23260d:

  virtio-ccw: fix build breakage on windows (2013-07-01 11:00:20 +0200)

----------------------------------------------------------------
Cornelia Huck (1):
  virtio-ccw: fix build breakage on windows

 hw/s390x/virtio-ccw.c |    6 ++----
 target-s390x/cpu.h    |   11 +++++++----
 target-s390x/kvm.c    |    5 +++--
 3 files changed, 12 insertions(+), 10 deletions(-)

-- 
1.7.9.5

^ permalink raw reply	[flat|nested] 3+ messages in thread

* [Qemu-devel] [PULL] virtio-ccw: fix build breakage on windows
  2013-07-01  9:05 [Qemu-devel] [PULL] virtio-ccw build fix Cornelia Huck
@ 2013-07-01  9:05 ` Cornelia Huck
  2013-07-10 16:53 ` [Qemu-devel] [PULL] virtio-ccw build fix Anthony Liguori
  1 sibling, 0 replies; 3+ messages in thread
From: Cornelia Huck @ 2013-07-01  9:05 UTC (permalink / raw)
  To: qemu-devel
  Cc: Blue Swirl, Cornelia Huck, Anthony Liguori, Aurélien Jarno

event_notifier_get_fd() is not available on windows hosts. Fix this by
moving the calls to event_notifier_get_fd() to the kvm code.

Reported-by: Stefan Weil <sw@weilnetz.de>
Reviewed-by: Paolo Bonzini <pbonzini@redhat.com>
Signed-off-by: Cornelia Huck <cornelia.huck@de.ibm.com>
---
 hw/s390x/virtio-ccw.c |    6 ++----
 target-s390x/cpu.h    |   11 +++++++----
 target-s390x/kvm.c    |    5 +++--
 3 files changed, 12 insertions(+), 10 deletions(-)

diff --git a/hw/s390x/virtio-ccw.c b/hw/s390x/virtio-ccw.c
index faef5dd..e744957 100644
--- a/hw/s390x/virtio-ccw.c
+++ b/hw/s390x/virtio-ccw.c
@@ -79,8 +79,7 @@ static int virtio_ccw_set_guest2host_notifier(VirtioCcwDevice *dev, int n,
             return r;
         }
         virtio_queue_set_host_notifier_fd_handler(vq, true, set_handler);
-        r = s390_assign_subch_ioeventfd(event_notifier_get_fd(notifier), sch_id,
-                                        n, assign);
+        r = s390_assign_subch_ioeventfd(notifier, sch_id, n, assign);
         if (r < 0) {
             error_report("%s: unable to assign ioeventfd: %d", __func__, r);
             virtio_queue_set_host_notifier_fd_handler(vq, false, false);
@@ -89,8 +88,7 @@ static int virtio_ccw_set_guest2host_notifier(VirtioCcwDevice *dev, int n,
         }
     } else {
         virtio_queue_set_host_notifier_fd_handler(vq, false, false);
-        s390_assign_subch_ioeventfd(event_notifier_get_fd(notifier), sch_id,
-                                    n, assign);
+        s390_assign_subch_ioeventfd(notifier, sch_id, n, assign);
         event_notifier_cleanup(notifier);
     }
     return r;
diff --git a/target-s390x/cpu.h b/target-s390x/cpu.h
index 918c819..741c4e4 100644
--- a/target-s390x/cpu.h
+++ b/target-s390x/cpu.h
@@ -1081,7 +1081,8 @@ void kvm_s390_io_interrupt(S390CPU *cpu, uint16_t subchannel_id,
 void kvm_s390_crw_mchk(S390CPU *cpu);
 void kvm_s390_enable_css_support(S390CPU *cpu);
 int kvm_s390_get_registers_partial(CPUState *cpu);
-int kvm_s390_assign_subch_ioeventfd(int fd, uint32_t sch, int vq, bool assign);
+int kvm_s390_assign_subch_ioeventfd(EventNotifier *notifier, uint32_t sch,
+                                    int vq, bool assign);
 #else
 static inline void kvm_s390_io_interrupt(S390CPU *cpu,
                                         uint16_t subchannel_id,
@@ -1100,7 +1101,8 @@ static inline int kvm_s390_get_registers_partial(CPUState *cpu)
 {
     return -ENOSYS;
 }
-static inline int kvm_s390_assign_subch_ioeventfd(int fd, uint32_t sch, int vq,
+static inline int kvm_s390_assign_subch_ioeventfd(EventNotifier *notifier,
+                                                  uint32_t sch, int vq,
                                                   bool assign)
 {
     return -ENOSYS;
@@ -1131,11 +1133,12 @@ static inline void s390_crw_mchk(S390CPU *cpu)
     }
 }
 
-static inline int s390_assign_subch_ioeventfd(int fd, uint32_t sch_id, int vq,
+static inline int s390_assign_subch_ioeventfd(EventNotifier *notifier,
+                                              uint32_t sch_id, int vq,
                                               bool assign)
 {
     if (kvm_enabled()) {
-        return kvm_s390_assign_subch_ioeventfd(fd, sch_id, vq, assign);
+        return kvm_s390_assign_subch_ioeventfd(notifier, sch_id, vq, assign);
     } else {
         return -ENOSYS;
     }
diff --git a/target-s390x/kvm.c b/target-s390x/kvm.c
index b524c35..42f758f 100644
--- a/target-s390x/kvm.c
+++ b/target-s390x/kvm.c
@@ -934,12 +934,13 @@ void kvm_arch_init_irq_routing(KVMState *s)
 {
 }
 
-int kvm_s390_assign_subch_ioeventfd(int fd, uint32_t sch, int vq, bool assign)
+int kvm_s390_assign_subch_ioeventfd(EventNotifier *notifier, uint32_t sch,
+                                    int vq, bool assign)
 {
     struct kvm_ioeventfd kick = {
         .flags = KVM_IOEVENTFD_FLAG_VIRTIO_CCW_NOTIFY |
         KVM_IOEVENTFD_FLAG_DATAMATCH,
-        .fd = fd,
+        .fd = event_notifier_get_fd(notifier),
         .datamatch = vq,
         .addr = sch,
         .len = 8,
-- 
1.7.9.5

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [Qemu-devel] [PULL] virtio-ccw build fix
  2013-07-01  9:05 [Qemu-devel] [PULL] virtio-ccw build fix Cornelia Huck
  2013-07-01  9:05 ` [Qemu-devel] [PULL] virtio-ccw: fix build breakage on windows Cornelia Huck
@ 2013-07-10 16:53 ` Anthony Liguori
  1 sibling, 0 replies; 3+ messages in thread
From: Anthony Liguori @ 2013-07-10 16:53 UTC (permalink / raw)
  To: Cornelia Huck, qemu-devel; +Cc: Blue Swirl, Anthony Liguori, None

Pulled.  Thanks.

Regards,

Anthony Liguori

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2013-07-10 16:53 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-07-01  9:05 [Qemu-devel] [PULL] virtio-ccw build fix Cornelia Huck
2013-07-01  9:05 ` [Qemu-devel] [PULL] virtio-ccw: fix build breakage on windows Cornelia Huck
2013-07-10 16:53 ` [Qemu-devel] [PULL] virtio-ccw build fix Anthony Liguori

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).