[Spice-commits] 2 commits - hw/Makefile.objs hw/dataplane qemu-char.c

Gerd Hoffmann kraxel at kemper.freedesktop.org
Fri Jan 4 00:18:10 PST 2013


 hw/Makefile.objs           |    3 ++-
 hw/dataplane/Makefile.objs |    4 +---
 qemu-char.c                |    9 +++++----
 3 files changed, 8 insertions(+), 8 deletions(-)

New commits:
commit 25bbf61e4bacd1e4fa4115ffcf151051b9d6608e
Author: Gerd Hoffmann <kraxel at redhat.com>
Date:   Thu Jan 3 14:23:03 2013 +0100

    pty: unbreak libvirt
    
    Commit 586502189edf9fd0f89a83de96717a2ea826fdb0 breaks libvirt pty
    support because it tried to figure the pts name from stderr output.
    
    Fix this by moving the label to the end of the line, this way the
    libvirt parser does still recognise the message.  libvirt looks
    for "char device redirected to ${ptsname}<whitespace>".
    
    Signed-off-by: Gerd Hoffmann <kraxel at redhat.com>
    Signed-off-by: Anthony Liguori <aliguori at us.ibm.com>

diff --git a/qemu-char.c b/qemu-char.c
index 331ad5c..f41788c 100644
--- a/qemu-char.c
+++ b/qemu-char.c
@@ -1012,10 +1012,11 @@ static CharDriverState *qemu_chr_open_pty(QemuOpts *opts)
     qemu_opt_set(opts, "path", q_ptsname(master_fd));
 
     label = qemu_opts_id(opts);
-    fprintf(stderr, "char device%s%s redirected to %s\n",
-            label ? " " : "",
-            label ?: "",
-            q_ptsname(master_fd));
+    fprintf(stderr, "char device redirected to %s%s%s%s\n",
+            q_ptsname(master_fd),
+            label ? " (label " : "",
+            label ? label      : "",
+            label ? ")"        : "");
 
     s = g_malloc0(sizeof(PtyCharDriver));
     chr->opaque = s;
commit ef4929fb3c25e03deca76c7f5d22fba08edf864f
Author: Stefan Hajnoczi <stefanha at redhat.com>
Date:   Thu Jan 3 11:56:16 2013 +0100

    dataplane: use linux-headers/ for virtio includes
    
    The hw/dataplane/vring.c code includes linux/virtio_ring.h.  Ensure that
    we use linux-headers/ instead of the system-wide headers, which may be
    out-of-date on older distros.
    
    This resolves the following build error on Debian 6:
    
      CC    hw/dataplane/vring.o
    cc1: warnings being treated as errors
    hw/dataplane/vring.c: In function 'vring_enable_notification':
    hw/dataplane/vring.c:71: error: implicit declaration of function 'vring_avail_event'
    hw/dataplane/vring.c:71: error: nested extern declaration of 'vring_avail_event'
    hw/dataplane/vring.c:71: error: lvalue required as left operand of assignment
    
    Note that we now build dataplane/ for each target instead of only once.
    There is no way around this since linux-headers/ is only available for
    per-target objects - and it's how virtio, vfio, kvm, and friends are
    built.
    
    Signed-off-by: Stefan Hajnoczi <stefanha at redhat.com>
    Signed-off-by: Anthony Liguori <aliguori at us.ibm.com>

diff --git a/hw/Makefile.objs b/hw/Makefile.objs
index 5ac4913..b8bbed3 100644
--- a/hw/Makefile.objs
+++ b/hw/Makefile.objs
@@ -1,4 +1,4 @@
-common-obj-y = usb/ ide/ pci/ dataplane/
+common-obj-y = usb/ ide/ pci/
 common-obj-y += loader.o
 common-obj-$(CONFIG_VIRTIO) += virtio-console.o
 common-obj-$(CONFIG_VIRTIO) += virtio-rng.o
@@ -191,6 +191,7 @@ common-obj-$(CONFIG_XEN_BACKEND) += xen_console.o xenfb.o xen_disk.o xen_nic.o
 # Per-target files
 # virtio has to be here due to weird dependency between PCI and virtio-net.
 # need to fix this properly
+obj-$(CONFIG_VIRTIO) += dataplane/
 obj-$(CONFIG_VIRTIO) += virtio.o virtio-blk.o virtio-balloon.o virtio-net.o
 obj-$(CONFIG_VIRTIO) += virtio-serial-bus.o virtio-scsi.o
 obj-$(CONFIG_SOFTMMU) += vhost_net.o
diff --git a/hw/dataplane/Makefile.objs b/hw/dataplane/Makefile.objs
index 682aa9e..3e47d05 100644
--- a/hw/dataplane/Makefile.objs
+++ b/hw/dataplane/Makefile.objs
@@ -1,3 +1 @@
-ifeq ($(CONFIG_VIRTIO), y)
-common-obj-$(CONFIG_VIRTIO_BLK_DATA_PLANE) += hostmem.o vring.o event-poll.o ioq.o virtio-blk.o
-endif
+obj-$(CONFIG_VIRTIO_BLK_DATA_PLANE) += hostmem.o vring.o event-poll.o ioq.o virtio-blk.o


More information about the Spice-commits mailing list