diff -Nru qemu-1.4.0+dfsg/debian/changelog qemu-1.4.0+dfsg/debian/changelog --- qemu-1.4.0+dfsg/debian/changelog 2013-04-03 13:31:04.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/changelog 2013-04-07 13:36:44.000000000 +0000 @@ -1,15 +1,10 @@ -qemu (1.4.0+dfsg-1expubuntu5~ppa2) raring; urgency=low +qemu (1.4.0+dfsg-1expubuntu6~ppa1) raring; urgency=low - * fix stupid typo : EAGAIN not -EAGAIN. + * add openbios-ppc to qemu-system-ppc Suggests (now that it's in the + archive) + * add qemu 1.4.1-stable patchset. - -- Serge Hallyn Wed, 03 Apr 2013 08:30:46 -0500 - -qemu (1.4.0+dfsg-1expubuntu5~ppa1) raring; urgency=low - - * 0002-migration-buffer-retry-on-eagain.patch - don't fail a migration - when socket send gives us -EAGAIN. (LP: #1157626) - - -- Serge Hallyn Tue, 02 Apr 2013 14:55:15 -0500 + -- Serge Hallyn Fri, 05 Apr 2013 15:08:27 -0500 qemu (1.4.0+dfsg-1expubuntu4) raring; urgency=low diff -Nru qemu-1.4.0+dfsg/debian/control qemu-1.4.0+dfsg/debian/control --- qemu-1.4.0+dfsg/debian/control 2013-03-14 19:52:02.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/control 2013-03-19 20:41:18.000000000 +0000 @@ -261,7 +261,7 @@ Breaks: qemu-system (<< 1.3.0+dfsg-5), qemu-kvm (<< 1.2.0.dfsg-1), qemu-common (<< 1.2.0.dfsg-1), kvm (<< 1.3.0+dfsg-5) Replaces: qemu-system (<< 1.3.0+dfsg-5), qemu-kvm (<< 1.2.0.dfsg-1), qemu-common (<< 1.2.0.dfsg-1), kvm (<< 1.3.0+dfsg-5) Recommends: qemu-utils -Suggests: samba, vde2 +Suggests: samba, vde2, openbios-ppc Description: QEMU full system emulation binaries (ppc) QEMU is a fast processor emulator: currently the package supports PowerPC emulation. By using dynamic translation it achieves diff -Nru qemu-1.4.0+dfsg/debian/patches/0002-migration-buffer-retry-on-eagain.patch qemu-1.4.0+dfsg/debian/patches/0002-migration-buffer-retry-on-eagain.patch --- qemu-1.4.0+dfsg/debian/patches/0002-migration-buffer-retry-on-eagain.patch 2013-04-03 13:30:45.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/0002-migration-buffer-retry-on-eagain.patch 1970-01-01 00:00:00.000000000 +0000 @@ -1,21 +0,0 @@ -Description: when sending migration buffer, retry on -EAGAIN - Otherwise getting EAGAIN causes us to call the migration an error. - This is not forwarded upstream because the code is no longer used - upstream. -Author: Serge Hallyn -Bug-Ubuntu: https://bugs.launchpad.net/ubuntu/+source/qemu/+bug/1157626 -Forwarded: no - -Index: qemu-1.4.0+dfsg/migration.c -=================================================================== ---- qemu-1.4.0+dfsg.orig/migration.c 2013-04-02 14:51:27.000000000 -0500 -+++ qemu-1.4.0+dfsg/migration.c 2013-04-03 08:30:44.339548052 -0500 -@@ -305,7 +305,7 @@ static ssize_t migrate_fd_put_buffer(Mig - - do { - ret = s->write(s, data, size); -- } while (ret == -1 && ((s->get_error(s)) == EINTR)); -+ } while (ret == -1 && ((s->get_error(s)) == EINTR || (s->get_error(s)) == EAGAIN)); - - if (ret == -1) - ret = -(s->get_error(s)); diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0001-target-ppc-Fix-G2leGP3-PVR.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0001-target-ppc-Fix-G2leGP3-PVR.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0001-target-ppc-Fix-G2leGP3-PVR.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0001-target-ppc-Fix-G2leGP3-PVR.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,39 @@ +From 80d8b5da48c29bfb086254a6caf87a432f63d130 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Andreas=20F=C3=A4rber?= +Date: Sun, 17 Feb 2013 23:16:00 +0000 +Subject: [PATCH 01/54] target-ppc: Fix "G2leGP3" PVR +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +Unlike derived PVR constants mapped to CPU_POWERPC_G2LEgp3, the +"G2leGP3" model definition itself used the CPU_POWERPC_G2LEgp1 PVR. + +Fixing this will allow to alias CPU_POWERPC_G2LEgp3-using types to +"G2leGP3". + +Signed-off-by: Andreas Färber +Signed-off-by: Alexander Graf +(cherry picked from commit bfe6d5b0daf9fdafeb0dbb7c26774dbb1bbb4507) + +Signed-off-by: Michael Roth +--- + target-ppc/translate_init.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/target-ppc/translate_init.c b/target-ppc/translate_init.c +index 6cebaa1..63e6fdc 100644 +--- a/target-ppc/translate_init.c ++++ b/target-ppc/translate_init.c +@@ -8243,7 +8243,7 @@ static const ppc_def_t ppc_defs[] = { + /* PowerPC G2LE GP1 core */ + POWERPC_DEF("G2leGP1", CPU_POWERPC_G2LEgp1, G2LE), + /* PowerPC G2LE GP3 core */ +- POWERPC_DEF("G2leGP3", CPU_POWERPC_G2LEgp1, G2LE), ++ POWERPC_DEF("G2leGP3", CPU_POWERPC_G2LEgp3, G2LE), + /* PowerPC MPC603 microcontrollers */ + /* MPC8240 */ + POWERPC_DEF("MPC8240", CPU_POWERPC_MPC8240, 603E), +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0002-coroutine-trim-down-nesting-level-in-perf_nesting-te.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0002-coroutine-trim-down-nesting-level-in-perf_nesting-te.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0002-coroutine-trim-down-nesting-level-in-perf_nesting-te.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0002-coroutine-trim-down-nesting-level-in-perf_nesting-te.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,36 @@ +From 51968b8503a00b5128fb4e3ed14efb8dc69579ce Mon Sep 17 00:00:00 2001 +From: Paolo Bonzini +Date: Tue, 19 Feb 2013 11:59:10 +0100 +Subject: [PATCH 02/54] coroutine: trim down nesting level in perf_nesting test + +20000 nested coroutines require 20 GB of virtual address space. +Only nest 1000 of them so that the test (only enabled with +"-m perf" on the command line) runs on 32-bit machines too. + +Cc: qemu-stable@nongnu.org +Signed-off-by: Paolo Bonzini +Reviewed-by: Stefan Hajnoczi +Signed-off-by: Kevin Wolf +(cherry picked from commit 027003152f4cf21952f9282b4487daf3fdd372ba) + +Signed-off-by: Michael Roth +--- + tests/test-coroutine.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/tests/test-coroutine.c b/tests/test-coroutine.c +index 4c6cc81..39be046 100644 +--- a/tests/test-coroutine.c ++++ b/tests/test-coroutine.c +@@ -183,7 +183,7 @@ static void perf_nesting(void) + double duration; + + maxcycles = 100000000; +- maxnesting = 20000; ++ maxnesting = 1000; + Coroutine *root; + NestData nd = { + .n_enter = 0, +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0003-block-complete-all-IOs-before-.bdrv_truncate.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0003-block-complete-all-IOs-before-.bdrv_truncate.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0003-block-complete-all-IOs-before-.bdrv_truncate.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0003-block-complete-all-IOs-before-.bdrv_truncate.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,38 @@ +From e6b795f34e2dfb440340d559c6813ce0febec937 Mon Sep 17 00:00:00 2001 +From: Peter Lieven +Date: Mon, 18 Feb 2013 13:48:31 +0100 +Subject: [PATCH 03/54] block: complete all IOs before .bdrv_truncate + +bdrv_truncate() invalidates the bdrv_check_request() result for +in-flight requests, so there should better be none. + +Cc: qemu-stable@nongnu.org +Signed-off-by: Peter Lieven +Reported-by: Kevin Wolf +Reviewed-by: Paolo Bonzini +Signed-off-by: Kevin Wolf +(cherry picked from commit 9a665b2b8640e464f0a778216fc2dca8d02acf33) + +Signed-off-by: Michael Roth +--- + block.c | 4 ++++ + 1 file changed, 4 insertions(+) + +diff --git a/block.c b/block.c +index 50dab8e..11f162b 100644 +--- a/block.c ++++ b/block.c +@@ -2427,6 +2427,10 @@ int bdrv_truncate(BlockDriverState *bs, int64_t offset) + return -EACCES; + if (bdrv_in_use(bs)) + return -EBUSY; ++ ++ /* There better not be any in-flight IOs when we truncate the device. */ ++ bdrv_drain_all(); ++ + ret = drv->bdrv_truncate(bs, offset); + if (ret == 0) { + ret = refresh_total_sectors(bs, offset >> BDRV_SECTOR_BITS); +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0004-tap-forbid-creating-multiqueue-tap-when-hub-is-used.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0004-tap-forbid-creating-multiqueue-tap-when-hub-is-used.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0004-tap-forbid-creating-multiqueue-tap-when-hub-is-used.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0004-tap-forbid-creating-multiqueue-tap-when-hub-is-used.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,40 @@ +From 332e93417a677a2f6845cd7215a2f20a227d3251 Mon Sep 17 00:00:00 2001 +From: Jason Wang +Date: Thu, 21 Feb 2013 11:05:56 +0800 +Subject: [PATCH 04/54] tap: forbid creating multiqueue tap when hub is used + +Obviously, hub does not support multiqueue tap. So this patch forbids creating +multiple queue tap when hub is used to prevent the crash when command line such +as "-net tap,queues=2" is used. + +Cc: qemu-stable@nongnu.org +Signed-off-by: Jason Wang +Signed-off-by: Stefan Hajnoczi +(cherry picked from commit ce675a7579fea498397c5d2da3c5367671e9f02a) + +Signed-off-by: Michael Roth +--- + net/tap.c | 7 +++++++ + 1 file changed, 7 insertions(+) + +diff --git a/net/tap.c b/net/tap.c +index 48c254e..daab350 100644 +--- a/net/tap.c ++++ b/net/tap.c +@@ -693,6 +693,13 @@ int net_init_tap(const NetClientOptions *opts, const char *name, + queues = tap->has_queues ? tap->queues : 1; + vhostfdname = tap->has_vhostfd ? tap->vhostfd : NULL; + ++ /* QEMU vlans does not support multiqueue tap, in this case peer is set. ++ * For -netdev, peer is always NULL. */ ++ if (peer && (tap->has_queues || tap->has_fds || tap->has_vhostfds)) { ++ error_report("Multiqueue tap cannnot be used with QEMU vlans"); ++ return -1; ++ } ++ + if (tap->has_fd) { + if (tap->has_ifname || tap->has_script || tap->has_downscript || + tap->has_vnet_hdr || tap->has_helper || tap->has_queues || +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0005-qemu-char.c-fix-waiting-for-telnet-connection-messag.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0005-qemu-char.c-fix-waiting-for-telnet-connection-messag.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0005-qemu-char.c-fix-waiting-for-telnet-connection-messag.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0005-qemu-char.c-fix-waiting-for-telnet-connection-messag.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,37 @@ +From ec9f828341cb5e9cc3ad0bdbbd6989884daf823a Mon Sep 17 00:00:00 2001 +From: Igor Mitsyanko +Date: Sun, 10 Mar 2013 17:58:05 +0400 +Subject: [PATCH 05/54] qemu-char.c: fix waiting for telnet connection message + +Current colon position in "waiting for telnet connection" message template +produces messages like: +QEMU waiting for connection on: telnet::127.0.0.16666,server + +After moving a colon to the right, we will get a correct messages like: +QEMU waiting for connection on: telnet:127.0.0.1:6666,server + +Signed-off-by: Igor Mitsyanko +Signed-off-by: Gerd Hoffmann +(cherry picked from commit e5545854dd1e2e3507b210ac0c1cbfca69ff0fcb) + +Signed-off-by: Michael Roth +--- + qemu-char.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/qemu-char.c b/qemu-char.c +index e4b0f53..3e152e1 100644 +--- a/qemu-char.c ++++ b/qemu-char.c +@@ -2482,7 +2482,7 @@ static CharDriverState *qemu_chr_open_socket_fd(int fd, bool do_nodelay, + s->do_nodelay = do_nodelay; + getnameinfo((struct sockaddr *) &ss, ss_len, host, sizeof(host), + serv, sizeof(serv), NI_NUMERICHOST | NI_NUMERICSERV); +- snprintf(chr->filename, 256, "%s:%s:%s%s%s%s", ++ snprintf(chr->filename, 256, "%s:%s%s%s:%s%s", + is_telnet ? "telnet" : "tcp", + left, host, right, serv, + is_listen ? ",server" : ""); +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0006-net-reduce-the-unnecessary-memory-allocation-of-mult.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0006-net-reduce-the-unnecessary-memory-allocation-of-mult.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0006-net-reduce-the-unnecessary-memory-allocation-of-mult.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0006-net-reduce-the-unnecessary-memory-allocation-of-mult.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,138 @@ +From 3b39a11cde495b42776889031769d730cbfd0993 Mon Sep 17 00:00:00 2001 +From: Jason Wang +Date: Fri, 22 Feb 2013 23:15:06 +0800 +Subject: [PATCH 06/54] net: reduce the unnecessary memory allocation of + multiqueue + +Edivaldo reports a problem that the array of NetClientState in NICState is too +large - MAX_QUEUE_NUM(1024) which will wastes memory even if multiqueue is not +used. + +Instead of static arrays, solving this issue by allocating the queues on demand +for both the NetClientState array in NICState and VirtIONetQueue array in +VirtIONet. + +Tested by myself, with single virtio-net-pci device. The memory allocation is +almost the same as when multiqueue is not merged. + +Cc: Edivaldo de Araujo Pereira +Cc: qemu-stable@nongnu.org +Signed-off-by: Jason Wang +Signed-off-by: Stefan Hajnoczi +(cherry picked from commit f6b26cf257232e5854c0e5c98a8685c625bf986e) + +Signed-off-by: Michael Roth +--- + hw/virtio-net.c | 6 ++++-- + include/net/net.h | 2 +- + net/net.c | 19 +++++++++---------- + 3 files changed, 14 insertions(+), 13 deletions(-) + +diff --git a/hw/virtio-net.c b/hw/virtio-net.c +index 573c669..bb2c26c 100644 +--- a/hw/virtio-net.c ++++ b/hw/virtio-net.c +@@ -44,7 +44,7 @@ typedef struct VirtIONet + VirtIODevice vdev; + uint8_t mac[ETH_ALEN]; + uint16_t status; +- VirtIONetQueue vqs[MAX_QUEUE_NUM]; ++ VirtIONetQueue *vqs; + VirtQueue *ctrl_vq; + NICState *nic; + uint32_t tx_timeout; +@@ -1326,8 +1326,9 @@ VirtIODevice *virtio_net_init(DeviceState *dev, NICConf *conf, + n->vdev.set_status = virtio_net_set_status; + n->vdev.guest_notifier_mask = virtio_net_guest_notifier_mask; + n->vdev.guest_notifier_pending = virtio_net_guest_notifier_pending; ++ n->max_queues = MAX(conf->queues, 1); ++ n->vqs = g_malloc0(sizeof(VirtIONetQueue) * n->max_queues); + n->vqs[0].rx_vq = virtio_add_queue(&n->vdev, 256, virtio_net_handle_rx); +- n->max_queues = conf->queues; + n->curr_queues = 1; + n->vqs[0].n = n; + n->tx_timeout = net->txtimer; +@@ -1412,6 +1413,7 @@ void virtio_net_exit(VirtIODevice *vdev) + } + } + ++ g_free(n->vqs); + qemu_del_nic(n->nic); + virtio_cleanup(&n->vdev); + } +diff --git a/include/net/net.h b/include/net/net.h +index 43a045e..cb049a1 100644 +--- a/include/net/net.h ++++ b/include/net/net.h +@@ -72,7 +72,7 @@ struct NetClientState { + }; + + typedef struct NICState { +- NetClientState ncs[MAX_QUEUE_NUM]; ++ NetClientState *ncs; + NICConf *conf; + void *opaque; + bool peer_deleted; +diff --git a/net/net.c b/net/net.c +index be03a8d..6262ed0 100644 +--- a/net/net.c ++++ b/net/net.c +@@ -235,23 +235,20 @@ NICState *qemu_new_nic(NetClientInfo *info, + const char *name, + void *opaque) + { +- NetClientState *nc; + NetClientState **peers = conf->peers.ncs; + NICState *nic; +- int i; ++ int i, queues = MAX(1, conf->queues); + + assert(info->type == NET_CLIENT_OPTIONS_KIND_NIC); + assert(info->size >= sizeof(NICState)); + +- nc = qemu_new_net_client(info, peers[0], model, name); +- nc->queue_index = 0; +- +- nic = qemu_get_nic(nc); ++ nic = g_malloc0(info->size + sizeof(NetClientState) * queues); ++ nic->ncs = (void *)nic + info->size; + nic->conf = conf; + nic->opaque = opaque; + +- for (i = 1; i < conf->queues; i++) { +- qemu_net_client_setup(&nic->ncs[i], info, peers[i], model, nc->name, ++ for (i = 0; i < queues; i++) { ++ qemu_net_client_setup(&nic->ncs[i], info, peers[i], model, name, + NULL); + nic->ncs[i].queue_index = i; + } +@@ -261,7 +258,7 @@ NICState *qemu_new_nic(NetClientInfo *info, + + NetClientState *qemu_get_subqueue(NICState *nic, int queue_index) + { +- return &nic->ncs[queue_index]; ++ return nic->ncs + queue_index; + } + + NetClientState *qemu_get_queue(NICState *nic) +@@ -273,7 +270,7 @@ NICState *qemu_get_nic(NetClientState *nc) + { + NetClientState *nc0 = nc - nc->queue_index; + +- return DO_UPCAST(NICState, ncs[0], nc0); ++ return (NICState *)((void *)nc0 - nc->info->size); + } + + void *qemu_get_nic_opaque(NetClientState *nc) +@@ -368,6 +365,8 @@ void qemu_del_nic(NICState *nic) + qemu_cleanup_net_client(nc); + qemu_free_net_client(nc); + } ++ ++ g_free(nic); + } + + void qemu_foreach_nic(qemu_nic_foreach func, void *opaque) +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0007-help-add-docs-for-multiqueue-tap-options.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0007-help-add-docs-for-multiqueue-tap-options.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0007-help-add-docs-for-multiqueue-tap-options.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0007-help-add-docs-for-multiqueue-tap-options.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,74 @@ +From cebb8ebe41001c37aa3d88770209889728da6ea8 Mon Sep 17 00:00:00 2001 +From: Jason Wang +Date: Wed, 20 Feb 2013 18:04:01 +0800 +Subject: [PATCH 07/54] help: add docs for multiqueue tap options + +Cc: Markus Armbruster +Cc: Jason Wang +Signed-off-by: Jason Wang +Message-id: 1361354641-51969-1-git-send-email-jasowang@redhat.com +Signed-off-by: Anthony Liguori +(cherry picked from commit 2ca81baa0b3363d57de94f8b80c02a003b361161) + +Signed-off-by: Michael Roth +--- + qapi-schema.json | 6 ++++++ + qemu-options.hx | 4 +++- + 2 files changed, 9 insertions(+), 1 deletion(-) + +diff --git a/qapi-schema.json b/qapi-schema.json +index 7275b5d..cd7ea25 100644 +--- a/qapi-schema.json ++++ b/qapi-schema.json +@@ -2504,6 +2504,9 @@ + # + # @fd: #optional file descriptor of an already opened tap + # ++# @fds: #optional multiple file descriptors of already opened multiqueue capable ++# tap ++# + # @script: #optional script to initialize the interface + # + # @downscript: #optional script to shut down the interface +@@ -2518,6 +2521,9 @@ + # + # @vhostfd: #optional file descriptor of an already opened vhost net device + # ++# @vhostfds: #optional file descriptors of multiple already opened vhost net ++# devices ++# + # @vhostforce: #optional vhost on for non-MSIX virtio guests + # + # Since 1.2 +diff --git a/qemu-options.hx b/qemu-options.hx +index 9d7131a..be21048 100644 +--- a/qemu-options.hx ++++ b/qemu-options.hx +@@ -1338,7 +1338,7 @@ DEF("net", HAS_ARG, QEMU_OPTION_net, + "-net tap[,vlan=n][,name=str],ifname=name\n" + " connect the host TAP network interface to VLAN 'n'\n" + #else +- "-net tap[,vlan=n][,name=str][,fd=h][,ifname=name][,script=file][,downscript=dfile][,helper=helper][,sndbuf=nbytes][,vnet_hdr=on|off][,vhost=on|off][,vhostfd=h][,vhostforce=on|off]\n" ++ "-net tap[,vlan=n][,name=str][,fd=h][,fds=x:y:...:z][,ifname=name][,script=file][,downscript=dfile][,helper=helper][,sndbuf=nbytes][,vnet_hdr=on|off][,vhost=on|off][,vhostfd=h][,vhostfds=x:y:...:z][,vhostforce=on|off]\n" + " connect the host TAP network interface to VLAN 'n'\n" + " use network scripts 'file' (default=" DEFAULT_NETWORK_SCRIPT ")\n" + " to configure it and 'dfile' (default=" DEFAULT_NETWORK_DOWN_SCRIPT ")\n" +@@ -1347,6 +1347,7 @@ DEF("net", HAS_ARG, QEMU_OPTION_net, + " use network helper 'helper' (default=" DEFAULT_BRIDGE_HELPER ") to\n" + " configure it\n" + " use 'fd=h' to connect to an already opened TAP interface\n" ++ " use 'fds=x:y:...:z' to connect to already opened multiqueue capable TAP interfaces\n" + " use 'sndbuf=nbytes' to limit the size of the send buffer (the\n" + " default is disabled 'sndbuf=0' to enable flow control set 'sndbuf=1048576')\n" + " use vnet_hdr=off to avoid enabling the IFF_VNET_HDR tap flag\n" +@@ -1355,6 +1356,7 @@ DEF("net", HAS_ARG, QEMU_OPTION_net, + " (only has effect for virtio guests which use MSIX)\n" + " use vhostforce=on to force vhost on for non-MSIX virtio guests\n" + " use 'vhostfd=h' to connect to an already opened vhost net device\n" ++ " use 'vhostfds=x:y:...:z to connect to multiple already opened vhost net devices\n" + "-net bridge[,vlan=n][,name=str][,br=bridge][,helper=helper]\n" + " connects a host TAP network interface to a host bridge device 'br'\n" + " (default=" DEFAULT_BRIDGE_INTERFACE ") using the program 'helper'\n" +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0008-vga-fix-byteswapping.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0008-vga-fix-byteswapping.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0008-vga-fix-byteswapping.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0008-vga-fix-byteswapping.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,165 @@ +From d49fed4c55e3f4dd4a8c4a4d68b938b12a36802c Mon Sep 17 00:00:00 2001 +From: Gerd Hoffmann +Date: Wed, 20 Feb 2013 09:37:12 +0100 +Subject: [PATCH 08/54] vga: fix byteswapping. + +In case host and guest endianness differ the vga code first creates +a shared surface (using qemu_create_displaysurface_from), then goes +patch the surface format to indicate that the bytes must be swapped. + +The switch to pixman broke that hack as the format patching isn't +propagated into the pixman image, so ui code using the pixman image +directly (such as vnc) uses the wrong format. + +Fix that by adding a byteswap parameter to +qemu_create_displaysurface_from, so we'll use the correct format +when creating the surface (and the pixman image) and don't have +to patch the format afterwards. + +[ v2: unbreak xen build ] + +Cc: qemu-stable@nongnu.org +Cc: mark.cave-ayland@ilande.co.uk +Cc: agraf@suse.de +Signed-off-by: Gerd Hoffmann +Message-id: 1361349432-23884-1-git-send-email-kraxel@redhat.com +Signed-off-by: Anthony Liguori +(cherry picked from commit b1424e0381a7f1c9969079eca4458d5f20bf1859) + +Signed-off-by: Michael Roth +--- + hw/qxl-render.c | 3 ++- + hw/vga.c | 18 ++++++++---------- + hw/vmware_vga.c | 2 +- + hw/xenfb.c | 3 ++- + include/ui/console.h | 3 ++- + ui/console.c | 9 +++++++-- + 6 files changed, 22 insertions(+), 16 deletions(-) + +diff --git a/hw/qxl-render.c b/hw/qxl-render.c +index 88e63f8..455fb91 100644 +--- a/hw/qxl-render.c ++++ b/hw/qxl-render.c +@@ -118,7 +118,8 @@ static void qxl_render_update_area_unlocked(PCIQXLDevice *qxl) + qxl->guest_primary.surface.height, + qxl->guest_primary.bits_pp, + qxl->guest_primary.abs_stride, +- qxl->guest_primary.data); ++ qxl->guest_primary.data, ++ false); + } else { + qemu_resize_displaysurface(vga->ds, + qxl->guest_primary.surface.width, +diff --git a/hw/vga.c b/hw/vga.c +index e2ba7f2..1caf23d 100644 +--- a/hw/vga.c ++++ b/hw/vga.c +@@ -1643,6 +1643,11 @@ static void vga_draw_graphic(VGACommonState *s, int full_update) + uint8_t *d; + uint32_t v, addr1, addr; + vga_draw_line_func *vga_draw_line; ++#if defined(HOST_WORDS_BIGENDIAN) == defined(TARGET_WORDS_BIGENDIAN) ++ static const bool byteswap = false; ++#else ++ static const bool byteswap = true; ++#endif + + full_update |= update_basic_params(s); + +@@ -1685,18 +1690,11 @@ static void vga_draw_graphic(VGACommonState *s, int full_update) + disp_width != s->last_width || + height != s->last_height || + s->last_depth != depth) { +-#if defined(HOST_WORDS_BIGENDIAN) == defined(TARGET_WORDS_BIGENDIAN) +- if (depth == 16 || depth == 32) { +-#else +- if (depth == 32) { +-#endif ++ if (depth == 32 || (depth == 16 && !byteswap)) { + qemu_free_displaysurface(s->ds); + s->ds->surface = qemu_create_displaysurface_from(disp_width, height, depth, + s->line_offset, +- s->vram_ptr + (s->start_addr * 4)); +-#if defined(HOST_WORDS_BIGENDIAN) != defined(TARGET_WORDS_BIGENDIAN) +- s->ds->surface->pf = qemu_different_endianness_pixelformat(depth); +-#endif ++ s->vram_ptr + (s->start_addr * 4), byteswap); + dpy_gfx_resize(s->ds); + } else { + qemu_console_resize(s->ds, disp_width, height); +@@ -1715,7 +1713,7 @@ static void vga_draw_graphic(VGACommonState *s, int full_update) + s->ds->surface = qemu_create_displaysurface_from(disp_width, + height, depth, + s->line_offset, +- s->vram_ptr + (s->start_addr * 4)); ++ s->vram_ptr + (s->start_addr * 4), byteswap); + dpy_gfx_setdata(s->ds); + } + +diff --git a/hw/vmware_vga.c b/hw/vmware_vga.c +index cd15ee4..8fc201b 100644 +--- a/hw/vmware_vga.c ++++ b/hw/vmware_vga.c +@@ -1074,7 +1074,7 @@ static void vmsvga_screen_dump(void *opaque, const char *filename, bool cswitch, + ds_get_height(s->vga.ds), + 32, + ds_get_linesize(s->vga.ds), +- s->vga.vram_ptr); ++ s->vga.vram_ptr, false); + ppm_save(filename, ds, errp); + g_free(ds); + } +diff --git a/hw/xenfb.c b/hw/xenfb.c +index 903efd3..7f1f6b4 100644 +--- a/hw/xenfb.c ++++ b/hw/xenfb.c +@@ -756,7 +756,8 @@ static void xenfb_update(void *opaque) + qemu_free_displaysurface(xenfb->c.ds); + xenfb->c.ds->surface = qemu_create_displaysurface_from + (xenfb->width, xenfb->height, xenfb->depth, +- xenfb->row_stride, xenfb->pixels + xenfb->offset); ++ xenfb->row_stride, xenfb->pixels + xenfb->offset, ++ false); + break; + default: + /* we must convert stuff */ +diff --git a/include/ui/console.h b/include/ui/console.h +index fc23baa..18012f1 100644 +--- a/include/ui/console.h ++++ b/include/ui/console.h +@@ -184,7 +184,8 @@ struct DisplayState { + void register_displaystate(DisplayState *ds); + DisplayState *get_displaystate(void); + DisplaySurface* qemu_create_displaysurface_from(int width, int height, int bpp, +- int linesize, uint8_t *data); ++ int linesize, uint8_t *data, ++ bool byteswap); + PixelFormat qemu_different_endianness_pixelformat(int bpp); + PixelFormat qemu_default_pixelformat(int bpp); + +diff --git a/ui/console.c b/ui/console.c +index 0a68836..25e06a5 100644 +--- a/ui/console.c ++++ b/ui/console.c +@@ -1339,11 +1339,16 @@ DisplaySurface *qemu_resize_displaysurface(DisplayState *ds, + } + + DisplaySurface *qemu_create_displaysurface_from(int width, int height, int bpp, +- int linesize, uint8_t *data) ++ int linesize, uint8_t *data, ++ bool byteswap) + { + DisplaySurface *surface = g_new0(DisplaySurface, 1); + +- surface->pf = qemu_default_pixelformat(bpp); ++ if (byteswap) { ++ surface->pf = qemu_different_endianness_pixelformat(bpp); ++ } else { ++ surface->pf = qemu_default_pixelformat(bpp); ++ } + + surface->format = qemu_pixman_get_format(&surface->pf); + assert(surface->format != 0); +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0009-qmp-netdev_add-is-like-netdev-not-net-fix-documentat.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0009-qmp-netdev_add-is-like-netdev-not-net-fix-documentat.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0009-qmp-netdev_add-is-like-netdev-not-net-fix-documentat.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0009-qmp-netdev_add-is-like-netdev-not-net-fix-documentat.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,33 @@ +From b7ff1a7a00bc91f9e771ca6033be0be19cc5723e Mon Sep 17 00:00:00 2001 +From: Markus Armbruster +Date: Fri, 22 Feb 2013 18:31:51 +0100 +Subject: [PATCH 09/54] qmp: netdev_add is like -netdev, not -net, fix + documentation + +Cc: qemu-stable@nongnu.org +Signed-off-by: Markus Armbruster +Reviewed-by: Laszlo Ersek +Signed-off-by: Stefan Hajnoczi +(cherry picked from commit af347aa5a521555f5342e67993eb717d4f542ba8) + +Signed-off-by: Michael Roth +--- + qmp-commands.hx | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/qmp-commands.hx b/qmp-commands.hx +index 799adea..95022e2 100644 +--- a/qmp-commands.hx ++++ b/qmp-commands.hx +@@ -822,7 +822,7 @@ Example: + -> { "execute": "netdev_add", "arguments": { "type": "user", "id": "netdev1" } } + <- { "return": {} } + +-Note: The supported device options are the same ones supported by the '-net' ++Note: The supported device options are the same ones supported by the '-netdev' + command-line argument, which are listed in the '-help' output or QEMU's + manual + +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0010-qemu-ga-make-guest-sync-delimited-available-during-f.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0010-qemu-ga-make-guest-sync-delimited-available-during-f.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0010-qemu-ga-make-guest-sync-delimited-available-during-f.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0010-qemu-ga-make-guest-sync-delimited-available-during-f.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,39 @@ +From 4a389443262b62ecfd916aea3efc09a502762cd9 Mon Sep 17 00:00:00 2001 +From: Michael Roth +Date: Fri, 1 Mar 2013 11:49:38 -0600 +Subject: [PATCH 10/54] qemu-ga: make guest-sync-delimited available during + fsfreeze + +We currently maintain a whitelist of commands that are safe during +fsfreeze. During fsfreeze, we disable all commands that aren't part of +that whitelist. + +guest-sync-delimited meets the criteria for being whitelisted, and is +also required for qemu-ga clients that rely on guest-sync-delimited for +re-syncing the channel after a timeout. + +Signed-off-by: Michael Roth +Cc: qemu-stable@nongnu.org +Reviewed-by: Eric Blake +(cherry picked from commit c5dcb6ae23a3ed7a01bae1cd75ce02abea31db5e) + +Signed-off-by: Michael Roth +--- + qga/main.c | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/qga/main.c b/qga/main.c +index db281a5..ad75171 100644 +--- a/qga/main.c ++++ b/qga/main.c +@@ -85,6 +85,7 @@ static const char *ga_freeze_whitelist[] = { + "guest-ping", + "guest-info", + "guest-sync", ++ "guest-sync-delimited", + "guest-fsfreeze-status", + "guest-fsfreeze-thaw", + NULL +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0011-scsi-disk-handle-io_canceled-uniformly-and-correctly.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0011-scsi-disk-handle-io_canceled-uniformly-and-correctly.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0011-scsi-disk-handle-io_canceled-uniformly-and-correctly.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0011-scsi-disk-handle-io_canceled-uniformly-and-correctly.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,115 @@ +From a8b090ef08872dad68acb2afbb0f81c44c4132e6 Mon Sep 17 00:00:00 2001 +From: Paolo Bonzini +Date: Mon, 25 Feb 2013 12:16:05 +0100 +Subject: [PATCH 11/54] scsi-disk: handle io_canceled uniformly and correctly + +Always check it immediately after calling bdrv_acct_done, and +always do a "goto done" in case the "done" label has to free +some memory---as is the case for scsi_unmap_complete in the +previous patch. + +This patch could fix problems that happen when a request is +split into multiple parts, and one of them is canceled. Then +the next part is fired, but the HBA's cancellation callbacks have +fired already. Whether this happens or not, depends on how the +block/ driver implements AIO cancellation. It it does a simple +bdrv_drain_all() or similar, then it will not have a problem. +If it only cancels the given AIOCB, this scenario could happen. + +Cc: qemu-stable@nongnu.org +Signed-off-by: Paolo Bonzini +(cherry picked from commit 0c92e0e6b64c9061f7365a2712b9055ea35b52f9) + +Signed-off-by: Michael Roth +--- + hw/scsi-disk.c | 25 +++++++++++++++++++++---- + 1 file changed, 21 insertions(+), 4 deletions(-) + +diff --git a/hw/scsi-disk.c b/hw/scsi-disk.c +index 28e75bb..6bc739d 100644 +--- a/hw/scsi-disk.c ++++ b/hw/scsi-disk.c +@@ -176,6 +176,9 @@ static void scsi_aio_complete(void *opaque, int ret) + assert(r->req.aiocb != NULL); + r->req.aiocb = NULL; + bdrv_acct_done(s->qdev.conf.bs, &r->acct); ++ if (r->req.io_canceled) { ++ goto done; ++ } + + if (ret < 0) { + if (scsi_handle_rw_error(r, -ret)) { +@@ -221,6 +224,10 @@ static void scsi_write_do_fua(SCSIDiskReq *r) + { + SCSIDiskState *s = DO_UPCAST(SCSIDiskState, qdev, r->req.dev); + ++ if (r->req.io_canceled) { ++ goto done; ++ } ++ + if (scsi_is_cmd_fua(&r->req.cmd)) { + bdrv_acct_start(s->qdev.conf.bs, &r->acct, 0, BDRV_ACCT_FLUSH); + r->req.aiocb = bdrv_aio_flush(s->qdev.conf.bs, scsi_aio_complete, r); +@@ -228,6 +235,8 @@ static void scsi_write_do_fua(SCSIDiskReq *r) + } + + scsi_req_complete(&r->req, GOOD); ++ ++done: + if (!r->req.io_canceled) { + scsi_req_unref(&r->req); + } +@@ -241,6 +250,9 @@ static void scsi_dma_complete(void *opaque, int ret) + assert(r->req.aiocb != NULL); + r->req.aiocb = NULL; + bdrv_acct_done(s->qdev.conf.bs, &r->acct); ++ if (r->req.io_canceled) { ++ goto done; ++ } + + if (ret < 0) { + if (scsi_handle_rw_error(r, -ret)) { +@@ -272,6 +284,9 @@ static void scsi_read_complete(void * opaque, int ret) + assert(r->req.aiocb != NULL); + r->req.aiocb = NULL; + bdrv_acct_done(s->qdev.conf.bs, &r->acct); ++ if (r->req.io_canceled) { ++ goto done; ++ } + + if (ret < 0) { + if (scsi_handle_rw_error(r, -ret)) { +@@ -303,6 +318,9 @@ static void scsi_do_read(void *opaque, int ret) + r->req.aiocb = NULL; + bdrv_acct_done(s->qdev.conf.bs, &r->acct); + } ++ if (r->req.io_canceled) { ++ goto done; ++ } + + if (ret < 0) { + if (scsi_handle_rw_error(r, -ret)) { +@@ -310,10 +328,6 @@ static void scsi_do_read(void *opaque, int ret) + } + } + +- if (r->req.io_canceled) { +- return; +- } +- + /* The request is used as the AIO opaque value, so add a ref. */ + scsi_req_ref(&r->req); + +@@ -421,6 +435,9 @@ static void scsi_write_complete(void * opaque, int ret) + r->req.aiocb = NULL; + bdrv_acct_done(s->qdev.conf.bs, &r->acct); + } ++ if (r->req.io_canceled) { ++ goto done; ++ } + + if (ret < 0) { + if (scsi_handle_rw_error(r, -ret)) { +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0012-iscsi-look-for-pkg-config-file-too.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0012-iscsi-look-for-pkg-config-file-too.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0012-iscsi-look-for-pkg-config-file-too.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0012-iscsi-look-for-pkg-config-file-too.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,41 @@ +From 0c918dd600fa6b3c7494b3dad743464242948a7a Mon Sep 17 00:00:00 2001 +From: Paolo Bonzini +Date: Fri, 22 Feb 2013 18:14:28 +0100 +Subject: [PATCH 12/54] iscsi: look for pkg-config file too + +Due to library conflicts, Fedora will have to put libiscsi in +/usr/lib/iscsi. Simplify configuration by using a pkg-config +file. The Fedora package will distribute one, and the patch +to add it has been sent to upstream libiscsi as well. + +Cc: qemu-stable@nongnu.org +Signed-off-by: Paolo Bonzini +(cherry picked from commit 3c33ea9640758bb625e110a77673e5abfd184e54) + +Signed-off-by: Michael Roth +--- + configure | 8 +++++++- + 1 file changed, 7 insertions(+), 1 deletion(-) + +diff --git a/configure b/configure +index 8789324..5fb388a 100755 +--- a/configure ++++ b/configure +@@ -2759,7 +2759,13 @@ if test "$libiscsi" != "no" ; then + #include + int main(void) { iscsi_unmap_sync(NULL,0,0,0,NULL,0); return 0; } + EOF +- if compile_prog "" "-liscsi" ; then ++ if $pkg_config --atleast-version=1.7.0 libiscsi --modversion >/dev/null 2>&1; then ++ libiscsi="yes" ++ libiscsi_cflags=$($pkg_config --cflags libiscsi 2>/dev/null) ++ libiscsi_libs=$($pkg_config --libs libiscsi 2>/dev/null) ++ CFLAGS="$CFLAGS $libiscsi_cflags" ++ LIBS="$LIBS $libiscsi_libs" ++ elif compile_prog "" "-liscsi" ; then + libiscsi="yes" + LIBS="$LIBS -liscsi" + else +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0013-scsi-do-not-call-scsi_read_data-scsi_write_data-for-.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0013-scsi-do-not-call-scsi_read_data-scsi_write_data-for-.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0013-scsi-do-not-call-scsi_read_data-scsi_write_data-for-.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0013-scsi-do-not-call-scsi_read_data-scsi_write_data-for-.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,46 @@ +From f23ab037c7ebd9ffe15526d0d2404194694ebad8 Mon Sep 17 00:00:00 2001 +From: Paolo Bonzini +Date: Mon, 25 Feb 2013 12:12:58 +0100 +Subject: [PATCH 13/54] scsi: do not call scsi_read_data/scsi_write_data for a + canceled request + +Cc: qemu-stable@nongnu.org +Signed-off-by: Paolo Bonzini +(cherry picked from commit 6f6710aa99ac53b59ff0f14380830cb9ab6bdc14) + +Signed-off-by: Michael Roth +--- + hw/scsi-bus.c | 4 ++++ + trace-events | 1 + + 2 files changed, 5 insertions(+) + +diff --git a/hw/scsi-bus.c b/hw/scsi-bus.c +index a97f1cd..01e1dec 100644 +--- a/hw/scsi-bus.c ++++ b/hw/scsi-bus.c +@@ -1508,6 +1508,10 @@ void scsi_req_unref(SCSIRequest *req) + will start the next chunk or complete the command. */ + void scsi_req_continue(SCSIRequest *req) + { ++ if (req->io_canceled) { ++ trace_scsi_req_continue_canceled(req->dev->id, req->lun, req->tag); ++ return; ++ } + trace_scsi_req_continue(req->dev->id, req->lun, req->tag); + if (req->cmd.mode == SCSI_XFER_TO_DEV) { + req->ops->write_data(req); +diff --git a/trace-events b/trace-events +index 1011f27..167f481 100644 +--- a/trace-events ++++ b/trace-events +@@ -460,6 +460,7 @@ scsi_req_data(int target, int lun, int tag, int len) "target %d lun %d tag %d le + scsi_req_data_canceled(int target, int lun, int tag, int len) "target %d lun %d tag %d len %d" + scsi_req_dequeue(int target, int lun, int tag) "target %d lun %d tag %d" + scsi_req_continue(int target, int lun, int tag) "target %d lun %d tag %d" ++scsi_req_continue_canceled(int target, int lun, int tag) "target %d lun %d tag %d" + scsi_req_parsed(int target, int lun, int tag, int cmd, int mode, int xfer) "target %d lun %d tag %d command %d dir %d length %d" + scsi_req_parsed_lba(int target, int lun, int tag, int cmd, uint64_t lba) "target %d lun %d tag %d command %d lba %"PRIu64 + scsi_req_parse_bad(int target, int lun, int tag, int cmd) "target %d lun %d tag %d command %d" +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0014-scsi-disk-do-not-complete-canceled-UNMAP-requests.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0014-scsi-disk-do-not-complete-canceled-UNMAP-requests.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0014-scsi-disk-do-not-complete-canceled-UNMAP-requests.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0014-scsi-disk-do-not-complete-canceled-UNMAP-requests.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,58 @@ +From 99b1f39bd28be0cf8f0505a55a98fa9beda23fa2 Mon Sep 17 00:00:00 2001 +From: Paolo Bonzini +Date: Mon, 25 Feb 2013 12:14:34 +0100 +Subject: [PATCH 14/54] scsi-disk: do not complete canceled UNMAP requests + +Canceled requests should never be completed, and doing that could cause +accesses to a NULL hba_private field. + +Cc: qemu-stable@nongnu.org +Reported-by: Stefan Priebe +Tested-by: Stefan Priebe +Signed-off-by: Paolo Bonzini +(cherry picked from commit d0242eadc5bba4f3abe34bc5d536bbfb81aa9891) + +Signed-off-by: Michael Roth +--- + hw/scsi-disk.c | 11 +++++++---- + 1 file changed, 7 insertions(+), 4 deletions(-) + +diff --git a/hw/scsi-disk.c b/hw/scsi-disk.c +index 6bc739d..c9c983a 100644 +--- a/hw/scsi-disk.c ++++ b/hw/scsi-disk.c +@@ -1493,13 +1493,17 @@ static void scsi_unmap_complete(void *opaque, int ret) + uint32_t nb_sectors; + + r->req.aiocb = NULL; ++ if (r->req.io_canceled) { ++ goto done; ++ } ++ + if (ret < 0) { + if (scsi_handle_rw_error(r, -ret)) { + goto done; + } + } + +- if (data->count > 0 && !r->req.io_canceled) { ++ if (data->count > 0) { + sector_num = ldq_be_p(&data->inbuf[0]); + nb_sectors = ldl_be_p(&data->inbuf[8]) & 0xffffffffULL; + if (!check_lba_range(s, sector_num, nb_sectors)) { +@@ -1516,10 +1520,9 @@ static void scsi_unmap_complete(void *opaque, int ret) + return; + } + ++ scsi_req_complete(&r->req, GOOD); ++ + done: +- if (data->count == 0) { +- scsi_req_complete(&r->req, GOOD); +- } + if (!r->req.io_canceled) { + scsi_req_unref(&r->req); + } +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0015-rtc-test-Fix-test-failures-with-recent-glib.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0015-rtc-test-Fix-test-failures-with-recent-glib.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0015-rtc-test-Fix-test-failures-with-recent-glib.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0015-rtc-test-Fix-test-failures-with-recent-glib.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,40 @@ +From c3b81e01b894f03b03db99804da89068064b3ad8 Mon Sep 17 00:00:00 2001 +From: Cole Robinson +Date: Tue, 26 Feb 2013 19:31:32 -0500 +Subject: [PATCH 15/54] rtc-test: Fix test failures with recent glib + +As of glib 2.35.4, glib changed its logic for ordering test cases: + +https://bugzilla.gnome.org/show_bug.cgi?id=694487 + +This was causing failures in rtc-test. Group the reordered test +cases into their own suite, which maintains the original ordering. + +CC: qemu-stable@nongnu.org +Signed-off-by: Cole Robinson +Signed-off-by: Stefan Hajnoczi +(cherry picked from commit eeb29fb9aa733f97d85857c210d6580a92a1b532) + +Signed-off-by: Michael Roth +--- + tests/rtc-test.c | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/tests/rtc-test.c b/tests/rtc-test.c +index 203c0fc..2441dcf 100644 +--- a/tests/rtc-test.c ++++ b/tests/rtc-test.c +@@ -387,8 +387,8 @@ int main(int argc, char **argv) + qtest_add_func("/rtc/alarm-time", alarm_time); + qtest_add_func("/rtc/set-year/20xx", set_year_20xx); + qtest_add_func("/rtc/set-year/1980", set_year_1980); +- qtest_add_func("/rtc/register_b_set_flag", register_b_set_flag); +- qtest_add_func("/rtc/fuzz-registers", fuzz_registers); ++ qtest_add_func("/rtc/misc/register_b_set_flag", register_b_set_flag); ++ qtest_add_func("/rtc/misc/fuzz-registers", fuzz_registers); + ret = g_test_run(); + + if (s) { +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0016-Allow-virtio-net-features-for-legacy-s390-virtio-bus.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0016-Allow-virtio-net-features-for-legacy-s390-virtio-bus.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0016-Allow-virtio-net-features-for-legacy-s390-virtio-bus.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0016-Allow-virtio-net-features-for-legacy-s390-virtio-bus.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,33 @@ +From 4d1cdb9efd76faf0f6dc0f5aa137842cf16d9ee6 Mon Sep 17 00:00:00 2001 +From: Christian Borntraeger +Date: Thu, 7 Mar 2013 17:21:41 +0100 +Subject: [PATCH 16/54] Allow virtio-net features for legacy s390 virtio bus + +Enable all virtio-net features for the legacy s390 virtio bus. This also fixes +kernel BUG at /usr/src/packages/BUILD/kernel-default-3.0.58/linux-3.0/drivers/s390/kvm/kvm_virtio.c:121! + +Signed-off-by: Christian Borntraeger +Cc: qemu-stable@nongnu.org +Signed-off-by: Alexander Graf +(cherry picked from commit 35569cea79fd3f5ccb5b23ca024c7d3aa4d24e75) + +Signed-off-by: Michael Roth +--- + hw/s390x/s390-virtio-bus.c | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/hw/s390x/s390-virtio-bus.c b/hw/s390x/s390-virtio-bus.c +index 089ed92..d9b7f83 100644 +--- a/hw/s390x/s390-virtio-bus.c ++++ b/hw/s390x/s390-virtio-bus.c +@@ -402,6 +402,7 @@ static const VirtIOBindings virtio_s390_bindings = { + + static Property s390_virtio_net_properties[] = { + DEFINE_NIC_PROPERTIES(VirtIOS390Device, nic), ++ DEFINE_VIRTIO_NET_FEATURES(VirtIOS390Device, host_features), + DEFINE_PROP_UINT32("x-txtimer", VirtIOS390Device, + net.txtimer, TX_TIMER_INTERVAL), + DEFINE_PROP_INT32("x-txburst", VirtIOS390Device, +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0017-pseries-Add-compatible-property-to-root-of-device-tr.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0017-pseries-Add-compatible-property-to-root-of-device-tr.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0017-pseries-Add-compatible-property-to-root-of-device-tr.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0017-pseries-Add-compatible-property-to-root-of-device-tr.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,40 @@ +From 51943504d5104474d3ec9983a1175c53762877de Mon Sep 17 00:00:00 2001 +From: David Gibson +Date: Mon, 25 Feb 2013 19:27:12 +0000 +Subject: [PATCH 17/54] pseries: Add compatible property to root of device tree + +Currently, for the pseries machine the device tree supplied by qemu to SLOF +and from there to the guest does not include a 'compatible property' at the +root level. Usually that works fine, since in this case the compatible +property doesn't really give any information not already found in the +'device_type' or 'model' properties. + +However, the lack of 'compatible' confuses the bootloader install in the +SLES11 SP2 and SLES11 SP3 installers. This patch therefore adds a token +'compatible' property to work around that. + +Signed-off-by: David Gibson +Cc: qemu-stable@nongnu.org +Signed-off-by: Alexander Graf +(cherry picked from commit d63919c93e6fb0587632adafba82c21e55ea4396) + +Signed-off-by: Michael Roth +--- + hw/spapr.c | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/hw/spapr.c b/hw/spapr.c +index e88a27a..fadf70f 100644 +--- a/hw/spapr.c ++++ b/hw/spapr.c +@@ -260,6 +260,7 @@ static void *spapr_create_fdt_skel(const char *cpu_model, + _FDT((fdt_begin_node(fdt, ""))); + _FDT((fdt_property_string(fdt, "device_type", "chrp"))); + _FDT((fdt_property_string(fdt, "model", "IBM pSeries (emulated by qemu)"))); ++ _FDT((fdt_property_string(fdt, "compatible", "qemu,pseries"))); + + _FDT((fdt_property_cell(fdt, "#address-cells", 0x2))); + _FDT((fdt_property_cell(fdt, "#size-cells", 0x2))); +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0018-qcow2-make-is_allocated-return-true-for-zero-cluster.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0018-qcow2-make-is_allocated-return-true-for-zero-cluster.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0018-qcow2-make-is_allocated-return-true-for-zero-cluster.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0018-qcow2-make-is_allocated-return-true-for-zero-cluster.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,64 @@ +From d3652a1b286063f02425adc18515804272ebef18 Mon Sep 17 00:00:00 2001 +From: Paolo Bonzini +Date: Wed, 6 Mar 2013 18:02:01 +0100 +Subject: [PATCH 18/54] qcow2: make is_allocated return true for zero clusters + +Otherwise, live migration of the top layer will miss zero clusters and +let the backing file show through. This also matches what is done in qed. + +QCOW2_CLUSTER_ZERO clusters are invalid in v2 image files. Check this +directly in qcow2_get_cluster_offset instead of replicating the test +everywhere. + +Cc: qemu-stable@nongnu.org +Signed-off-by: Paolo Bonzini +Signed-off-by: Stefan Hajnoczi +(cherry picked from commit 381b487d54ba18c73df9db8452028a330058c505) + +Signed-off-by: Michael Roth +--- + block/qcow2-cluster.c | 3 +++ + block/qcow2.c | 6 +----- + 2 files changed, 4 insertions(+), 5 deletions(-) + +diff --git a/block/qcow2-cluster.c b/block/qcow2-cluster.c +index 56fccf9..bb04432 100644 +--- a/block/qcow2-cluster.c ++++ b/block/qcow2-cluster.c +@@ -454,6 +454,9 @@ int qcow2_get_cluster_offset(BlockDriverState *bs, uint64_t offset, + *cluster_offset &= L2E_COMPRESSED_OFFSET_SIZE_MASK; + break; + case QCOW2_CLUSTER_ZERO: ++ if (s->qcow_version < 3) { ++ return -EIO; ++ } + c = count_contiguous_clusters(nb_clusters, s->cluster_size, + &l2_table[l2_index], 0, + QCOW_OFLAG_COMPRESSED | QCOW_OFLAG_ZERO); +diff --git a/block/qcow2.c b/block/qcow2.c +index 7610e56..b4c7c54 100644 +--- a/block/qcow2.c ++++ b/block/qcow2.c +@@ -584,7 +584,7 @@ static int coroutine_fn qcow2_co_is_allocated(BlockDriverState *bs, + *pnum = 0; + } + +- return (cluster_offset != 0); ++ return (cluster_offset != 0) || (ret == QCOW2_CLUSTER_ZERO); + } + + /* handle reading after the end of the backing file */ +@@ -665,10 +665,6 @@ static coroutine_fn int qcow2_co_readv(BlockDriverState *bs, int64_t sector_num, + break; + + case QCOW2_CLUSTER_ZERO: +- if (s->qcow_version < 3) { +- ret = -EIO; +- goto fail; +- } + qemu_iovec_memset(&hd_qiov, 0, 0, 512 * cur_nr_sectors); + break; + +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0019-qemu-ga-use-key-value-store-to-avoid-recycling-fd-ha.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0019-qemu-ga-use-key-value-store-to-avoid-recycling-fd-ha.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0019-qemu-ga-use-key-value-store-to-avoid-recycling-fd-ha.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0019-qemu-ga-use-key-value-store-to-avoid-recycling-fd-ha.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,352 @@ +From f305d504ab1114c578a64c90e17885129eb8d0aa Mon Sep 17 00:00:00 2001 +From: Michael Roth +Date: Fri, 1 Mar 2013 11:40:27 -0600 +Subject: [PATCH 19/54] qemu-ga: use key-value store to avoid recycling fd + handles after restart + +Hosts hold on to handles provided by guest-file-open for periods that can +span beyond the life of the qemu-ga process that issued them. Since these +are issued starting from 0 on every restart, we run the risk of issuing +duplicate handles after restarts/reboots. + +As a result, users with a stale copy of these handles may end up +reading/writing corrupted data due to their existing handles effectively +being re-assigned to an unexpected file or offset. + +We unfortunately do not issue handles as strings, but as integers, so a +solution such as using UUIDs can't be implemented without introducing a +new interface. + +As a workaround, we fix this by implementing a persistent key-value store +that will be used to track the value of the last handle that was issued +across restarts/reboots to avoid issuing duplicates. + +The store is automatically written to the same directory we currently +set via --statedir to track fsfreeze state, and so should be applicable +for stable releases where this flag is supported. + +A follow-up can use this same store for handling fsfreeze state, but +that change is cosmetic and left out for now. + +Signed-off-by: Michael Roth +Cc: qemu-stable@nongnu.org + +* fixed guest_file_handle_add() return value from uint64_t to int64_t +(cherry picked from commit 39097daf15c42243742667607d2cad2c9dc4f764) + +Signed-off-by: Michael Roth +--- + qga/commands-posix.c | 25 +++++-- + qga/guest-agent-core.h | 1 + + qga/main.c | 184 +++++++++++++++++++++++++++++++++++++++++++++++++ + 3 files changed, 204 insertions(+), 6 deletions(-) + +diff --git a/qga/commands-posix.c b/qga/commands-posix.c +index 7a0202e..1c2aff3 100644 +--- a/qga/commands-posix.c ++++ b/qga/commands-posix.c +@@ -129,14 +129,22 @@ static struct { + QTAILQ_HEAD(, GuestFileHandle) filehandles; + } guest_file_state; + +-static void guest_file_handle_add(FILE *fh) ++static int64_t guest_file_handle_add(FILE *fh, Error **errp) + { + GuestFileHandle *gfh; ++ int64_t handle; ++ ++ handle = ga_get_fd_handle(ga_state, errp); ++ if (error_is_set(errp)) { ++ return 0; ++ } + + gfh = g_malloc0(sizeof(GuestFileHandle)); +- gfh->id = fileno(fh); ++ gfh->id = handle; + gfh->fh = fh; + QTAILQ_INSERT_TAIL(&guest_file_state.filehandles, gfh, next); ++ ++ return handle; + } + + static GuestFileHandle *guest_file_handle_find(int64_t id, Error **err) +@@ -158,7 +166,7 @@ int64_t qmp_guest_file_open(const char *path, bool has_mode, const char *mode, E + { + FILE *fh; + int fd; +- int64_t ret = -1; ++ int64_t ret = -1, handle; + + if (!has_mode) { + mode = "r"; +@@ -184,9 +192,14 @@ int64_t qmp_guest_file_open(const char *path, bool has_mode, const char *mode, E + return -1; + } + +- guest_file_handle_add(fh); +- slog("guest-file-open, handle: %d", fd); +- return fd; ++ handle = guest_file_handle_add(fh, err); ++ if (error_is_set(err)) { ++ fclose(fh); ++ return -1; ++ } ++ ++ slog("guest-file-open, handle: %d", handle); ++ return handle; + } + + void qmp_guest_file_close(int64_t handle, Error **err) +diff --git a/qga/guest-agent-core.h b/qga/guest-agent-core.h +index 3354598..624a559 100644 +--- a/qga/guest-agent-core.h ++++ b/qga/guest-agent-core.h +@@ -35,6 +35,7 @@ bool ga_is_frozen(GAState *s); + void ga_set_frozen(GAState *s); + void ga_unset_frozen(GAState *s); + const char *ga_fsfreeze_hook(GAState *s); ++int64_t ga_get_fd_handle(GAState *s, Error **errp); + + #ifndef _WIN32 + void reopen_fd_to_null(int fd); +diff --git a/qga/main.c b/qga/main.c +index ad75171..99346e1 100644 +--- a/qga/main.c ++++ b/qga/main.c +@@ -15,6 +15,7 @@ + #include + #include + #include ++#include + #ifndef _WIN32 + #include + #include +@@ -30,6 +31,7 @@ + #include "qapi/qmp/qerror.h" + #include "qapi/qmp/dispatch.h" + #include "qga/channel.h" ++#include "qemu/bswap.h" + #ifdef _WIN32 + #include "qga/service-win32.h" + #include +@@ -53,6 +55,11 @@ + #endif + #define QGA_SENTINEL_BYTE 0xFF + ++typedef struct GAPersistentState { ++#define QGA_PSTATE_DEFAULT_FD_COUNTER 1000 ++ int64_t fd_counter; ++} GAPersistentState; ++ + struct GAState { + JSONMessageParser parser; + GMainLoop *main_loop; +@@ -76,6 +83,8 @@ struct GAState { + #ifdef CONFIG_FSFREEZE + const char *fsfreeze_hook; + #endif ++ const gchar *pstate_filepath; ++ GAPersistentState pstate; + }; + + struct GAState *ga_state; +@@ -725,6 +734,171 @@ VOID WINAPI service_main(DWORD argc, TCHAR *argv[]) + } + #endif + ++static void set_persistent_state_defaults(GAPersistentState *pstate) ++{ ++ g_assert(pstate); ++ pstate->fd_counter = QGA_PSTATE_DEFAULT_FD_COUNTER; ++} ++ ++static void persistent_state_from_keyfile(GAPersistentState *pstate, ++ GKeyFile *keyfile) ++{ ++ g_assert(pstate); ++ g_assert(keyfile); ++ /* if any fields are missing, either because the file was tampered with ++ * by agents of chaos, or because the field wasn't present at the time the ++ * file was created, the best we can ever do is start over with the default ++ * values. so load them now, and ignore any errors in accessing key-value ++ * pairs ++ */ ++ set_persistent_state_defaults(pstate); ++ ++ if (g_key_file_has_key(keyfile, "global", "fd_counter", NULL)) { ++ pstate->fd_counter = ++ g_key_file_get_int64(keyfile, "global", "fd_counter", NULL); ++ } ++} ++ ++static void persistent_state_to_keyfile(const GAPersistentState *pstate, ++ GKeyFile *keyfile) ++{ ++ g_assert(pstate); ++ g_assert(keyfile); ++ ++ g_key_file_set_int64(keyfile, "global", "fd_counter", pstate->fd_counter); ++} ++ ++static gboolean write_persistent_state(const GAPersistentState *pstate, ++ const gchar *path) ++{ ++ GKeyFile *keyfile = g_key_file_new(); ++ GError *gerr = NULL; ++ gboolean ret = true; ++ gchar *data = NULL; ++ gsize data_len; ++ ++ g_assert(pstate); ++ ++ persistent_state_to_keyfile(pstate, keyfile); ++ data = g_key_file_to_data(keyfile, &data_len, &gerr); ++ if (gerr) { ++ g_critical("failed to convert persistent state to string: %s", ++ gerr->message); ++ ret = false; ++ goto out; ++ } ++ ++ g_file_set_contents(path, data, data_len, &gerr); ++ if (gerr) { ++ g_critical("failed to write persistent state to %s: %s", ++ path, gerr->message); ++ ret = false; ++ goto out; ++ } ++ ++out: ++ if (gerr) { ++ g_error_free(gerr); ++ } ++ if (keyfile) { ++ g_key_file_free(keyfile); ++ } ++ g_free(data); ++ return ret; ++} ++ ++static gboolean read_persistent_state(GAPersistentState *pstate, ++ const gchar *path, gboolean frozen) ++{ ++ GKeyFile *keyfile = NULL; ++ GError *gerr = NULL; ++ struct stat st; ++ gboolean ret = true; ++ ++ g_assert(pstate); ++ ++ if (stat(path, &st) == -1) { ++ /* it's okay if state file doesn't exist, but any other error ++ * indicates a permissions issue or some other misconfiguration ++ * that we likely won't be able to recover from. ++ */ ++ if (errno != ENOENT) { ++ g_critical("unable to access state file at path %s: %s", ++ path, strerror(errno)); ++ ret = false; ++ goto out; ++ } ++ ++ /* file doesn't exist. initialize state to default values and ++ * attempt to save now. (we could wait till later when we have ++ * modified state we need to commit, but if there's a problem, ++ * such as a missing parent directory, we want to catch it now) ++ * ++ * there is a potential scenario where someone either managed to ++ * update the agent from a version that didn't use a key store ++ * while qemu-ga thought the filesystem was frozen, or ++ * deleted the key store prior to issuing a fsfreeze, prior ++ * to restarting the agent. in this case we go ahead and defer ++ * initial creation till we actually have modified state to ++ * write, otherwise fail to recover from freeze. ++ */ ++ set_persistent_state_defaults(pstate); ++ if (!frozen) { ++ ret = write_persistent_state(pstate, path); ++ if (!ret) { ++ g_critical("unable to create state file at path %s", path); ++ ret = false; ++ goto out; ++ } ++ } ++ ret = true; ++ goto out; ++ } ++ ++ keyfile = g_key_file_new(); ++ g_key_file_load_from_file(keyfile, path, 0, &gerr); ++ if (gerr) { ++ g_critical("error loading persistent state from path: %s, %s", ++ path, gerr->message); ++ ret = false; ++ goto out; ++ } ++ ++ persistent_state_from_keyfile(pstate, keyfile); ++ ++out: ++ if (keyfile) { ++ g_key_file_free(keyfile); ++ } ++ if (gerr) { ++ g_error_free(gerr); ++ } ++ ++ return ret; ++} ++ ++int64_t ga_get_fd_handle(GAState *s, Error **errp) ++{ ++ int64_t handle; ++ ++ g_assert(s->pstate_filepath); ++ /* we blacklist commands and avoid operations that potentially require ++ * writing to disk when we're in a frozen state. this includes opening ++ * new files, so we should never get here in that situation ++ */ ++ g_assert(!ga_is_frozen(s)); ++ ++ handle = s->pstate.fd_counter++; ++ if (s->pstate.fd_counter < 0) { ++ s->pstate.fd_counter = 0; ++ } ++ if (!write_persistent_state(&s->pstate, s->pstate_filepath)) { ++ error_setg(errp, "failed to commit persistent state to disk"); ++ } ++ ++ return handle; ++} ++ + int main(int argc, char **argv) + { + const char *sopt = "hVvdm:p:l:f:F::b:s:t:"; +@@ -854,7 +1028,9 @@ int main(int argc, char **argv) + ga_enable_logging(s); + s->state_filepath_isfrozen = g_strdup_printf("%s/qga.state.isfrozen", + state_dir); ++ s->pstate_filepath = g_strdup_printf("%s/qga.state", state_dir); + s->frozen = false; ++ + #ifndef _WIN32 + /* check if a previous instance of qemu-ga exited with filesystems' state + * marked as frozen. this could be a stale value (a non-qemu-ga process +@@ -911,6 +1087,14 @@ int main(int argc, char **argv) + } + } + ++ /* load persistent state from disk */ ++ if (!read_persistent_state(&s->pstate, ++ s->pstate_filepath, ++ ga_is_frozen(s))) { ++ g_critical("failed to load persistent state"); ++ goto out_bad; ++ } ++ + if (blacklist) { + s->blacklist = blacklist; + do { +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0020-qga-main.c-Don-t-use-g_key_file_get-set_int64.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0020-qga-main.c-Don-t-use-g_key_file_get-set_int64.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0020-qga-main.c-Don-t-use-g_key_file_get-set_int64.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0020-qga-main.c-Don-t-use-g_key_file_get-set_int64.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,49 @@ +From d26efd2d39b879fd5ff4cee9676ba03391101d67 Mon Sep 17 00:00:00 2001 +From: Peter Crosthwaite +Date: Fri, 15 Mar 2013 15:04:39 +1000 +Subject: [PATCH 20/54] qga/main.c: Don't use g_key_file_get/set_int64 + +These functions don't exist until glib version 2.26. QEMU is currently only +mandating glib 2.12. + +This patch replaces the functions with g_key_file_get/set_integer. + +Unbreaks the build on Ubuntu 10.04 and RHEL 5.6. + +Regression was introduced by 39097daf15c42243742667607d2cad2c9dc4f764 + +Signed-off-by: Peter Crosthwaite +Message-id: 1363323879-682-1-git-send-email-peter.crosthwaite@xilinx.com +Signed-off-by: Anthony Liguori +(cherry picked from commit 4f306496183d81aed4b43762cf3bfd6e054de767) + +Signed-off-by: Michael Roth +--- + qga/main.c | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/qga/main.c b/qga/main.c +index 99346e1..74ef788 100644 +--- a/qga/main.c ++++ b/qga/main.c +@@ -755,7 +755,7 @@ static void persistent_state_from_keyfile(GAPersistentState *pstate, + + if (g_key_file_has_key(keyfile, "global", "fd_counter", NULL)) { + pstate->fd_counter = +- g_key_file_get_int64(keyfile, "global", "fd_counter", NULL); ++ g_key_file_get_integer(keyfile, "global", "fd_counter", NULL); + } + } + +@@ -765,7 +765,7 @@ static void persistent_state_to_keyfile(const GAPersistentState *pstate, + g_assert(pstate); + g_assert(keyfile); + +- g_key_file_set_int64(keyfile, "global", "fd_counter", pstate->fd_counter); ++ g_key_file_set_integer(keyfile, "global", "fd_counter", pstate->fd_counter); + } + + static gboolean write_persistent_state(const GAPersistentState *pstate, +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0021-tcg-Fix-occasional-TCG-broken-problem-when-ldst-opti.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0021-tcg-Fix-occasional-TCG-broken-problem-when-ldst-opti.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0021-tcg-Fix-occasional-TCG-broken-problem-when-ldst-opti.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0021-tcg-Fix-occasional-TCG-broken-problem-when-ldst-opti.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,49 @@ +From b0da310a69a4516dd49597e73b812747d8da05e9 Mon Sep 17 00:00:00 2001 +From: Yeongkyoon Lee +Date: Fri, 22 Mar 2013 21:50:17 +0900 +Subject: [PATCH 21/54] tcg: Fix occasional TCG broken problem when ldst + optimization enabled + +is_tcg_gen_code() checks the upper limit of TCG generated code range wrong, so +that TCG could get broken occasionally only when CONFIG_QEMU_LDST_OPTIMIZATION +enabled. The reason is code_gen_buffer_max_size does not cover the upper range +up to (TCG_MAX_OP_SIZE * OPC_BUF_SIZE), thus code_gen_buffer_max_size should be +modified to code_gen_buffer_size. + +CC: qemu-stable@nongnu.org +Signed-off-by: Yeongkyoon Lee +Reviewed-by: Peter Maydell +Signed-off-by: Aurelien Jarno +(cherry picked from commit 52ae646d4a3ebdcdcc973492c6a56f2c49b6578f) + +Conflicts: + + translate-all.c + +*modified to use non-tcg-ctx version of code_gen_* variables + +Signed-off-by: Michael Roth +--- + translate-all.c | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/translate-all.c b/translate-all.c +index d367fc4..bf1db09 100644 +--- a/translate-all.c ++++ b/translate-all.c +@@ -1310,10 +1310,10 @@ static void tb_link_page(TranslationBlock *tb, tb_page_addr_t phys_pc, + /* check whether the given addr is in TCG generated code buffer or not */ + bool is_tcg_gen_code(uintptr_t tc_ptr) + { +- /* This can be called during code generation, code_gen_buffer_max_size ++ /* This can be called during code generation, code_gen_buffer_size + is used instead of code_gen_ptr for upper boundary checking */ + return (tc_ptr >= (uintptr_t)code_gen_buffer && +- tc_ptr < (uintptr_t)(code_gen_buffer + code_gen_buffer_max_size)); ++ tc_ptr < (uintptr_t)(code_gen_buffer + code_gen_buffer_size)); + } + #endif + +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0022-virtio-ccw-Queue-sanity-check-for-notify-hypercall.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0022-virtio-ccw-Queue-sanity-check-for-notify-hypercall.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0022-virtio-ccw-Queue-sanity-check-for-notify-hypercall.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0022-virtio-ccw-Queue-sanity-check-for-notify-hypercall.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,35 @@ +From 3c3de7c6b4cc78bf312e45402c60ce2a8e8a39ed Mon Sep 17 00:00:00 2001 +From: Cornelia Huck +Date: Tue, 26 Mar 2013 17:32:44 +0100 +Subject: [PATCH 22/54] virtio-ccw: Queue sanity check for notify hypercall. + +Verify that the virtio-ccw notify hypercall passed a reasonable +value for queue. + +Cc: qemu-stable@nongnu.org +Reported-by: Alexander Graf +Signed-off-by: Cornelia Huck +(cherry picked from commit b57ed9bf075e33cdd2f9eb545ff555301dd57221) + +Signed-off-by: Michael Roth +--- + hw/s390x/s390-virtio-ccw.c | 3 +++ + 1 file changed, 3 insertions(+) + +diff --git a/hw/s390x/s390-virtio-ccw.c b/hw/s390x/s390-virtio-ccw.c +index 6549211..f90b5e4 100644 +--- a/hw/s390x/s390-virtio-ccw.c ++++ b/hw/s390x/s390-virtio-ccw.c +@@ -31,6 +31,9 @@ static int virtio_ccw_hcall_notify(const uint64_t *args) + if (!sch || !css_subch_visible(sch)) { + return -EINVAL; + } ++ if (queue >= VIRTIO_PCI_QUEUE_MAX) { ++ return -EINVAL; ++ } + virtio_queue_notify(virtio_ccw_get_vdev(sch), queue); + return 0; + +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0023-qemu-bridge-helper-force-usage-of-a-very-high-MAC-ad.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0023-qemu-bridge-helper-force-usage-of-a-very-high-MAC-ad.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0023-qemu-bridge-helper-force-usage-of-a-very-high-MAC-ad.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0023-qemu-bridge-helper-force-usage-of-a-very-high-MAC-ad.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,56 @@ +From 43e00611bcf40cde483b2d44374ae0ff15eed346 Mon Sep 17 00:00:00 2001 +From: Paolo Bonzini +Date: Fri, 22 Mar 2013 17:57:48 +0100 +Subject: [PATCH 23/54] qemu-bridge-helper: force usage of a very high MAC + address for the bridge + +Linux uses the lowest enslaved MAC address as the MAC address of +the bridge. Set MAC address to a high value so that it does not +affect the MAC address of the bridge. + +Changing the MAC address of the bridge could cause a few seconds +of network downtime. + +Cc: qemu-stable@nongnu.org +Signed-off-by: Paolo Bonzini +Message-id: 1363971468-21154-1-git-send-email-pbonzini@redhat.com +Signed-off-by: Anthony Liguori +(cherry picked from commit 226ecabfbd410c7b2041385ea4b6f083a09ce8a2) + +Signed-off-by: Michael Roth +--- + qemu-bridge-helper.c | 18 ++++++++++++++++++ + 1 file changed, 18 insertions(+) + +diff --git a/qemu-bridge-helper.c b/qemu-bridge-helper.c +index 287bfd5..6a0974e 100644 +--- a/qemu-bridge-helper.c ++++ b/qemu-bridge-helper.c +@@ -367,6 +367,24 @@ int main(int argc, char **argv) + goto cleanup; + } + ++ /* Linux uses the lowest enslaved MAC address as the MAC address of ++ * the bridge. Set MAC address to a high value so that it doesn't ++ * affect the MAC address of the bridge. ++ */ ++ if (ioctl(ctlfd, SIOCGIFHWADDR, &ifr) < 0) { ++ fprintf(stderr, "failed to get MAC address of device `%s': %s\n", ++ iface, strerror(errno)); ++ ret = EXIT_FAILURE; ++ goto cleanup; ++ } ++ ifr.ifr_hwaddr.sa_data[0] = 0xFE; ++ if (ioctl(ctlfd, SIOCSIFHWADDR, &ifr) < 0) { ++ fprintf(stderr, "failed to set MAC address of device `%s': %s\n", ++ iface, strerror(errno)); ++ ret = EXIT_FAILURE; ++ goto cleanup; ++ } ++ + /* add the interface to the bridge */ + prep_ifreq(&ifr, bridge); + ifindex = if_nametoindex(iface); +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0024-configure-Require-at-least-spice-protocol-0.12.3.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0024-configure-Require-at-least-spice-protocol-0.12.3.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0024-configure-Require-at-least-spice-protocol-0.12.3.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0024-configure-Require-at-least-spice-protocol-0.12.3.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,34 @@ +From 4e4566ce78e8d0668a0b66c90b4bc01b5c88d050 Mon Sep 17 00:00:00 2001 +From: Michal Privoznik +Date: Fri, 1 Mar 2013 08:43:18 +0100 +Subject: [PATCH 24/54] configure: Require at least spice-protocol-0.12.3 + +As of 5a49d3e9 we assume SPICE_PORT_EVENT_BREAK to be defined. +However, it is defined not in 0.12.2 what we require now, but in +0.12.3. Therefore in order to prevent build failure we must +adjust our minimal requirements. + +Signed-off-by: Stefan Hajnoczi +(cherry picked from commit 358689fe299c306f1d81bea57a5067d0abb56699) + +Signed-off-by: Michael Roth +--- + configure | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/configure b/configure +index 5fb388a..e7468a9 100755 +--- a/configure ++++ b/configure +@@ -2833,7 +2833,7 @@ EOF + spice_cflags=$($pkg_config --cflags spice-protocol spice-server 2>/dev/null) + spice_libs=$($pkg_config --libs spice-protocol spice-server 2>/dev/null) + if $pkg_config --atleast-version=0.12.0 spice-server >/dev/null 2>&1 && \ +- $pkg_config --atleast-version=0.12.2 spice-protocol > /dev/null 2>&1 && \ ++ $pkg_config --atleast-version=0.12.3 spice-protocol > /dev/null 2>&1 && \ + compile_prog "$spice_cflags" "$spice_libs" ; then + spice="yes" + libs_softmmu="$libs_softmmu $spice_libs" +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0025-pseries-Add-cleanup-hook-for-PAPR-virtual-LAN-device.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0025-pseries-Add-cleanup-hook-for-PAPR-virtual-LAN-device.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0025-pseries-Add-cleanup-hook-for-PAPR-virtual-LAN-device.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0025-pseries-Add-cleanup-hook-for-PAPR-virtual-LAN-device.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,46 @@ +From 611c7f2c3aba7885fd94a4b267e419f351d37a0f Mon Sep 17 00:00:00 2001 +From: David Gibson +Date: Sun, 10 Feb 2013 18:59:02 +0000 +Subject: [PATCH 25/54] pseries: Add cleanup hook for PAPR virtual LAN device + +Currently the spapr-vlan device does not supply a cleanup call for its +NetClientInfo structure. With current qemu versions, that leads to a SEGV +on exit, when net_cleanup() attempts to call the cleanup handlers on all +net clients. + +Signed-off-by: David Gibson +Signed-off-by: Alexander Graf +(cherry picked from commit 156dfaded87d718a9ea798083e1c3e5ea7526713) + +Signed-off-by: Michael Roth +--- + hw/spapr_llan.c | 8 ++++++++ + 1 file changed, 8 insertions(+) + +diff --git a/hw/spapr_llan.c b/hw/spapr_llan.c +index 6ef2936..0ace2eb 100644 +--- a/hw/spapr_llan.c ++++ b/hw/spapr_llan.c +@@ -175,11 +175,19 @@ static ssize_t spapr_vlan_receive(NetClientState *nc, const uint8_t *buf, + return size; + } + ++static void spapr_vlan_cleanup(NetClientState *nc) ++{ ++ VIOsPAPRVLANDevice *dev = qemu_get_nic_opaque(nc); ++ ++ dev->nic = NULL; ++} ++ + static NetClientInfo net_spapr_vlan_info = { + .type = NET_CLIENT_OPTIONS_KIND_NIC, + .size = sizeof(NICState), + .can_receive = spapr_vlan_can_receive, + .receive = spapr_vlan_receive, ++ .cleanup = spapr_vlan_cleanup, + }; + + static void spapr_vlan_reset(VIOsPAPRDevice *sdev) +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0026-target-ppc-Fix-CPU_POWERPC_MPC8547E.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0026-target-ppc-Fix-CPU_POWERPC_MPC8547E.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0026-target-ppc-Fix-CPU_POWERPC_MPC8547E.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0026-target-ppc-Fix-CPU_POWERPC_MPC8547E.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,38 @@ +From e09b99b54f1c2dac52e16d2666388c5813bb9a73 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Andreas=20F=C3=A4rber?= +Date: Mon, 11 Feb 2013 10:53:11 +0000 +Subject: [PATCH 26/54] target-ppc: Fix CPU_POWERPC_MPC8547E +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +It was defined to ..._MPC8545E_v21 rather than ..._MPC8547E_v21. +Due to both resolving to CPU_POWERPC_e500v2_v21 this did not show. + +Fixing this nontheless helps with QOM'ifying CPU aliases. + +Signed-off-by: Andreas Färber +Signed-off-by: Alexander Graf +(cherry picked from commit 0136d715ad985fccb8fed4bb5081d5bd20bfe88c) + +Signed-off-by: Michael Roth +--- + target-ppc/translate_init.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/target-ppc/translate_init.c b/target-ppc/translate_init.c +index 63e6fdc..a05bb7b 100644 +--- a/target-ppc/translate_init.c ++++ b/target-ppc/translate_init.c +@@ -7282,7 +7282,7 @@ enum { + #define CPU_POWERPC_MPC8545E_v10 CPU_POWERPC_e500v2_v10 + #define CPU_POWERPC_MPC8545E_v20 CPU_POWERPC_e500v2_v20 + #define CPU_POWERPC_MPC8545E_v21 CPU_POWERPC_e500v2_v21 +-#define CPU_POWERPC_MPC8547E CPU_POWERPC_MPC8545E_v21 ++#define CPU_POWERPC_MPC8547E CPU_POWERPC_MPC8547E_v21 + #define CPU_POWERPC_MPC8547E_v10 CPU_POWERPC_e500v2_v10 + #define CPU_POWERPC_MPC8547E_v20 CPU_POWERPC_e500v2_v20 + #define CPU_POWERPC_MPC8547E_v21 CPU_POWERPC_e500v2_v21 +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0027-ide-macio-Fix-macio-DMA-initialisation.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0027-ide-macio-Fix-macio-DMA-initialisation.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0027-ide-macio-Fix-macio-DMA-initialisation.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0027-ide-macio-Fix-macio-DMA-initialisation.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,39 @@ +From b91aee581090f9066a09111a220cf5c300fa56cc Mon Sep 17 00:00:00 2001 +From: Mark Cave-Ayland +Date: Sun, 24 Feb 2013 20:46:11 +0000 +Subject: [PATCH 27/54] ide/macio: Fix macio DMA initialisation. +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +Commit 07a7484e5d713f1eb7c1c37b18a8ab0d56d88875 accidentally introduced a bug +in the initialisation of the second macio DMA device which could cause some +DMA operations to segfault QEMU. + +CC: Andreas Färber +Signed-off-by: Mark Cave-Ayland +Acked-by: Andreas Färber +Signed-off-by: Stefan Hajnoczi +(cherry picked from commit 02d583c7232d65920634f7553700eb348f84e472) + +Signed-off-by: Michael Roth +--- + hw/macio.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/hw/macio.c b/hw/macio.c +index 74bdcd1..0c6a6b8 100644 +--- a/hw/macio.c ++++ b/hw/macio.c +@@ -188,7 +188,7 @@ static int macio_newworld_initfn(PCIDevice *d) + sysbus_dev = SYS_BUS_DEVICE(&ns->ide[1]); + sysbus_connect_irq(sysbus_dev, 0, ns->irqs[3]); + sysbus_connect_irq(sysbus_dev, 1, ns->irqs[4]); +- macio_ide_register_dma(&ns->ide[0], s->dbdma, 0x1a); ++ macio_ide_register_dma(&ns->ide[1], s->dbdma, 0x1a); + ret = qdev_init(DEVICE(&ns->ide[1])); + if (ret < 0) { + return ret; +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0028-virtio-blk-fix-unplug-virsh-reboot.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0028-virtio-blk-fix-unplug-virsh-reboot.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0028-virtio-blk-fix-unplug-virsh-reboot.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0028-virtio-blk-fix-unplug-virsh-reboot.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,51 @@ +From 7a687aed28c216e7779661124c066b80e1e54fb1 Mon Sep 17 00:00:00 2001 +From: Christian Borntraeger +Date: Fri, 22 Feb 2013 14:37:10 +0100 +Subject: [PATCH 28/54] virtio-blk: fix unplug + virsh reboot + +virtio-blk registers a vmstate change handler. Unfortunately this +handler is not unregistered on unplug, leading to some random +crashes if the system is restarted, e.g. via virsh reboot. +Lets unregister the vmstate change handler if the device is removed. + +Signed-off-by: Christian Borntraeger +Signed-off-by: Stefan Hajnoczi +(cherry picked from commit 69b302b2044a9a0f6d157d25b39a91ff7124c61f) + +Signed-off-by: Michael Roth +--- + hw/virtio-blk.c | 4 +++- + 1 file changed, 3 insertions(+), 1 deletion(-) + +diff --git a/hw/virtio-blk.c b/hw/virtio-blk.c +index 34913ee..f5e6ee9 100644 +--- a/hw/virtio-blk.c ++++ b/hw/virtio-blk.c +@@ -36,6 +36,7 @@ typedef struct VirtIOBlock + VirtIOBlkConf *blk; + unsigned short sector_mask; + DeviceState *qdev; ++ VMChangeStateEntry *change; + #ifdef CONFIG_VIRTIO_BLK_DATA_PLANE + VirtIOBlockDataPlane *dataplane; + #endif +@@ -681,7 +682,7 @@ VirtIODevice *virtio_blk_init(DeviceState *dev, VirtIOBlkConf *blk) + } + #endif + +- qemu_add_vm_change_state_handler(virtio_blk_dma_restart_cb, s); ++ s->change = qemu_add_vm_change_state_handler(virtio_blk_dma_restart_cb, s); + s->qdev = dev; + register_savevm(dev, "virtio-blk", virtio_blk_id++, 2, + virtio_blk_save, virtio_blk_load, s); +@@ -702,6 +703,7 @@ void virtio_blk_exit(VirtIODevice *vdev) + virtio_blk_data_plane_destroy(s->dataplane); + s->dataplane = NULL; + #endif ++ qemu_del_vm_change_state_handler(s->change); + unregister_savevm(s->qdev, "virtio-blk", s); + blockdev_mark_auto_del(s->bs); + virtio_cleanup(vdev); +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0029-Fix-page_cache-leak-in-cache_resize.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0029-Fix-page_cache-leak-in-cache_resize.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0029-Fix-page_cache-leak-in-cache_resize.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0029-Fix-page_cache-leak-in-cache_resize.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,31 @@ +From 5610ef5863a7834f0680f520beb8c48b2dc107e4 Mon Sep 17 00:00:00 2001 +From: Orit Wasserman +Date: Mon, 25 Feb 2013 19:12:01 +0200 +Subject: [PATCH 29/54] Fix page_cache leak in cache_resize + +Signed-off-by: Orit Wasserman + +Reviewed-by: Peter Maydell +Signed-off-by: Juan Quintela +(cherry picked from commit 0db65d624e0211a43c011579d6607a50d8f06082) + +Signed-off-by: Michael Roth +--- + page_cache.c | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/page_cache.c b/page_cache.c +index ba5640b..748957b 100644 +--- a/page_cache.c ++++ b/page_cache.c +@@ -208,6 +208,7 @@ int64_t cache_resize(PageCache *cache, int64_t new_num_pages) + } + } + ++ g_free(cache->page_cache); + cache->page_cache = new_cache->page_cache; + cache->max_num_items = new_cache->max_num_items; + cache->num_items = new_cache->num_items; +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0030-page_cache-fix-memory-leak.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0030-page_cache-fix-memory-leak.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0030-page_cache-fix-memory-leak.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0030-page_cache-fix-memory-leak.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,42 @@ +From 0fcf00b55c6a5fb8af1f62a9eb4cbfa3171709e6 Mon Sep 17 00:00:00 2001 +From: Peter Lieven +Date: Mon, 25 Feb 2013 19:12:03 +0200 +Subject: [PATCH 30/54] page_cache: fix memory leak + +XBZRLE encoded migration introduced a MRU page cache +meachnism. Unfortunately, cached items where never freed in +case of a collision in the page cache on cache_insert(). + +This lead to out of memory conditions during XBZRLE migration +if the page cache was small and there where a lot of collisions +in the cache. + +Signed-off-by: Peter Lieven +Signed-off-by: Orit Wasserman + +Reviewed-by: Peter Maydell +Signed-off-by: Juan Quintela +(cherry picked from commit 32a1c08b60a8ac0e63b54a5793a26b5e32b36618) + +Signed-off-by: Michael Roth +--- + page_cache.c | 3 +++ + 1 file changed, 3 insertions(+) + +diff --git a/page_cache.c b/page_cache.c +index 748957b..b92482c 100644 +--- a/page_cache.c ++++ b/page_cache.c +@@ -152,6 +152,9 @@ void cache_insert(PageCache *cache, uint64_t addr, uint8_t *pdata) + /* actual update of entry */ + it = cache_get_by_addr(cache, addr); + ++ /* free old cached data if any */ ++ g_free(it->it_data); ++ + if (!it->it_data) { + cache->num_items++; + } +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0031-qcow2-flush-refcount-cache-correctly-in-alloc_refcou.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0031-qcow2-flush-refcount-cache-correctly-in-alloc_refcou.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0031-qcow2-flush-refcount-cache-correctly-in-alloc_refcou.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0031-qcow2-flush-refcount-cache-correctly-in-alloc_refcou.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,52 @@ +From 02ea844746e072fccd30b046a383265434d3dde8 Mon Sep 17 00:00:00 2001 +From: Stefan Hajnoczi +Date: Mon, 4 Mar 2013 15:02:30 +0100 +Subject: [PATCH 31/54] qcow2: flush refcount cache correctly in + alloc_refcount_block() + +update_refcount() affects the refcount cache, it does not write to disk. +Therefore bdrv_flush(bs->file) does nothing. We need to flush the +refcount cache in order to write out the refcount updates! + +While we're here also add error returns when qcow2_cache_flush() fails. + +Signed-off-by: Stefan Hajnoczi +Signed-off-by: Kevin Wolf +(cherry picked from commit 9991923b262dc35f6dd8393ab4853edd7fc3724f) + +Signed-off-by: Michael Roth +--- + block/qcow2-refcount.c | 10 ++++++++-- + 1 file changed, 8 insertions(+), 2 deletions(-) + +diff --git a/block/qcow2-refcount.c b/block/qcow2-refcount.c +index bc1784c..6a7a230 100644 +--- a/block/qcow2-refcount.c ++++ b/block/qcow2-refcount.c +@@ -201,7 +201,10 @@ static int alloc_refcount_block(BlockDriverState *bs, + *refcount_block = NULL; + + /* We write to the refcount table, so we might depend on L2 tables */ +- qcow2_cache_flush(bs, s->l2_table_cache); ++ ret = qcow2_cache_flush(bs, s->l2_table_cache); ++ if (ret < 0) { ++ return ret; ++ } + + /* Allocate the refcount block itself and mark it as used */ + int64_t new_block = alloc_clusters_noref(bs, s->cluster_size); +@@ -237,7 +240,10 @@ static int alloc_refcount_block(BlockDriverState *bs, + goto fail_block; + } + +- bdrv_flush(bs->file); ++ ret = qcow2_cache_flush(bs, s->refcount_block_cache); ++ if (ret < 0) { ++ goto fail_block; ++ } + + /* Initialize the new refcount block only after updating its refcount, + * update_refcount uses the refcount cache itself */ +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0032-qcow2-flush-refcount-cache-correctly-in-qcow2_write_.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0032-qcow2-flush-refcount-cache-correctly-in-qcow2_write_.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0032-qcow2-flush-refcount-cache-correctly-in-qcow2_write_.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0032-qcow2-flush-refcount-cache-correctly-in-qcow2_write_.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,45 @@ +From 7d47b243d6dff50906bbdba1acb1090ee0c4937f Mon Sep 17 00:00:00 2001 +From: Stefan Hajnoczi +Date: Mon, 4 Mar 2013 15:02:31 +0100 +Subject: [PATCH 32/54] qcow2: flush refcount cache correctly in + qcow2_write_snapshots() + +Since qcow2 metadata is cached we need to flush the caches, not just the +underlying file. Use bdrv_flush(bs) instead of bdrv_flush(bs->file). + +Also add the error return path when bdrv_flush() fails and move the +flush after checking for qcow2_alloc_clusters() failure so that the +qcow2_alloc_clusters() error return value takes precedence. + +Signed-off-by: Stefan Hajnoczi +Signed-off-by: Kevin Wolf +(cherry picked from commit f6977f15561973d4a67b6aa46da88aa678c505dd) + +Signed-off-by: Michael Roth +--- + block/qcow2-snapshot.c | 5 ++++- + 1 file changed, 4 insertions(+), 1 deletion(-) + +diff --git a/block/qcow2-snapshot.c b/block/qcow2-snapshot.c +index eb8fcd5..f4719d9 100644 +--- a/block/qcow2-snapshot.c ++++ b/block/qcow2-snapshot.c +@@ -180,11 +180,14 @@ static int qcow2_write_snapshots(BlockDriverState *bs) + + /* Allocate space for the new snapshot list */ + snapshots_offset = qcow2_alloc_clusters(bs, snapshots_size); +- bdrv_flush(bs->file); + offset = snapshots_offset; + if (offset < 0) { + return offset; + } ++ ret = bdrv_flush(bs); ++ if (ret < 0) { ++ return ret; ++ } + + /* Write all snapshots to the new list */ + for(i = 0; i < s->nb_snapshots; i++) { +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0033-linux-user-syscall.c-handle-FUTEX_WAIT_BITSET-in-do_.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0033-linux-user-syscall.c-handle-FUTEX_WAIT_BITSET-in-do_.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0033-linux-user-syscall.c-handle-FUTEX_WAIT_BITSET-in-do_.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0033-linux-user-syscall.c-handle-FUTEX_WAIT_BITSET-in-do_.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,46 @@ +From 02493ee4906715e73bb98f6778a19b37924347e0 Mon Sep 17 00:00:00 2001 +From: John Rigby +Date: Sat, 23 Feb 2013 16:14:07 -0700 +Subject: [PATCH 33/54] linux-user/syscall.c: handle FUTEX_WAIT_BITSET in + do_futex + +Upstream libc has recently changed to start using +FUTEX_WAIT_BITSET instead of FUTEX_WAIT and this +is causing do_futex to return -TARGET_ENOSYS. + +Pass bitset in val3 to sys_futex which will be +ignored by kernel for the FUTEX_WAIT case. + +Signed-off-by: John Rigby +Signed-off-by: Riku Voipio +(cherry picked from commit cce246e0a21577bb2372ab3a7d6789371e087de9) + +Signed-off-by: Michael Roth +--- + linux-user/syscall.c | 3 ++- + 1 file changed, 2 insertions(+), 1 deletion(-) + +diff --git a/linux-user/syscall.c b/linux-user/syscall.c +index 9e31ea7..7bc5ba9 100644 +--- a/linux-user/syscall.c ++++ b/linux-user/syscall.c +@@ -4920,6 +4920,7 @@ static int do_futex(target_ulong uaddr, int op, int val, target_ulong timeout, + #endif + switch (base_op) { + case FUTEX_WAIT: ++ case FUTEX_WAIT_BITSET: + if (timeout) { + pts = &ts; + target_to_host_timespec(pts, timeout); +@@ -4927,7 +4928,7 @@ static int do_futex(target_ulong uaddr, int op, int val, target_ulong timeout, + pts = NULL; + } + return get_errno(sys_futex(g2h(uaddr), op, tswap32(val), +- pts, NULL, 0)); ++ pts, NULL, val3)); + case FUTEX_WAKE: + return get_errno(sys_futex(g2h(uaddr), op, val, NULL, NULL, 0)); + case FUTEX_FD: +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0034-linux-user-fix-futex-strace-of-FUTEX_CLOCK_REALTIME.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0034-linux-user-fix-futex-strace-of-FUTEX_CLOCK_REALTIME.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0034-linux-user-fix-futex-strace-of-FUTEX_CLOCK_REALTIME.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0034-linux-user-fix-futex-strace-of-FUTEX_CLOCK_REALTIME.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,36 @@ +From 7a238b9fbdd0f4d21e8b1d5825067f92c394449c Mon Sep 17 00:00:00 2001 +From: John Rigby +Date: Sat, 23 Feb 2013 16:14:08 -0700 +Subject: [PATCH 34/54] linux-user: fix futex strace of FUTEX_CLOCK_REALTIME + +Handle same as existing FUTEX_PRIVATE_FLAG. + +Signed-off-by: John Rigby +Signed-off-by: Riku Voipio +(cherry picked from commit bfb669f39f2ecd854992924ced20b00163509043) + +Signed-off-by: Michael Roth +--- + linux-user/strace.c | 6 ++++++ + 1 file changed, 6 insertions(+) + +diff --git a/linux-user/strace.c b/linux-user/strace.c +index 4e91a6e..f8030e0 100644 +--- a/linux-user/strace.c ++++ b/linux-user/strace.c +@@ -1437,6 +1437,12 @@ if( cmd == val ) { \ + cmd &= ~FUTEX_PRIVATE_FLAG; + } + #endif ++#ifdef FUTEX_CLOCK_REALTIME ++ if (cmd & FUTEX_CLOCK_REALTIME) { ++ gemu_log("FUTEX_CLOCK_REALTIME|"); ++ cmd &= ~FUTEX_CLOCK_REALTIME; ++ } ++#endif + print_op(FUTEX_WAIT) + print_op(FUTEX_WAKE) + print_op(FUTEX_FD) +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0035-linux-user-make-bogus-negative-iovec-lengths-fail-EI.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0035-linux-user-make-bogus-negative-iovec-lengths-fail-EI.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0035-linux-user-make-bogus-negative-iovec-lengths-fail-EI.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0035-linux-user-make-bogus-negative-iovec-lengths-fail-EI.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,36 @@ +From 8378910554a03d54c22ab46cfaec491ee95b8315 Mon Sep 17 00:00:00 2001 +From: Peter Maydell +Date: Fri, 8 Feb 2013 07:58:41 +0000 +Subject: [PATCH 35/54] linux-user: make bogus negative iovec lengths fail + EINVAL + +If the guest passes us a bogus negative length for an iovec, fail +EINVAL rather than proceeding blindly forward. This fixes some of +the error cases tests for readv and writev in the LTP. + +Signed-off-by: Peter Maydell +Reviewed-by: Richard Henderson +Signed-off-by: Riku Voipio +(cherry picked from commit dfae8e00f8ddeedcda24bd28f71d4fd2a9f988b8) + +Signed-off-by: Michael Roth +--- + linux-user/syscall.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/linux-user/syscall.c b/linux-user/syscall.c +index 7bc5ba9..b682357 100644 +--- a/linux-user/syscall.c ++++ b/linux-user/syscall.c +@@ -1776,7 +1776,7 @@ static struct iovec *lock_iovec(int type, abi_ulong target_addr, + errno = 0; + return NULL; + } +- if (count > IOV_MAX) { ++ if (count < 0 || count > IOV_MAX) { + errno = EINVAL; + return NULL; + } +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0036-linux-user-syscall.c-Don-t-warn-about-unimplemented-.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0036-linux-user-syscall.c-Don-t-warn-about-unimplemented-.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0036-linux-user-syscall.c-Don-t-warn-about-unimplemented-.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0036-linux-user-syscall.c-Don-t-warn-about-unimplemented-.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,54 @@ +From 799a34a48ba609f1157bf9a7ec1170e7d67faab0 Mon Sep 17 00:00:00 2001 +From: Peter Maydell +Date: Fri, 8 Feb 2013 04:34:54 +0000 +Subject: [PATCH 36/54] linux-user/syscall.c: Don't warn about unimplemented + get_robust_list + +The nature of the kernel ABI for the get_robust_list and set_robust_list +syscalls means we cannot implement them in QEMU. Make get_robust_list +silently return ENOSYS rather than using the default "print message and +then fail ENOSYS" code path, in the same way we already do for +set_robust_list, and add a comment documenting why we do this. + +This silences warnings which were being produced for emulating +even trivial programs like 'ls' in x86-64-on-x86-64. + +Signed-off-by: Peter Maydell +Reviewed-by: Richard Henderson +Signed-off-by: Riku Voipio +(cherry picked from commit e9a970a8316f9f86a6c800a9a90175bd593f862c) + +Signed-off-by: Michael Roth +--- + linux-user/syscall.c | 15 ++++++++++++++- + 1 file changed, 14 insertions(+), 1 deletion(-) + +diff --git a/linux-user/syscall.c b/linux-user/syscall.c +index b682357..4e43a58 100644 +--- a/linux-user/syscall.c ++++ b/linux-user/syscall.c +@@ -8551,7 +8551,20 @@ abi_long do_syscall(void *cpu_env, int num, abi_long arg1, + + #ifdef TARGET_NR_set_robust_list + case TARGET_NR_set_robust_list: +- goto unimplemented_nowarn; ++ case TARGET_NR_get_robust_list: ++ /* The ABI for supporting robust futexes has userspace pass ++ * the kernel a pointer to a linked list which is updated by ++ * userspace after the syscall; the list is walked by the kernel ++ * when the thread exits. Since the linked list in QEMU guest ++ * memory isn't a valid linked list for the host and we have ++ * no way to reliably intercept the thread-death event, we can't ++ * support these. Silently return ENOSYS so that guest userspace ++ * falls back to a non-robust futex implementation (which should ++ * be OK except in the corner case of the guest crashing while ++ * holding a mutex that is shared with another process via ++ * shared memory). ++ */ ++ goto unimplemented_nowarn; + #endif + + #if defined(TARGET_NR_utimensat) && defined(__NR_utimensat) +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0037-update-seabios-to-1.7.2.1.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0037-update-seabios-to-1.7.2.1.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0037-update-seabios-to-1.7.2.1.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0037-update-seabios-to-1.7.2.1.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,788 @@ +From 01357962718faee20d558dc5ee8ae248427af9e5 Mon Sep 17 00:00:00 2001 +From: Gerd Hoffmann +Date: Thu, 28 Feb 2013 09:18:56 +0100 +Subject: [PATCH 37/54] update seabios to 1.7.2.1 + +Alex Williamson (3): + seabios q35: Enable all PIRQn IRQs at startup + seabios q35: Add new PCI slot to irq routing function + seabios: Add a dummy PCI slot to irq mapping function + +Avik Sil (1): + USB-EHCI: Fix null pointer assignment + +Kevin O'Connor (4): + Update tools/acpi_extract.py to handle iasl 20130117 release. + Fix Makefile - don't reference "out/" directly, instead use "$(OUT)". + build: Don't require $(OUT) to be a sub-directory of the main +directory. + Verify CC is valid during build tests. + +Signed-off-by: Gerd Hoffmann +(cherry picked from commit 5c75fb10029c5fd1e705a6ef5d698fbea06c7a33) + +Signed-off-by: Michael Roth +--- + pc-bios/bios.bin | Bin 131072 -> 131072 bytes + roms/seabios | 2 +- + 2 files changed, 1 insertion(+), 1 deletion(-) + +diff --git a/pc-bios/bios.bin b/pc-bios/bios.bin +index ab5dd9db6addf9d6a6f67697231ef604bab02fc8..ec9eeb12c62a511f2e45bfc6fe3af90cc6da0d65 100644 +GIT binary patch +delta 27073 +zcmaL930PCd7dCz;tSSrpqa0$={cHtcB=9k?4KM)5fwRB`AkIz@TGSVWFkk@ik%J&i1Iii+LWxQc +zegn)vtcxH#CNvdVLFfV)0hOSVAqZ#?4%xt-4#FfdXO+&c+^*jW&EMhn8{T?AoAS7;1$jDZ5cOW;s9 +zLD0tvLP5MBoChj^fbJ05Ll6>y&47JRK^O|01U4iH!dBoMa0RFY{si6vieAV|$Cqty +zFaoU-1)+H#LC6Q1_7#MC{n7nNg0L323Ahaa4=@y1540R82sJ>1WI@mYY%qEP2pEDM +z0Fs8HYzl@6SUpS-E&^tt!ElrvAqYKz^a6Y>9Eq+QjqwJSjX@WW6$BG-Y8=MzBSDx8 +zECrIr3&J-O1flITLC^vxr=!9dg3x28Ancz7#euiL#My%I8PIJG8U_e+1>qX-PpTj! +z%!7R_7K9g{3c}TNjDLKlAZ+>^TIvL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`*OssgH}jMe`4FQZ@u!(=1M#N#O^stn)aOaQLznqC!fO~v4?p}Ua(DA +z$)vECtg-+0Wb_<%snwgc%CLS7@%8dv3>Jcaxxq{+^(FJS55OX%mwQTEUa}pCd3wLX +zf_y@n^NPj$zARS43)2UD>*atcsM!Cl-ejlPnd=nk_A53hsQLU~ywCjN38l>~s2Y +eYpLE}(vS+4;CS_T#c$@HD?kW3A?>SR-Toi4z4lxH + +diff --git a/roms/seabios b/roms/seabios +index 4bd8aeb..88cb66e 160000 +--- a/roms/seabios ++++ b/roms/seabios +@@ -1 +1 @@ +-Subproject commit 4bd8aebf3534e10d9aa21e820903f2cf9120708c ++Subproject commit 88cb66ea542906ffff8a80ef397b9e3adbb33116 +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0038-oslib-posix-rename-socket_set_nonblock-to-qemu_set_n.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0038-oslib-posix-rename-socket_set_nonblock-to-qemu_set_n.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0038-oslib-posix-rename-socket_set_nonblock-to-qemu_set_n.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0038-oslib-posix-rename-socket_set_nonblock-to-qemu_set_n.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,392 @@ +From 68f9df599042482e54cd92193d3a8679c2b35bc7 Mon Sep 17 00:00:00 2001 +From: Stefan Hajnoczi +Date: Thu, 4 Apr 2013 16:18:28 +0200 +Subject: [PATCH 38/54] oslib-posix: rename socket_set_nonblock() to + qemu_set_nonblock() + +The fcntl(fd, F_SETFL, O_NONBLOCK) flag is not specific to sockets. +Rename to qemu_set_nonblock() just like qemu_set_cloexec(). + +Signed-off-by: Stefan Hajnoczi +(cherry picked from commit 399f1c8f8af1f6f8b18ef4e37169c6301264e467) + +Signed-off-by: Stefan Hajnoczi + +Conflicts: + block/sheepdog.c + +socket_set_block()/socket_set_nonblock() calls in different locations + + include/qemu/sockets.h + +socket_set_nodelay() does not exist in v1.4.0, messes up diff context + + qemu-char.c + +glib G_IO_IN events are not used in v1.4.0, messes up diff context + + savevm.c + +qemu_fopen_socket() only has read mode in v1.4.0, qemu_set_block() not +necessary. + + slirp/misc.c + +unportable setsockopt() calls in v1.4.0 mess up diff context + + slirp/tcp_subr.c + +file was reformatted, diff context is messed up + + ui/vnc.c + +old dcl->idle instead of vd->dcl.idle messes up diff context + +Added: + migration-tcp.c, migration-unix.c + +qemu_fopen_socket() write mode does not exist yet, qemu_set_block() call +is needed here. +Signed-off-by: Michael Roth +--- + block/nbd.c | 2 +- + block/sheepdog.c | 6 +++--- + include/qemu/sockets.h | 4 ++-- + migration-tcp.c | 2 +- + migration-unix.c | 2 +- + migration.c | 2 +- + nbd.c | 8 ++++---- + net/socket.c | 6 +++--- + qemu-char.c | 8 ++++---- + slirp/misc.c | 2 +- + slirp/tcp_subr.c | 4 ++-- + ui/vnc.c | 2 +- + util/oslib-posix.c | 4 ++-- + util/oslib-win32.c | 4 ++-- + util/qemu-sockets.c | 4 ++-- + 15 files changed, 30 insertions(+), 30 deletions(-) + +diff --git a/block/nbd.c b/block/nbd.c +index a581294..6562fd3 100644 +--- a/block/nbd.c ++++ b/block/nbd.c +@@ -350,7 +350,7 @@ static int nbd_establish_connection(BlockDriverState *bs) + + /* Now that we're connected, set the socket to be non-blocking and + * kick the reply mechanism. */ +- socket_set_nonblock(sock); ++ qemu_set_nonblock(sock); + qemu_aio_set_fd_handler(sock, nbd_reply_ready, NULL, + nbd_have_request, s); + +diff --git a/block/sheepdog.c b/block/sheepdog.c +index d466b23..b968b59 100644 +--- a/block/sheepdog.c ++++ b/block/sheepdog.c +@@ -549,7 +549,7 @@ static coroutine_fn void do_co_req(void *opaque) + co = qemu_coroutine_self(); + qemu_aio_set_fd_handler(sockfd, NULL, restart_co_req, NULL, co); + +- socket_set_block(sockfd); ++ qemu_set_block(sockfd); + ret = send_co_req(sockfd, hdr, data, wlen); + if (ret < 0) { + goto out; +@@ -579,7 +579,7 @@ static coroutine_fn void do_co_req(void *opaque) + ret = 0; + out: + qemu_aio_set_fd_handler(sockfd, NULL, NULL, NULL, NULL); +- socket_set_nonblock(sockfd); ++ qemu_set_nonblock(sockfd); + + srco->ret = ret; + srco->finished = true; +@@ -812,7 +812,7 @@ static int get_sheep_fd(BDRVSheepdogState *s) + return fd; + } + +- socket_set_nonblock(fd); ++ qemu_set_nonblock(fd); + + ret = set_nodelay(fd); + if (ret) { +diff --git a/include/qemu/sockets.h b/include/qemu/sockets.h +index 803ae17..0ccf32f 100644 +--- a/include/qemu/sockets.h ++++ b/include/qemu/sockets.h +@@ -34,8 +34,8 @@ int inet_aton(const char *cp, struct in_addr *ia); + int qemu_socket(int domain, int type, int protocol); + int qemu_accept(int s, struct sockaddr *addr, socklen_t *addrlen); + int socket_set_cork(int fd, int v); +-void socket_set_block(int fd); +-void socket_set_nonblock(int fd); ++void qemu_set_block(int fd); ++void qemu_set_nonblock(int fd); + int send_all(int fd, const void *buf, int len1); + + /* callback function for nonblocking connect +diff --git a/migration-tcp.c b/migration-tcp.c +index e78a296..59e3b7e 100644 +--- a/migration-tcp.c ++++ b/migration-tcp.c +@@ -60,7 +60,7 @@ static void tcp_wait_for_connect(int fd, void *opaque) + } else { + DPRINTF("migrate connect success\n"); + s->fd = fd; +- socket_set_block(s->fd); ++ qemu_set_block(s->fd); + migrate_fd_connect(s); + } + } +diff --git a/migration-unix.c b/migration-unix.c +index 218835a..0ca2a21 100644 +--- a/migration-unix.c ++++ b/migration-unix.c +@@ -60,7 +60,7 @@ static void unix_wait_for_connect(int fd, void *opaque) + } else { + DPRINTF("migrate connect success\n"); + s->fd = fd; +- socket_set_block(s->fd); ++ qemu_set_block(s->fd); + migrate_fd_connect(s); + } + } +diff --git a/migration.c b/migration.c +index b1ebb01..98c7696 100644 +--- a/migration.c ++++ b/migration.c +@@ -120,7 +120,7 @@ void process_incoming_migration(QEMUFile *f) + int fd = qemu_get_fd(f); + + assert(fd != -1); +- socket_set_nonblock(fd); ++ qemu_set_nonblock(fd); + qemu_coroutine_enter(co, f); + } + +diff --git a/nbd.c b/nbd.c +index 0698a02..2eff5a2 100644 +--- a/nbd.c ++++ b/nbd.c +@@ -393,7 +393,7 @@ static int nbd_send_negotiate(NBDClient *client) + [28 .. 151] reserved (0) + */ + +- socket_set_block(csock); ++ qemu_set_block(csock); + rc = -EINVAL; + + TRACE("Beginning negotiation."); +@@ -436,7 +436,7 @@ static int nbd_send_negotiate(NBDClient *client) + TRACE("Negotiation succeeded."); + rc = 0; + fail: +- socket_set_nonblock(csock); ++ qemu_set_nonblock(csock); + return rc; + } + +@@ -450,7 +450,7 @@ int nbd_receive_negotiate(int csock, const char *name, uint32_t *flags, + + TRACE("Receiving negotiation."); + +- socket_set_block(csock); ++ qemu_set_block(csock); + rc = -EINVAL; + + if (read_sync(csock, buf, 8) != 8) { +@@ -565,7 +565,7 @@ int nbd_receive_negotiate(int csock, const char *name, uint32_t *flags, + rc = 0; + + fail: +- socket_set_nonblock(csock); ++ qemu_set_nonblock(csock); + return rc; + } + +diff --git a/net/socket.c b/net/socket.c +index 396dc8c..ea407c7 100644 +--- a/net/socket.c ++++ b/net/socket.c +@@ -309,7 +309,7 @@ static int net_socket_mcast_create(struct sockaddr_in *mcastaddr, struct in_addr + } + } + +- socket_set_nonblock(fd); ++ qemu_set_nonblock(fd); + return fd; + fail: + if (fd >= 0) +@@ -517,7 +517,7 @@ static int net_socket_listen_init(NetClientState *peer, + perror("socket"); + return -1; + } +- socket_set_nonblock(fd); ++ qemu_set_nonblock(fd); + + /* allow fast reuse */ + val = 1; +@@ -563,7 +563,7 @@ static int net_socket_connect_init(NetClientState *peer, + perror("socket"); + return -1; + } +- socket_set_nonblock(fd); ++ qemu_set_nonblock(fd); + + connected = 0; + for(;;) { +diff --git a/qemu-char.c b/qemu-char.c +index 3e152e1..050764b 100644 +--- a/qemu-char.c ++++ b/qemu-char.c +@@ -2377,7 +2377,7 @@ static int tcp_chr_add_client(CharDriverState *chr, int fd) + if (s->fd != -1) + return -1; + +- socket_set_nonblock(fd); ++ qemu_set_nonblock(fd); + if (s->do_nodelay) + socket_set_nodelay(fd); + s->fd = fd; +@@ -2512,7 +2512,7 @@ static CharDriverState *qemu_chr_open_socket_fd(int fd, bool do_nodelay, + printf("QEMU waiting for connection on: %s\n", + chr->filename); + tcp_chr_accept(chr); +- socket_set_nonblock(s->listen_fd); ++ qemu_set_nonblock(s->listen_fd); + } + return chr; + } +@@ -2554,7 +2554,7 @@ static CharDriverState *qemu_chr_open_socket(QemuOpts *opts) + } + + if (!is_waitconnect) +- socket_set_nonblock(fd); ++ qemu_set_nonblock(fd); + + chr = qemu_chr_open_socket_fd(fd, do_nodelay, is_listen, is_telnet, + is_waitconnect, &local_err); +@@ -3328,7 +3328,7 @@ static CharDriverState *qmp_chardev_open_serial(ChardevHostdev *serial, + if (error_is_set(errp)) { + return NULL; + } +- socket_set_nonblock(fd); ++ qemu_set_nonblock(fd); + return qemu_chr_open_tty_fd(fd); + #else + error_setg(errp, "character device backend type 'serial' not supported"); +diff --git a/slirp/misc.c b/slirp/misc.c +index d4df972..00f0140 100644 +--- a/slirp/misc.c ++++ b/slirp/misc.c +@@ -215,7 +215,7 @@ fork_exec(struct socket *so, const char *ex, int do_pty) + setsockopt(so->s, SOL_SOCKET, SO_REUSEADDR, (char *)&opt, sizeof(int)); + opt = 1; + setsockopt(so->s, SOL_SOCKET, SO_OOBINLINE, (char *)&opt, sizeof(int)); +- socket_set_nonblock(so->s); ++ qemu_set_nonblock(so->s); + + /* Append the telnet options now */ + if (so->so_m != NULL && do_pty == 1) { +diff --git a/slirp/tcp_subr.c b/slirp/tcp_subr.c +index 1542e43..8b7c2b5 100644 +--- a/slirp/tcp_subr.c ++++ b/slirp/tcp_subr.c +@@ -336,7 +336,7 @@ int tcp_fconnect(struct socket *so) + int opt, s=so->s; + struct sockaddr_in addr; + +- socket_set_nonblock(s); ++ qemu_set_nonblock(s); + opt = 1; + setsockopt(s,SOL_SOCKET,SO_REUSEADDR,(char *)&opt,sizeof(opt )); + opt = 1; +@@ -424,7 +424,7 @@ tcp_connect(struct socket *inso) + tcp_close(sototcpcb(so)); /* This will sofree() as well */ + return; + } +- socket_set_nonblock(s); ++ qemu_set_nonblock(s); + opt = 1; + setsockopt(s,SOL_SOCKET,SO_REUSEADDR,(char *)&opt,sizeof(int)); + opt = 1; +diff --git a/ui/vnc.c b/ui/vnc.c +index ff4e2ae..9ba3794 100644 +--- a/ui/vnc.c ++++ b/ui/vnc.c +@@ -2726,7 +2726,7 @@ static void vnc_connect(VncDisplay *vd, int csock, int skipauth, bool websocket) + + VNC_DEBUG("New client on socket %d\n", csock); + dcl->idle = 0; +- socket_set_nonblock(vs->csock); ++ qemu_set_nonblock(vs->csock); + #ifdef CONFIG_VNC_WS + if (websocket) { + vs->websocket = 1; +diff --git a/util/oslib-posix.c b/util/oslib-posix.c +index b4152fb..42fbfed 100644 +--- a/util/oslib-posix.c ++++ b/util/oslib-posix.c +@@ -134,14 +134,14 @@ void qemu_vfree(void *ptr) + free(ptr); + } + +-void socket_set_block(int fd) ++void qemu_set_block(int fd) + { + int f; + f = fcntl(fd, F_GETFL); + fcntl(fd, F_SETFL, f & ~O_NONBLOCK); + } + +-void socket_set_nonblock(int fd) ++void qemu_set_nonblock(int fd) + { + int f; + f = fcntl(fd, F_GETFL); +diff --git a/util/oslib-win32.c b/util/oslib-win32.c +index 640194c..dcfa0c2 100644 +--- a/util/oslib-win32.c ++++ b/util/oslib-win32.c +@@ -100,14 +100,14 @@ struct tm *localtime_r(const time_t *timep, struct tm *result) + return p; + } + +-void socket_set_block(int fd) ++void qemu_set_block(int fd) + { + unsigned long opt = 0; + WSAEventSelect(fd, NULL, 0); + ioctlsocket(fd, FIONBIO, &opt); + } + +-void socket_set_nonblock(int fd) ++void qemu_set_nonblock(int fd) + { + unsigned long opt = 1; + ioctlsocket(fd, FIONBIO, &opt); +diff --git a/util/qemu-sockets.c b/util/qemu-sockets.c +index 1350ccc..e92e0d5 100644 +--- a/util/qemu-sockets.c ++++ b/util/qemu-sockets.c +@@ -277,7 +277,7 @@ static int inet_connect_addr(struct addrinfo *addr, bool *in_progress, + } + qemu_setsockopt(sock, SOL_SOCKET, SO_REUSEADDR, &on, sizeof(on)); + if (connect_state != NULL) { +- socket_set_nonblock(sock); ++ qemu_set_nonblock(sock); + } + /* connect to peer */ + do { +@@ -733,7 +733,7 @@ int unix_connect_opts(QemuOpts *opts, Error **errp, + connect_state = g_malloc0(sizeof(*connect_state)); + connect_state->callback = callback; + connect_state->opaque = opaque; +- socket_set_nonblock(sock); ++ qemu_set_nonblock(sock); + } + + memset(&un, 0, sizeof(un)); +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0039-net-ensure-socket-backend-uses-non-blocking-fds.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0039-net-ensure-socket-backend-uses-non-blocking-fds.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0039-net-ensure-socket-backend-uses-non-blocking-fds.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0039-net-ensure-socket-backend-uses-non-blocking-fds.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,54 @@ +From a1cb89f3fedd6206bc1d99744f303afad2fa6dee Mon Sep 17 00:00:00 2001 +From: Stefan Hajnoczi +Date: Thu, 4 Apr 2013 16:18:29 +0200 +Subject: [PATCH 39/54] net: ensure "socket" backend uses non-blocking fds + +There are several code paths in net_init_socket() depending on how the +socket is created: file descriptor passing, UDP multicast, TCP, or UDP. +Some of these support both listen and connect. + +Not all code paths set the socket to non-blocking. This patch addresses +the file descriptor passing and UDP cases which were missing +socket_set_nonblock(fd) calls. + +I considered moving socket_set_nonblock(fd) to a central location but it +turns out the code paths are different enough to require non-blocking at +different places. + +Signed-off-by: Stefan Hajnoczi +(cherry picked from commit f05b707279dc7c29ab10d9d13dbf413df6ec22f1) + +Signed-off-by: Stefan Hajnoczi +Signed-off-by: Michael Roth +--- + net/socket.c | 7 ++++++- + 1 file changed, 6 insertions(+), 1 deletion(-) + +diff --git a/net/socket.c b/net/socket.c +index ea407c7..a2b94f4 100644 +--- a/net/socket.c ++++ b/net/socket.c +@@ -672,6 +672,7 @@ static int net_socket_udp_init(NetClientState *peer, + closesocket(fd); + return -1; + } ++ qemu_set_nonblock(fd); + + s = net_socket_fd_init(peer, model, name, fd, 0); + if (!s) { +@@ -710,7 +711,11 @@ int net_init_socket(const NetClientOptions *opts, const char *name, + int fd; + + fd = monitor_handle_fd_param(cur_mon, sock->fd); +- if (fd == -1 || !net_socket_fd_init(peer, "socket", name, fd, 1)) { ++ if (fd == -1) { ++ return -1; ++ } ++ qemu_set_nonblock(fd); ++ if (!net_socket_fd_init(peer, "socket", name, fd, 1)) { + return -1; + } + return 0; +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0040-qemu-socket-set-passed-fd-non-blocking-in-socket_con.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0040-qemu-socket-set-passed-fd-non-blocking-in-socket_con.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0040-qemu-socket-set-passed-fd-non-blocking-in-socket_con.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0040-qemu-socket-set-passed-fd-non-blocking-in-socket_con.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,34 @@ +From 283b7de6a57ff96db89d46874cfdb6fc590760dc Mon Sep 17 00:00:00 2001 +From: Stefan Hajnoczi +Date: Thu, 4 Apr 2013 16:18:30 +0200 +Subject: [PATCH 40/54] qemu-socket: set passed fd non-blocking in + socket_connect() + +socket_connect() sets non-blocking on TCP or UNIX domain sockets if a +callback function is passed. Do the same for file descriptor passing, +otherwise we could unexpectedly be using a blocking file descriptor. + +Signed-off-by: Stefan Hajnoczi +(cherry picked from commit 35fb94fa292173a3e1df0768433e06912a2a88e4) + +Signed-off-by: Stefan Hajnoczi +Signed-off-by: Michael Roth +--- + util/qemu-sockets.c | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/util/qemu-sockets.c b/util/qemu-sockets.c +index e92e0d5..cd54fb4 100644 +--- a/util/qemu-sockets.c ++++ b/util/qemu-sockets.c +@@ -906,6 +906,7 @@ int socket_connect(SocketAddress *addr, Error **errp, + case SOCKET_ADDRESS_KIND_FD: + fd = monitor_get_fd(cur_mon, addr->fd->str, errp); + if (callback) { ++ qemu_set_nonblock(fd); + callback(fd, opaque); + } + break; +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0041-chardev-clear-O_NONBLOCK-on-SCM_RIGHTS-file-descript.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0041-chardev-clear-O_NONBLOCK-on-SCM_RIGHTS-file-descript.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0041-chardev-clear-O_NONBLOCK-on-SCM_RIGHTS-file-descript.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0041-chardev-clear-O_NONBLOCK-on-SCM_RIGHTS-file-descript.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,46 @@ +From 27c71355fbf7f999f3fbb8ec42ec88210211b6f4 Mon Sep 17 00:00:00 2001 +From: Stefan Hajnoczi +Date: Thu, 4 Apr 2013 16:18:31 +0200 +Subject: [PATCH 41/54] chardev: clear O_NONBLOCK on SCM_RIGHTS file + descriptors + +When we receive a file descriptor over a UNIX domain socket the +O_NONBLOCK flag is preserved. Clear the O_NONBLOCK flag and rely on +QEMU file descriptor users like migration, SPICE, VNC, block layer, and +others to set non-blocking only when necessary. + +This change ensures we don't accidentally expose O_NONBLOCK in the QMP +API. QMP clients should not need to get the non-blocking state +"correct". + +A recent real-world example was when libvirt passed a non-blocking TCP +socket for migration where we expected a blocking socket. The source +QEMU produced a corrupted migration stream since its code did not cope +with non-blocking sockets. + +Signed-off-by: Stefan Hajnoczi +(cherry picked from commit e374f7f816171f9783c1d9d00a041f26379f1ac6) + +Signed-off-by: Stefan Hajnoczi +Signed-off-by: Michael Roth +--- + qemu-char.c | 3 +++ + 1 file changed, 3 insertions(+) + +diff --git a/qemu-char.c b/qemu-char.c +index 050764b..f4a74ac 100644 +--- a/qemu-char.c ++++ b/qemu-char.c +@@ -2252,6 +2252,9 @@ static void unix_process_msgfd(CharDriverState *chr, struct msghdr *msg) + if (fd < 0) + continue; + ++ /* O_NONBLOCK is preserved across SCM_RIGHTS so reset it */ ++ qemu_set_block(fd); ++ + #ifndef MSG_CMSG_CLOEXEC + qemu_set_cloexec(fd); + #endif +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0042-usb-tablet-Don-t-claim-wakeup-capability-for-USB-2-v.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0042-usb-tablet-Don-t-claim-wakeup-capability-for-USB-2-v.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0042-usb-tablet-Don-t-claim-wakeup-capability-for-USB-2-v.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0042-usb-tablet-Don-t-claim-wakeup-capability-for-USB-2-v.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,36 @@ +From 57e929c19c5aec8cbb572ec218ff6cbe250f5fc1 Mon Sep 17 00:00:00 2001 +From: Hans de Goede +Date: Tue, 2 Apr 2013 19:15:05 +0200 +Subject: [PATCH 42/54] usb-tablet: Don't claim wakeup capability for USB-2 + version + +Our ehci code does not implement wakeup support, so claiming support for +it with usb-tablet in USB-2 mode causes all tablet events to get lost. + +http://bugzilla.redhat.com/show_bug.cgi?id=929068 + +Signed-off-by: Hans de Goede +Signed-off-by: Gerd Hoffmann +(cherry picked from commit aa1c9e971e80d25b92908dce3dec7c38b49480ea) + +Signed-off-by: Michael Roth +--- + hw/usb/dev-hid.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/hw/usb/dev-hid.c b/hw/usb/dev-hid.c +index 29b6481..801f32b 100644 +--- a/hw/usb/dev-hid.c ++++ b/hw/usb/dev-hid.c +@@ -236,7 +236,7 @@ static const USBDescDevice desc_device_tablet2 = { + .bNumInterfaces = 1, + .bConfigurationValue = 1, + .iConfiguration = STR_CONFIG_TABLET, +- .bmAttributes = 0xa0, ++ .bmAttributes = 0x80, + .bMaxPower = 50, + .nif = 1, + .ifs = &desc_iface_tablet2, +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0043-target-mips-fix-for-incorrect-multiplication-with-MU.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0043-target-mips-fix-for-incorrect-multiplication-with-MU.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0043-target-mips-fix-for-incorrect-multiplication-with-MU.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0043-target-mips-fix-for-incorrect-multiplication-with-MU.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,61 @@ +From 79a4dd4085fceaaf23b619e1e269478306226f16 Mon Sep 17 00:00:00 2001 +From: Petar Jovanovic +Date: Wed, 6 Feb 2013 18:05:25 +0100 +Subject: [PATCH 43/54] target-mips: fix for incorrect multiplication with + MULQ_S.PH + +The change corrects sign-related issue with MULQ_S.PH. It also includes +extension to the already existing test which will trigger the issue. + +Signed-off-by: Petar Jovanovic +Signed-off-by: Aurelien Jarno +(cherry picked from commit 9c19eb1e205b29018f6f61c5f43db6abbe7dc0e5) + +Signed-off-by: Michael Roth +--- + target-mips/dsp_helper.c | 2 +- + tests/tcg/mips/mips32-dspr2/mulq_s_ph.c | 15 +++++++++++++++ + 2 files changed, 16 insertions(+), 1 deletion(-) + +diff --git a/target-mips/dsp_helper.c b/target-mips/dsp_helper.c +index 96cb044..6781da8 100644 +--- a/target-mips/dsp_helper.c ++++ b/target-mips/dsp_helper.c +@@ -652,7 +652,7 @@ static inline int32_t mipsdsp_sat16_mul_q15_q15(uint16_t a, uint16_t b, + temp = 0x7FFF0000; + set_DSPControl_overflow_flag(1, 21, env); + } else { +- temp = ((uint32_t)a * (uint32_t)b); ++ temp = (int16_t)a * (int16_t)b; + temp = temp << 1; + } + +diff --git a/tests/tcg/mips/mips32-dspr2/mulq_s_ph.c b/tests/tcg/mips/mips32-dspr2/mulq_s_ph.c +index d0f7674..00e0155 100644 +--- a/tests/tcg/mips/mips32-dspr2/mulq_s_ph.c ++++ b/tests/tcg/mips/mips32-dspr2/mulq_s_ph.c +@@ -6,6 +6,21 @@ int main() + int rd, rs, rt, dsp; + int result, resultdsp; + ++ rs = 0x80000000; ++ rt = 0x0ffc0000; ++ result = 0xF0040000; ++ resultdsp = 0; ++ ++ __asm ++ ("mulq_s.ph %0, %2, %3\n\t" ++ "rddsp %1\n\t" ++ : "=r"(rd), "=r"(dsp) ++ : "r"(rs), "r"(rt) ++ ); ++ dsp = (dsp >> 21) & 0x01; ++ assert(rd == result); ++ assert(dsp == resultdsp); ++ + rs = 0x80001234; + rt = 0x80004321; + result = 0x7FFF098B; +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0044-target-mips-fix-for-sign-issue-in-MULQ_W-helper.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0044-target-mips-fix-for-sign-issue-in-MULQ_W-helper.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0044-target-mips-fix-for-sign-issue-in-MULQ_W-helper.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0044-target-mips-fix-for-sign-issue-in-MULQ_W-helper.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,63 @@ +From b09a67316484af24427a7174b65531e9c0b6e6b4 Mon Sep 17 00:00:00 2001 +From: Petar Jovanovic +Date: Thu, 7 Feb 2013 19:36:09 +0100 +Subject: [PATCH 44/54] target-mips: fix for sign-issue in MULQ_W helper + +Correct sign-propagation before multiplication in MULQ_W helper. +The change also fixes previously incorrect expected values in the +tests for MULQ_RS.W and MULQ_S.W. + +Signed-off-by: Petar Jovanovic +Richard Henderson +Signed-off-by: Aurelien Jarno +(cherry picked from commit a345481baa2b2fb3d54f8c9ddb58dfcaf75786df) + +Signed-off-by: Michael Roth +--- + target-mips/dsp_helper.c | 2 +- + tests/tcg/mips/mips32-dspr2/mulq_rs_w.c | 2 +- + tests/tcg/mips/mips32-dspr2/mulq_s_w.c | 2 +- + 3 files changed, 3 insertions(+), 3 deletions(-) + +diff --git a/target-mips/dsp_helper.c b/target-mips/dsp_helper.c +index 6781da8..841f47b 100644 +--- a/target-mips/dsp_helper.c ++++ b/target-mips/dsp_helper.c +@@ -2689,7 +2689,7 @@ MAQ_SA_W(maq_sa_w_phr, 0); + target_ulong helper_##name(target_ulong rs, target_ulong rt, \ + CPUMIPSState *env) \ + { \ +- uint32_t rs_t, rt_t; \ ++ int32_t rs_t, rt_t; \ + int32_t tempI; \ + int64_t tempL; \ + \ +diff --git a/tests/tcg/mips/mips32-dspr2/mulq_rs_w.c b/tests/tcg/mips/mips32-dspr2/mulq_rs_w.c +index 669405f..7ba633b 100644 +--- a/tests/tcg/mips/mips32-dspr2/mulq_rs_w.c ++++ b/tests/tcg/mips/mips32-dspr2/mulq_rs_w.c +@@ -8,7 +8,7 @@ int main() + + rs = 0x80001234; + rt = 0x80004321; +- result = 0x80005555; ++ result = 0x7FFFAAAB; + + __asm + ("mulq_rs.w %0, %1, %2\n\t" +diff --git a/tests/tcg/mips/mips32-dspr2/mulq_s_w.c b/tests/tcg/mips/mips32-dspr2/mulq_s_w.c +index df148b7..9c2be06 100644 +--- a/tests/tcg/mips/mips32-dspr2/mulq_s_w.c ++++ b/tests/tcg/mips/mips32-dspr2/mulq_s_w.c +@@ -8,7 +8,7 @@ int main() + + rs = 0x80001234; + rt = 0x80004321; +- result = 0x80005555; ++ result = 0x7FFFAAAB; + + __asm + ("mulq_s.w %0, %1, %2\n\t" +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0045-target-mips-fix-DSP-overflow-macro-and-affected-rout.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0045-target-mips-fix-DSP-overflow-macro-and-affected-rout.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0045-target-mips-fix-DSP-overflow-macro-and-affected-rout.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0045-target-mips-fix-DSP-overflow-macro-and-affected-rout.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,307 @@ +From dac077f0e6f02791d4206aa05e034b6ebbce0ba7 Mon Sep 17 00:00:00 2001 +From: Petar Jovanovic +Date: Mon, 25 Feb 2013 16:45:40 +0100 +Subject: [PATCH 45/54] target-mips: fix DSP overflow macro and affected + routines + +The previous implementation incorrectly used same macro to detect overflow +for addition and subtraction. This patch makes distinction between these +two, and creates separate macros. The affected routines are changed +accordingly. + +This change also includes additions to the existing tests for SUBQ_S_PH and +SUBQ_S_W that would trigger the fixed issue, and it removes dead code from +the test file. The last test case in subq_s_w.c is a bug found/reported/ +isolated by Klaus Peichl from Dolby. + +Signed-off-by: Petar Jovanovic +Signed-off-by: Aurelien Jarno +(cherry picked from commit 20c334a797bf46a4ee59a6e42be6d5e7c3cda585) + +Signed-off-by: Michael Roth +--- + target-mips/dsp_helper.c | 90 +++++++++++++++++++---------------- + tests/tcg/mips/mips32-dsp/subq_s_ph.c | 22 ++++++++- + tests/tcg/mips/mips32-dsp/subq_s_w.c | 36 ++++++++++---- + 3 files changed, 94 insertions(+), 54 deletions(-) + +diff --git a/target-mips/dsp_helper.c b/target-mips/dsp_helper.c +index 841f47b..ffa9396 100644 +--- a/target-mips/dsp_helper.c ++++ b/target-mips/dsp_helper.c +@@ -44,7 +44,8 @@ typedef union { + + /*** MIPS DSP internal functions begin ***/ + #define MIPSDSP_ABS(x) (((x) >= 0) ? x : -x) +-#define MIPSDSP_OVERFLOW(a, b, c, d) (!(!((a ^ b ^ -1) & (a ^ c) & d))) ++#define MIPSDSP_OVERFLOW_ADD(a, b, c, d) (~(a ^ b) & (a ^ c) & d) ++#define MIPSDSP_OVERFLOW_SUB(a, b, c, d) ((a ^ b) & (a ^ c) & d) + + static inline void set_DSPControl_overflow_flag(uint32_t flag, int position, + CPUMIPSState *env) +@@ -142,7 +143,7 @@ static inline int16_t mipsdsp_add_i16(int16_t a, int16_t b, CPUMIPSState *env) + + tempI = a + b; + +- if (MIPSDSP_OVERFLOW(a, b, tempI, 0x8000)) { ++ if (MIPSDSP_OVERFLOW_ADD(a, b, tempI, 0x8000)) { + set_DSPControl_overflow_flag(1, 20, env); + } + +@@ -156,7 +157,7 @@ static inline int16_t mipsdsp_sat_add_i16(int16_t a, int16_t b, + + tempS = a + b; + +- if (MIPSDSP_OVERFLOW(a, b, tempS, 0x8000)) { ++ if (MIPSDSP_OVERFLOW_ADD(a, b, tempS, 0x8000)) { + if (a > 0) { + tempS = 0x7FFF; + } else { +@@ -175,7 +176,7 @@ static inline int32_t mipsdsp_sat_add_i32(int32_t a, int32_t b, + + tempI = a + b; + +- if (MIPSDSP_OVERFLOW(a, b, tempI, 0x80000000)) { ++ if (MIPSDSP_OVERFLOW_ADD(a, b, tempI, 0x80000000)) { + if (a > 0) { + tempI = 0x7FFFFFFF; + } else { +@@ -858,7 +859,7 @@ static inline uint16_t mipsdsp_sub_i16(int16_t a, int16_t b, CPUMIPSState *env) + int16_t temp; + + temp = a - b; +- if (MIPSDSP_OVERFLOW(a, -b, temp, 0x8000)) { ++ if (MIPSDSP_OVERFLOW_SUB(a, b, temp, 0x8000)) { + set_DSPControl_overflow_flag(1, 20, env); + } + +@@ -871,8 +872,8 @@ static inline uint16_t mipsdsp_sat16_sub(int16_t a, int16_t b, + int16_t temp; + + temp = a - b; +- if (MIPSDSP_OVERFLOW(a, -b, temp, 0x8000)) { +- if (a > 0) { ++ if (MIPSDSP_OVERFLOW_SUB(a, b, temp, 0x8000)) { ++ if (a >= 0) { + temp = 0x7FFF; + } else { + temp = 0x8000; +@@ -889,8 +890,8 @@ static inline uint32_t mipsdsp_sat32_sub(int32_t a, int32_t b, + int32_t temp; + + temp = a - b; +- if (MIPSDSP_OVERFLOW(a, -b, temp, 0x80000000)) { +- if (a > 0) { ++ if (MIPSDSP_OVERFLOW_SUB(a, b, temp, 0x80000000)) { ++ if (a >= 0) { + temp = 0x7FFFFFFF; + } else { + temp = 0x80000000; +@@ -1004,7 +1005,7 @@ static inline uint32_t mipsdsp_sub32(int32_t a, int32_t b, CPUMIPSState *env) + int32_t temp; + + temp = a - b; +- if (MIPSDSP_OVERFLOW(a, -b, temp, 0x80000000)) { ++ if (MIPSDSP_OVERFLOW_SUB(a, b, temp, 0x80000000)) { + set_DSPControl_overflow_flag(1, 20, env); + } + +@@ -1017,7 +1018,7 @@ static inline int32_t mipsdsp_add_i32(int32_t a, int32_t b, CPUMIPSState *env) + + temp = a + b; + +- if (MIPSDSP_OVERFLOW(a, b, temp, 0x80000000)) { ++ if (MIPSDSP_OVERFLOW_ADD(a, b, temp, 0x80000000)) { + set_DSPControl_overflow_flag(1, 20, env); + } + +@@ -2488,37 +2489,42 @@ DP_QH(dpsq_s_w_qh, 0, 1); + #endif + + #define DP_L_W(name, is_add) \ +-void helper_##name(uint32_t ac, target_ulong rs, target_ulong rt, \ +- CPUMIPSState *env) \ +-{ \ +- int32_t temp63; \ +- int64_t dotp, acc; \ +- uint64_t temp; \ +- \ +- dotp = mipsdsp_mul_q31_q31(ac, rs, rt, env); \ +- acc = ((uint64_t)env->active_tc.HI[ac] << 32) | \ +- ((uint64_t)env->active_tc.LO[ac] & MIPSDSP_LLO); \ +- if (!is_add) { \ +- dotp = -dotp; \ +- } \ +- \ +- temp = acc + dotp; \ +- if (MIPSDSP_OVERFLOW((uint64_t)acc, (uint64_t)dotp, temp, \ +- (0x01ull << 63))) { \ +- temp63 = (temp >> 63) & 0x01; \ +- if (temp63 == 1) { \ +- temp = (0x01ull << 63) - 1; \ +- } else { \ +- temp = 0x01ull << 63; \ +- } \ +- \ +- set_DSPControl_overflow_flag(1, 16 + ac, env); \ +- } \ +- \ +- env->active_tc.HI[ac] = (target_long)(int32_t) \ +- ((temp & MIPSDSP_LHI) >> 32); \ +- env->active_tc.LO[ac] = (target_long)(int32_t) \ +- (temp & MIPSDSP_LLO); \ ++void helper_##name(uint32_t ac, target_ulong rs, target_ulong rt, \ ++ CPUMIPSState *env) \ ++{ \ ++ int32_t temp63; \ ++ int64_t dotp, acc; \ ++ uint64_t temp; \ ++ bool overflow; \ ++ \ ++ dotp = mipsdsp_mul_q31_q31(ac, rs, rt, env); \ ++ acc = ((uint64_t)env->active_tc.HI[ac] << 32) | \ ++ ((uint64_t)env->active_tc.LO[ac] & MIPSDSP_LLO); \ ++ if (is_add) { \ ++ temp = acc + dotp; \ ++ overflow = MIPSDSP_OVERFLOW_ADD((uint64_t)acc, (uint64_t)dotp, \ ++ temp, (0x01ull << 63)); \ ++ } else { \ ++ temp = acc - dotp; \ ++ overflow = MIPSDSP_OVERFLOW_SUB((uint64_t)acc, (uint64_t)dotp, \ ++ temp, (0x01ull << 63)); \ ++ } \ ++ \ ++ if (overflow) { \ ++ temp63 = (temp >> 63) & 0x01; \ ++ if (temp63 == 1) { \ ++ temp = (0x01ull << 63) - 1; \ ++ } else { \ ++ temp = 0x01ull << 63; \ ++ } \ ++ \ ++ set_DSPControl_overflow_flag(1, 16 + ac, env); \ ++ } \ ++ \ ++ env->active_tc.HI[ac] = (target_long)(int32_t) \ ++ ((temp & MIPSDSP_LHI) >> 32); \ ++ env->active_tc.LO[ac] = (target_long)(int32_t) \ ++ (temp & MIPSDSP_LLO); \ + } + + DP_L_W(dpaq_sa_l_w, 1); +diff --git a/tests/tcg/mips/mips32-dsp/subq_s_ph.c b/tests/tcg/mips/mips32-dsp/subq_s_ph.c +index 8e36dad..64c89eb 100644 +--- a/tests/tcg/mips/mips32-dsp/subq_s_ph.c ++++ b/tests/tcg/mips/mips32-dsp/subq_s_ph.c +@@ -12,7 +12,8 @@ int main() + resultdsp = 0x01; + + __asm +- ("subq_s.ph %0, %2, %3\n\t" ++ ("wrdsp $0\n\t" ++ "subq_s.ph %0, %2, %3\n\t" + "rddsp %1\n\t" + : "=r"(rd), "=r"(dsp) + : "r"(rs), "r"(rt) +@@ -27,7 +28,24 @@ int main() + resultdsp = 0x01; + + __asm +- ("subq_s.ph %0, %2, %3\n\t" ++ ("wrdsp $0\n\t" ++ "subq_s.ph %0, %2, %3\n\t" ++ "rddsp %1\n\t" ++ : "=r"(rd), "=r"(dsp) ++ : "r"(rs), "r"(rt) ++ ); ++ dsp = (dsp >> 20) & 0x01; ++ assert(dsp == resultdsp); ++ assert(rd == result); ++ ++ rs = 0x12340000; ++ rt = 0x87658000; ++ result = 0x7FFF7FFF; ++ resultdsp = 0x01; ++ ++ __asm ++ ("wrdsp $0\n\t" ++ "subq_s.ph %0, %2, %3\n\t" + "rddsp %1\n\t" + : "=r"(rd), "=r"(dsp) + : "r"(rs), "r"(rt) +diff --git a/tests/tcg/mips/mips32-dsp/subq_s_w.c b/tests/tcg/mips/mips32-dsp/subq_s_w.c +index 09022e9..9d456a9 100644 +--- a/tests/tcg/mips/mips32-dsp/subq_s_w.c ++++ b/tests/tcg/mips/mips32-dsp/subq_s_w.c +@@ -12,7 +12,8 @@ int main() + resultdsp = 0x01; + + __asm +- ("subq_s.w %0, %2, %3\n\t" ++ ("wrdsp $0\n\t" ++ "subq_s.w %0, %2, %3\n\t" + "rddsp %1\n\t" + : "=r"(rd), "=r"(dsp) + : "r"(rs), "r"(rt) +@@ -24,10 +25,11 @@ int main() + rs = 0x66666; + rt = 0x55555; + result = 0x11111; +- resultdsp = 0x01; ++ resultdsp = 0x0; + + __asm +- ("subq_s.w %0, %2, %3\n\t" ++ ("wrdsp $0\n\t" ++ "subq_s.w %0, %2, %3\n\t" + "rddsp %1\n\t" + : "=r"(rd), "=r"(dsp) + : "r"(rs), "r"(rt) +@@ -36,23 +38,37 @@ int main() + assert(dsp == resultdsp); + assert(rd == result); + +- +-#if 0 +- rs = 0x35555555; +- rt = 0xf5555555; +- result = 0x80000000; ++ rs = 0x0; ++ rt = 0x80000000; ++ result = 0x7FFFFFFF; + resultdsp = 0x01; + + __asm +- ("subq_s.w %0, %2, %3\n\t" ++ ("wrdsp $0\n\t" ++ "subq_s.w %0, %2, %3\n\t" + "rddsp %1\n\t" + : "=r"(rd), "=r"(dsp) + : "r"(rs), "r"(rt) + ); ++ dsp = (dsp >> 20) & 0x01; ++ assert(dsp == resultdsp); ++ assert(rd == result); ++ ++ rs = 0x80000000; ++ rt = 0x80000000; ++ result = 0; ++ resultdsp = 0x00; + ++ __asm ++ ("wrdsp $0\n\t" ++ "subq_s.w %0, %2, %3\n\t" ++ "rddsp %1\n\t" ++ : "=r"(rd), "=r"(dsp) ++ : "r"(rs), "r"(rt) ++ ); + dsp = (dsp >> 20) & 0x01; + assert(dsp == resultdsp); + assert(rd == result); +-#endif ++ + return 0; + } +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0046-target-mips-fix-rndrashift_short_acc-and-code-for-EX.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0046-target-mips-fix-rndrashift_short_acc-and-code-for-EX.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0046-target-mips-fix-rndrashift_short_acc-and-code-for-EX.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0046-target-mips-fix-rndrashift_short_acc-and-code-for-EX.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,206 @@ +From d019dd928c68038c539fa0a5ba92f046fed12a6c Mon Sep 17 00:00:00 2001 +From: Petar Jovanovic +Date: Fri, 15 Mar 2013 18:56:19 +0100 +Subject: [PATCH 46/54] target-mips: fix rndrashift_short_acc and code for + EXTR_ instructions + +Fix for rndrashift_short_acc to set correct value to higher 64 bits. +This change also corrects conditions when bit 23 of the DSPControl register +is set. + +The existing test files have been extended with several examples that +trigger the issues. One bug/example in the test file for EXTR_RS_W has been +found and reported by Klaus Peichl. + +Signed-off-by: Petar Jovanovic +Signed-off-by: Aurelien Jarno +(cherry picked from commit 8b758d0568a986d58c254b3c209691c82e0f82a1) + +Signed-off-by: Michael Roth +--- + target-mips/dsp_helper.c | 23 +++++++----------- + tests/tcg/mips/mips32-dsp/extr_r_w.c | 23 ++++++++++++++++++ + tests/tcg/mips/mips32-dsp/extr_rs_w.c | 46 +++++++++++++++++++++++++++++++++++ + tests/tcg/mips/mips32-dsp/extr_w.c | 23 ++++++++++++++++++ + 4 files changed, 101 insertions(+), 14 deletions(-) + +diff --git a/target-mips/dsp_helper.c b/target-mips/dsp_helper.c +index ffa9396..550f4a1 100644 +--- a/target-mips/dsp_helper.c ++++ b/target-mips/dsp_helper.c +@@ -517,13 +517,8 @@ static inline void mipsdsp_rndrashift_short_acc(int64_t *p, + + acc = ((int64_t)env->active_tc.HI[ac] << 32) | + ((int64_t)env->active_tc.LO[ac] & 0xFFFFFFFF); +- if (shift == 0) { +- p[0] = acc << 1; +- p[1] = (acc >> 63) & 0x01; +- } else { +- p[0] = acc >> (shift - 1); +- p[1] = 0; +- } ++ p[0] = (shift == 0) ? (acc << 1) : (acc >> (shift - 1)); ++ p[1] = (acc >> 63) & 0x01; + } + + /* 128 bits long. p[0] is LO, p[1] is HI */ +@@ -3161,8 +3156,8 @@ target_ulong helper_extr_w(target_ulong ac, target_ulong shift, + tempDL[1] += 1; + } + +- if ((!(tempDL[1] == 0 && (tempDL[0] & MIPSDSP_LHI) == 0x00)) && +- (!(tempDL[1] == 1 && (tempDL[0] & MIPSDSP_LHI) == MIPSDSP_LHI))) { ++ if (((tempDL[1] & 0x01) != 0 || (tempDL[0] & MIPSDSP_LHI) != 0) && ++ ((tempDL[1] & 0x01) != 1 || (tempDL[0] & MIPSDSP_LHI) != MIPSDSP_LHI)) { + set_DSPControl_overflow_flag(1, 23, env); + } + +@@ -3187,8 +3182,8 @@ target_ulong helper_extr_r_w(target_ulong ac, target_ulong shift, + tempDL[1] += 1; + } + +- if ((tempDL[1] != 0 || (tempDL[0] & MIPSDSP_LHI) != 0) && +- (tempDL[1] != 1 && (tempDL[0] & MIPSDSP_LHI) != MIPSDSP_LHI)) { ++ if (((tempDL[1] & 0x01) != 0 || (tempDL[0] & MIPSDSP_LHI) != 0) && ++ ((tempDL[1] & 0x01) != 1 || (tempDL[0] & MIPSDSP_LHI) != MIPSDSP_LHI)) { + set_DSPControl_overflow_flag(1, 23, env); + } + +@@ -3214,9 +3209,9 @@ target_ulong helper_extr_rs_w(target_ulong ac, target_ulong shift, + } + tempI = tempDL[0] >> 1; + +- if ((tempDL[1] != 0 || (tempDL[0] & MIPSDSP_LHI) != 0) && +- (tempDL[1] != 1 || (tempDL[0] & MIPSDSP_LHI) != MIPSDSP_LHI)) { +- temp64 = tempDL[1]; ++ if (((tempDL[1] & 0x01) != 0 || (tempDL[0] & MIPSDSP_LHI) != 0) && ++ ((tempDL[1] & 0x01) != 1 || (tempDL[0] & MIPSDSP_LHI) != MIPSDSP_LHI)) { ++ temp64 = tempDL[1] & 0x01; + if (temp64 == 0) { + tempI = 0x7FFFFFFF; + } else { +diff --git a/tests/tcg/mips/mips32-dsp/extr_r_w.c b/tests/tcg/mips/mips32-dsp/extr_r_w.c +index 02e0224..489c193 100644 +--- a/tests/tcg/mips/mips32-dsp/extr_r_w.c ++++ b/tests/tcg/mips/mips32-dsp/extr_r_w.c +@@ -67,5 +67,28 @@ int main() + assert(dsp == 0); + assert(result == rt); + ++ /* Clear dspcontrol */ ++ dsp = 0; ++ __asm ++ ("wrdsp %0\n\t" ++ : ++ : "r"(dsp) ++ ); ++ ++ ach = 0xFFFFFFFF; ++ acl = 0xFFFFFFFF; ++ result = 0; ++ __asm ++ ("mthi %2, $ac1\n\t" ++ "mtlo %3, $ac1\n\t" ++ "extr_r.w %0, $ac1, 0x1F\n\t" ++ "rddsp %1\n\t" ++ : "=r"(rt), "=r"(dsp) ++ : "r"(ach), "r"(acl) ++ ); ++ dsp = (dsp >> 23) & 0x01; ++ assert(dsp == 0); ++ assert(result == rt); ++ + return 0; + } +diff --git a/tests/tcg/mips/mips32-dsp/extr_rs_w.c b/tests/tcg/mips/mips32-dsp/extr_rs_w.c +index c3a22ee..f9d2ed6 100644 +--- a/tests/tcg/mips/mips32-dsp/extr_rs_w.c ++++ b/tests/tcg/mips/mips32-dsp/extr_rs_w.c +@@ -67,5 +67,51 @@ int main() + assert(dsp == 0); + assert(result == rt); + ++ /* Clear dspcontrol */ ++ dsp = 0; ++ __asm ++ ("wrdsp %0\n\t" ++ : ++ : "r"(dsp) ++ ); ++ ++ ach = 0x80000000; ++ acl = 0x00000000; ++ result = 0x80000000; ++ __asm ++ ("mthi %2, $ac1\n\t" ++ "mtlo %3, $ac1\n\t" ++ "extr_rs.w %0, $ac1, 0x1F\n\t" ++ "rddsp %1\n\t" ++ : "=r"(rt), "=r"(dsp) ++ : "r"(ach), "r"(acl) ++ ); ++ dsp = (dsp >> 23) & 0x01; ++ assert(dsp == 1); ++ assert(result == rt); ++ ++ /* Clear dspcontrol */ ++ dsp = 0; ++ __asm ++ ("wrdsp %0\n\t" ++ : ++ : "r"(dsp) ++ ); ++ ++ ach = 0xFFFFFFFF; ++ acl = 0xFFFFFFFF; ++ result = 0; ++ __asm ++ ("mthi %2, $ac1\n\t" ++ "mtlo %3, $ac1\n\t" ++ "extr_rs.w %0, $ac1, 0x1F\n\t" ++ "rddsp %1\n\t" ++ : "=r"(rt), "=r"(dsp) ++ : "r"(ach), "r"(acl) ++ ); ++ dsp = (dsp >> 23) & 0x01; ++ assert(dsp == 0); ++ assert(result == rt); ++ + return 0; + } +diff --git a/tests/tcg/mips/mips32-dsp/extr_w.c b/tests/tcg/mips/mips32-dsp/extr_w.c +index bd6b0b9..cf92614 100644 +--- a/tests/tcg/mips/mips32-dsp/extr_w.c ++++ b/tests/tcg/mips/mips32-dsp/extr_w.c +@@ -67,5 +67,28 @@ int main() + assert(dsp == 0); + assert(result == rt); + ++ /* Clear dspcontrol */ ++ dsp = 0; ++ __asm ++ ("wrdsp %0\n\t" ++ : ++ : "r"(dsp) ++ ); ++ ++ ach = 0xFFFFFFFF; ++ acl = 0xFFFFFFFF; ++ result = 0xFFFFFFFF; ++ __asm ++ ("mthi %2, $ac1\n\t" ++ "mtlo %3, $ac1\n\t" ++ "extr.w %0, $ac1, 0x1F\n\t" ++ "rddsp %1\n\t" ++ : "=r"(rt), "=r"(dsp) ++ : "r"(ach), "r"(acl) ++ ); ++ dsp = (dsp >> 23) & 0x01; ++ assert(dsp == 0); ++ assert(result == rt); ++ + return 0; + } +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0047-acpi-initialize-s4_val-used-in-s4-shutdown.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0047-acpi-initialize-s4_val-used-in-s4-shutdown.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0047-acpi-initialize-s4_val-used-in-s4-shutdown.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0047-acpi-initialize-s4_val-used-in-s4-shutdown.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,95 @@ +From 888e036eb4f03ec266be05cec3d047488dcaa165 Mon Sep 17 00:00:00 2001 +From: Bruce Rogers +Date: Tue, 2 Apr 2013 12:41:40 -0600 +Subject: [PATCH 47/54] acpi: initialize s4_val used in s4 shutdown + +While investigating why a 32 bit Windows 2003 guest wasn't able to +successfully perform a shutdown /h, it was discovered that commit +afafe4bbe0cf7d3318e1ac7b40925561f86a6bd4 inadvertently dropped the +initialization of the s4_val used to handle s4 shutdown. +Initialize the value as before. + +Signed-off-by: Bruce Rogers +Message-id: 1364928100-487-1-git-send-email-brogers@suse.com +Signed-off-by: Anthony Liguori +(cherry picked from commit 560e63965232e37d1916a447125cf91c18a96930) + +Signed-off-by: Michael Roth +--- + hw/acpi.c | 3 ++- + hw/acpi.h | 2 +- + hw/acpi_ich9.c | 2 +- + hw/acpi_piix4.c | 2 +- + hw/vt82c686.c | 2 +- + 5 files changed, 6 insertions(+), 5 deletions(-) + +diff --git a/hw/acpi.c b/hw/acpi.c +index 8c9dcc5..a83c4ea 100644 +--- a/hw/acpi.c ++++ b/hw/acpi.c +@@ -472,8 +472,9 @@ static const MemoryRegionOps acpi_pm_cnt_ops = { + .endianness = DEVICE_LITTLE_ENDIAN, + }; + +-void acpi_pm1_cnt_init(ACPIREGS *ar, MemoryRegion *parent) ++void acpi_pm1_cnt_init(ACPIREGS *ar, MemoryRegion *parent, uint8_t s4_val) + { ++ ar->pm1.cnt.s4_val = s4_val; + ar->wakeup.notify = acpi_notify_wakeup; + qemu_register_wakeup_notifier(&ar->wakeup); + memory_region_init_io(&ar->pm1.cnt.io, &acpi_pm_cnt_ops, ar, "acpi-cnt", 2); +diff --git a/hw/acpi.h b/hw/acpi.h +index c3628d0..e18ef28 100644 +--- a/hw/acpi.h ++++ b/hw/acpi.h +@@ -142,7 +142,7 @@ void acpi_pm1_evt_init(ACPIREGS *ar, acpi_update_sci_fn update_sci, + MemoryRegion *parent); + + /* PM1a_CNT: piix and ich9 don't implement PM1b CNT. */ +-void acpi_pm1_cnt_init(ACPIREGS *ar, MemoryRegion *parent); ++void acpi_pm1_cnt_init(ACPIREGS *ar, MemoryRegion *parent, uint8_t s4_val); + void acpi_pm1_cnt_update(ACPIREGS *ar, + bool sci_enable, bool sci_disable); + void acpi_pm1_cnt_reset(ACPIREGS *ar); +diff --git a/hw/acpi_ich9.c b/hw/acpi_ich9.c +index d2f9808..fe385e9 100644 +--- a/hw/acpi_ich9.c ++++ b/hw/acpi_ich9.c +@@ -212,7 +212,7 @@ void ich9_pm_init(PCIDevice *lpc_pci, ICH9LPCPMRegs *pm, + + acpi_pm_tmr_init(&pm->acpi_regs, ich9_pm_update_sci_fn, &pm->io); + acpi_pm1_evt_init(&pm->acpi_regs, ich9_pm_update_sci_fn, &pm->io); +- acpi_pm1_cnt_init(&pm->acpi_regs, &pm->io); ++ acpi_pm1_cnt_init(&pm->acpi_regs, &pm->io, 2); + + acpi_gpe_init(&pm->acpi_regs, ICH9_PMIO_GPE0_LEN); + memory_region_init_io(&pm->io_gpe, &ich9_gpe_ops, pm, "apci-gpe0", +diff --git a/hw/acpi_piix4.c b/hw/acpi_piix4.c +index 65b2601..1beac21 100644 +--- a/hw/acpi_piix4.c ++++ b/hw/acpi_piix4.c +@@ -418,7 +418,7 @@ static int piix4_pm_initfn(PCIDevice *dev) + + acpi_pm_tmr_init(&s->ar, pm_tmr_timer, &s->io); + acpi_pm1_evt_init(&s->ar, pm_tmr_timer, &s->io); +- acpi_pm1_cnt_init(&s->ar, &s->io); ++ acpi_pm1_cnt_init(&s->ar, &s->io, s->s4_val); + acpi_gpe_init(&s->ar, GPE_LEN); + + s->powerdown_notifier.notify = piix4_pm_powerdown_req; +diff --git a/hw/vt82c686.c b/hw/vt82c686.c +index 2d8e398..9823f8a 100644 +--- a/hw/vt82c686.c ++++ b/hw/vt82c686.c +@@ -362,7 +362,7 @@ static int vt82c686b_pm_initfn(PCIDevice *dev) + + acpi_pm_tmr_init(&s->ar, pm_tmr_timer, &s->io); + acpi_pm1_evt_init(&s->ar, pm_tmr_timer, &s->io); +- acpi_pm1_cnt_init(&s->ar, &s->io); ++ acpi_pm1_cnt_init(&s->ar, &s->io, 2); + + return 0; + } +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0048-doc-Fix-texinfo-table-markup-in-qemu-options.hx.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0048-doc-Fix-texinfo-table-markup-in-qemu-options.hx.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0048-doc-Fix-texinfo-table-markup-in-qemu-options.hx.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0048-doc-Fix-texinfo-table-markup-in-qemu-options.hx.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,213 @@ +From 65fe29ec000bd3d5b8fd4d15c2379fe6c24dae94 Mon Sep 17 00:00:00 2001 +From: Markus Armbruster +Date: Wed, 13 Feb 2013 19:49:40 +0100 +Subject: [PATCH 48/54] doc: Fix texinfo @table markup in qemu-options.hx + +End tables before headings, start new ones afterwards. Fixes +incorrect indentation of headings "File system options" and "Virtual +File system pass-through options" in manual page and qemu-doc. + +Normalize markup some to increase chances it survives future edits. + +Signed-off-by: Markus Armbruster +Reviewed-by: Stefan Hajnoczi +Message-id: 1360781383-28635-5-git-send-email-armbru@redhat.com +Signed-off-by: Anthony Liguori +(cherry picked from commit c70a01e449536c616c85ab820c6fbad7d7e9cf39) + +Signed-off-by: Michael Roth +--- + qemu-options.hx | 56 +++++++++++++++++++++++++++++++++++++------------------- + 1 file changed, 37 insertions(+), 19 deletions(-) + +diff --git a/qemu-options.hx b/qemu-options.hx +index be21048..14fb84b 100644 +--- a/qemu-options.hx ++++ b/qemu-options.hx +@@ -537,13 +537,15 @@ STEXI + @end table + ETEXI + +-DEF("usb", 0, QEMU_OPTION_usb, +- "-usb enable the USB driver (will be the default soon)\n", +- QEMU_ARCH_ALL) + STEXI + USB options: + @table @option ++ETEXI + ++DEF("usb", 0, QEMU_OPTION_usb, ++ "-usb enable the USB driver (will be the default soon)\n", ++ QEMU_ARCH_ALL) ++STEXI + @item -usb + @findex -usb + Enable the USB driver (will be the default soon) +@@ -610,9 +612,15 @@ possible drivers and properties, use @code{-device help} and + @code{-device @var{driver},help}. + ETEXI + ++STEXI ++@end table ++ETEXI + DEFHEADING() + + DEFHEADING(File system options:) ++STEXI ++@table @option ++ETEXI + + DEF("fsdev", HAS_ARG, QEMU_OPTION_fsdev, + "-fsdev fsdriver,id=id[,path=path,][security_model={mapped-xattr|mapped-file|passthrough|none}]\n" +@@ -676,9 +684,15 @@ Specifies the tag name to be used by the guest to mount this export point + + ETEXI + ++STEXI ++@end table ++ETEXI + DEFHEADING() + + DEFHEADING(Virtual File system pass-through options:) ++STEXI ++@table @option ++ETEXI + + DEF("virtfs", HAS_ARG, QEMU_OPTION_virtfs, + "-virtfs local,path=path,mount_tag=tag,security_model=[mapped-xattr|mapped-file|passthrough|none]\n" +@@ -769,11 +783,9 @@ ETEXI + STEXI + @end table + ETEXI +- + DEFHEADING() + + DEFHEADING(Display options:) +- + STEXI + @table @option + ETEXI +@@ -1215,7 +1227,6 @@ ETEXI + STEXI + @end table + ETEXI +- + ARCHHEADING(, QEMU_ARCH_I386) + + ARCHHEADING(i386 target only:, QEMU_ARCH_I386) +@@ -1301,10 +1312,10 @@ Specify SMBIOS type 0 fields + Specify SMBIOS type 1 fields + ETEXI + +-DEFHEADING() + STEXI + @end table + ETEXI ++DEFHEADING() + + DEFHEADING(Network options:) + STEXI +@@ -1720,13 +1731,19 @@ libpcap, so it can be analyzed with tools such as tcpdump or Wireshark. + Indicate that no network devices should be configured. It is used to + override the default configuration (@option{-net nic -net user}) which + is activated if no @option{-net} options are provided. ++ETEXI + ++STEXI + @end table + ETEXI +- + DEFHEADING() + + DEFHEADING(Character device options:) ++STEXI ++ ++The general form of a character device option is: ++@table @option ++ETEXI + + DEF("chardev", HAS_ARG, QEMU_OPTION_chardev, + "-chardev null,id=id[,mux=on|off]\n" +@@ -1768,10 +1785,6 @@ DEF("chardev", HAS_ARG, QEMU_OPTION_chardev, + ) + + STEXI +- +-The general form of a character device option is: +-@table @option +- + @item -chardev @var{backend} ,id=@var{id} [,mux=on|off] [,@var{options}] + @findex -chardev + Backend is one of: +@@ -1992,14 +2005,15 @@ Connect to a spice virtual machine channel, such as vdiport. + + Connect to a spice port, allowing a Spice client to handle the traffic + identified by a name (preferably a fqdn). ++ETEXI + ++STEXI + @end table + ETEXI +- + DEFHEADING() + +-STEXI + DEFHEADING(Device URL Syntax:) ++STEXI + + In addition to using normal file images for the emulated storage devices, + QEMU can also use networked resources such as iSCSI devices. These are +@@ -2115,10 +2129,16 @@ qemu-system-x86_84 --drive file=gluster://192.0.2.1/testvol/a.img + @end example + + See also @url{http://www.gluster.org}. ++ETEXI ++ ++STEXI + @end table + ETEXI + + DEFHEADING(Bluetooth(R) options:) ++STEXI ++@table @option ++ETEXI + + DEF("bt", HAS_ARG, QEMU_OPTION_bt, \ + "-bt hci,null dumb bluetooth HCI - doesn't respond to commands\n" \ +@@ -2132,8 +2152,6 @@ DEF("bt", HAS_ARG, QEMU_OPTION_bt, \ + " emulate a bluetooth device 'dev' in scatternet 'n'\n", + QEMU_ARCH_ALL) + STEXI +-@table @option +- + @item -bt hci[...] + @findex -bt + Defines the function of the corresponding Bluetooth HCI. -bt options +@@ -2185,9 +2203,11 @@ currently: + @item keyboard + Virtual wireless keyboard implementing the HIDP bluetooth profile. + @end table +-@end table + ETEXI + ++STEXI ++@end table ++ETEXI + DEFHEADING() + + DEFHEADING(Linux/Multiboot boot specific:) +@@ -2244,11 +2264,9 @@ ETEXI + STEXI + @end table + ETEXI +- + DEFHEADING() + + DEFHEADING(Debug/Expert options:) +- + STEXI + @table @option + ETEXI +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0049-qxl-better-vga-init-in-enter_vga_mode.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0049-qxl-better-vga-init-in-enter_vga_mode.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0049-qxl-better-vga-init-in-enter_vga_mode.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0049-qxl-better-vga-init-in-enter_vga_mode.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,33 @@ +From d15b1aa30c8b57e89beb41d67cd87cd4fbaacd8c Mon Sep 17 00:00:00 2001 +From: Gerd Hoffmann +Date: Thu, 28 Feb 2013 11:08:50 +0100 +Subject: [PATCH 49/54] qxl: better vga init in enter_vga_mode + +Ask the vga core to update the display. Will trigger dpy_gfx_resize +if needed. More complete than just calling dpy_gfx_resize. + +Signed-off-by: Gerd Hoffmann +(cherry picked from commit c099e7aa0295678859d58e9e60b7619f6ae3bac8) + +Signed-off-by: Michael Roth +--- + hw/qxl.c | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/hw/qxl.c b/hw/qxl.c +index 2e1c5e2..ca094e6 100644 +--- a/hw/qxl.c ++++ b/hw/qxl.c +@@ -1075,8 +1075,8 @@ static void qxl_enter_vga_mode(PCIQXLDevice *d) + trace_qxl_enter_vga_mode(d->id); + qemu_spice_create_host_primary(&d->ssd); + d->mode = QXL_MODE_VGA; +- dpy_gfx_resize(d->ssd.ds); + vga_dirty_log_start(&d->vga); ++ vga_hw_update(); + } + + static void qxl_exit_vga_mode(PCIQXLDevice *d) +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0050-Revert-block-complete-all-IOs-before-.bdrv_truncate.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0050-Revert-block-complete-all-IOs-before-.bdrv_truncate.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0050-Revert-block-complete-all-IOs-before-.bdrv_truncate.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0050-Revert-block-complete-all-IOs-before-.bdrv_truncate.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,37 @@ +From e4cce2d3e9dbdb1c82994f024c0c7e2d2661547e Mon Sep 17 00:00:00 2001 +From: Peter Lieven +Date: Mon, 11 Mar 2013 11:03:28 +0100 +Subject: [PATCH 50/54] Revert "block: complete all IOs before .bdrv_truncate" + +brdv_truncate() is also called from readv/writev commands on self- +growing file based storage. this will result in requests waiting +for theirselves to complete. + +This reverts commit 9a665b2b8640e464f0a778216fc2dca8d02acf33. + +Signed-off-by: Kevin Wolf +(cherry picked from commit 5c916681ae2383f0425bb8a3680ade9d055f5dfe) + +Signed-off-by: Michael Roth +--- + block.c | 4 ---- + 1 file changed, 4 deletions(-) + +diff --git a/block.c b/block.c +index 11f162b..50dab8e 100644 +--- a/block.c ++++ b/block.c +@@ -2427,10 +2427,6 @@ int bdrv_truncate(BlockDriverState *bs, int64_t offset) + return -EACCES; + if (bdrv_in_use(bs)) + return -EBUSY; +- +- /* There better not be any in-flight IOs when we truncate the device. */ +- bdrv_drain_all(); +- + ret = drv->bdrv_truncate(bs, offset); + if (ret == 0) { + ret = refresh_total_sectors(bs, offset >> BDRV_SECTOR_BITS); +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0051-block-complete-all-IOs-before-resizing-a-device.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0051-block-complete-all-IOs-before-resizing-a-device.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0051-block-complete-all-IOs-before-resizing-a-device.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0051-block-complete-all-IOs-before-resizing-a-device.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,36 @@ +From 2b92aa36d112780674d5686ad9c98e8cfe68d207 Mon Sep 17 00:00:00 2001 +From: Peter Lieven +Date: Mon, 11 Mar 2013 11:04:24 +0100 +Subject: [PATCH 51/54] block: complete all IOs before resizing a device + +this patch ensures that all pending IOs are completed +before a device is resized. this is especially important +if a device is shrinked as it the bdrv_check_request() +result is invalidated. + +Signed-off-by: Peter Lieven +Signed-off-by: Kevin Wolf +(cherry picked from commit 92b7a08d64e5e3129fa885f9d180e5bddcb76b42) + +Signed-off-by: Michael Roth +--- + blockdev.c | 3 +++ + 1 file changed, 3 insertions(+) + +diff --git a/blockdev.c b/blockdev.c +index 63e6f1e..4ea2725 100644 +--- a/blockdev.c ++++ b/blockdev.c +@@ -1043,6 +1043,9 @@ void qmp_block_resize(const char *device, int64_t size, Error **errp) + return; + } + ++ /* complete all in-flight operations before resizing the device */ ++ bdrv_drain_all(); ++ + switch (bdrv_truncate(bs, size)) { + case 0: + break; +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0052-compiler-fix-warning-with-GCC-4.8.0.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0052-compiler-fix-warning-with-GCC-4.8.0.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0052-compiler-fix-warning-with-GCC-4.8.0.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0052-compiler-fix-warning-with-GCC-4.8.0.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,46 @@ +From da78a1bc7a6ad2c0653c265a19032540921c15d0 Mon Sep 17 00:00:00 2001 +From: Paolo Bonzini +Date: Wed, 27 Mar 2013 14:34:32 +0100 +Subject: [PATCH 52/54] compiler: fix warning with GCC 4.8.0 +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +GCC 4.8.0 introduces a new warning: + + block/qcow2-snapshot.c: In function 'qcow2_write_snapshots’: + block/qcow2-snapshot.c:252:18: error: typedef 'qemu_build_bug_on__253' + locally defined but not used [-Werror=unused-local-typedefs] + QEMU_BUILD_BUG_ON(offsetof(QCowHeader, snapshots_offset) != + ^ + cc1: all warnings being treated as errors + +(Caret diagnostics aren't perfect yet with macros... :)) Work around it +with __attribute__((unused)). + +Signed-off-by: Paolo Bonzini +Message-id: 1364391272-1128-1-git-send-email-pbonzini@redhat.com +Signed-off-by: Anthony Liguori +(cherry picked from commit 99835e00849369bab726a4dc4ceed1f6f9ed967c) + +Signed-off-by: Michael Roth +--- + include/qemu/compiler.h | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/include/qemu/compiler.h b/include/qemu/compiler.h +index 2f7998b..6175c24 100644 +--- a/include/qemu/compiler.h ++++ b/include/qemu/compiler.h +@@ -33,7 +33,7 @@ + #define cat(x,y) x ## y + #define cat2(x,y) cat(x,y) + #define QEMU_BUILD_BUG_ON(x) \ +- typedef char cat2(qemu_build_bug_on__,__LINE__)[(x)?-1:1]; ++ typedef char cat2(qemu_build_bug_on__,__LINE__)[(x)?-1:1] __attribute__((unused)); + + #if defined __GNUC__ + # if !QEMU_GNUC_PREREQ(4, 4) +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0053-help-add-docs-for-missing-queues-option-of-tap.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0053-help-add-docs-for-missing-queues-option-of-tap.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0053-help-add-docs-for-missing-queues-option-of-tap.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0053-help-add-docs-for-missing-queues-option-of-tap.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,55 @@ +From f85e082a3668dea5ca74759a314e284432f2d46b Mon Sep 17 00:00:00 2001 +From: Jason Wang +Date: Fri, 22 Feb 2013 22:57:52 +0800 +Subject: [PATCH 53/54] help: add docs for missing 'queues' option of tap + +Cc: Markus Armbruster +Cc: qemu-stable@nongnu.org +Signed-off-by: Jason Wang +Message-id: 1361545072-30426-1-git-send-email-jasowang@redhat.com +Signed-off-by: Anthony Liguori +(cherry picked from commit ec3960148f95dd90e94511a6a64838bc3f474bcc) + +Signed-off-by: Michael Roth +--- + qapi-schema.json | 2 ++ + qemu-options.hx | 3 ++- + 2 files changed, 4 insertions(+), 1 deletion(-) + +diff --git a/qapi-schema.json b/qapi-schema.json +index cd7ea25..b3844e6 100644 +--- a/qapi-schema.json ++++ b/qapi-schema.json +@@ -2526,6 +2526,8 @@ + # + # @vhostforce: #optional vhost on for non-MSIX virtio guests + # ++# @queues: #optional number of queues to be created for multiqueue capable tap ++# + # Since 1.2 + ## + { 'type': 'NetdevTapOptions', +diff --git a/qemu-options.hx b/qemu-options.hx +index 14fb84b..15dc29e 100644 +--- a/qemu-options.hx ++++ b/qemu-options.hx +@@ -1349,7 +1349,7 @@ DEF("net", HAS_ARG, QEMU_OPTION_net, + "-net tap[,vlan=n][,name=str],ifname=name\n" + " connect the host TAP network interface to VLAN 'n'\n" + #else +- "-net tap[,vlan=n][,name=str][,fd=h][,fds=x:y:...:z][,ifname=name][,script=file][,downscript=dfile][,helper=helper][,sndbuf=nbytes][,vnet_hdr=on|off][,vhost=on|off][,vhostfd=h][,vhostfds=x:y:...:z][,vhostforce=on|off]\n" ++ "-net tap[,vlan=n][,name=str][,fd=h][,fds=x:y:...:z][,ifname=name][,script=file][,downscript=dfile][,helper=helper][,sndbuf=nbytes][,vnet_hdr=on|off][,vhost=on|off][,vhostfd=h][,vhostfds=x:y:...:z][,vhostforce=on|off][,queues=n]\n" + " connect the host TAP network interface to VLAN 'n'\n" + " use network scripts 'file' (default=" DEFAULT_NETWORK_SCRIPT ")\n" + " to configure it and 'dfile' (default=" DEFAULT_NETWORK_DOWN_SCRIPT ")\n" +@@ -1368,6 +1368,7 @@ DEF("net", HAS_ARG, QEMU_OPTION_net, + " use vhostforce=on to force vhost on for non-MSIX virtio guests\n" + " use 'vhostfd=h' to connect to an already opened vhost net device\n" + " use 'vhostfds=x:y:...:z to connect to multiple already opened vhost net devices\n" ++ " use 'queues=n' to specify the number of queues to be created for multiqueue TAP\n" + "-net bridge[,vlan=n][,name=str][,br=bridge][,helper=helper]\n" + " connects a host TAP network interface to a host bridge device 'br'\n" + " (default=" DEFAULT_BRIDGE_INTERFACE ") using the program 'helper'\n" +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/1.4.1/0054-target-i386-Check-for-host-features-before-filter_fe.patch qemu-1.4.0+dfsg/debian/patches/1.4.1/0054-target-i386-Check-for-host-features-before-filter_fe.patch --- qemu-1.4.0+dfsg/debian/patches/1.4.1/0054-target-i386-Check-for-host-features-before-filter_fe.patch 1970-01-01 00:00:00.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/1.4.1/0054-target-i386-Check-for-host-features-before-filter_fe.patch 2013-04-05 20:03:40.000000000 +0000 @@ -0,0 +1,51 @@ +From 46f9071a23385933e7318a7c1f540852689ee0ca Mon Sep 17 00:00:00 2001 +From: Eduardo Habkost +Date: Tue, 2 Apr 2013 17:48:12 -0300 +Subject: [PATCH 54/54] target-i386: Check for host features before + filter_features_for_kvm() + +commit 5ec01c2e96910e1588d1a0de8609b9dda7618c7f broke "-cpu ..,enforce", +as it has moved kvm_check_features_against_host() after the +filter_features_for_kvm() call. filter_features_for_kvm() removes all +features not supported by the host, so this effectively made +kvm_check_features_against_host() impossible to fail. + +This patch changes the call so we check for host feature support before +filtering the feature bits. + +Signed-off-by: Eduardo Habkost +Message-id: 1364935692-24004-1-git-send-email-ehabkost@redhat.com +Cc: Igor Mammedov +Signed-off-by: Anthony Liguori +(cherry picked from commit a509d632c877f7b5fa07368879b8ae5919a6d345) + +Signed-off-by: Michael Roth +--- + target-i386/cpu.c | 6 +++--- + 1 file changed, 3 insertions(+), 3 deletions(-) + +diff --git a/target-i386/cpu.c b/target-i386/cpu.c +index aab35c7..d9500e9 100644 +--- a/target-i386/cpu.c ++++ b/target-i386/cpu.c +@@ -2091,14 +2091,14 @@ void x86_cpu_realize(Object *obj, Error **errp) + env->cpuid_ext3_features &= TCG_EXT3_FEATURES; + env->cpuid_svm_features &= TCG_SVM_FEATURES; + } else { +-#ifdef CONFIG_KVM +- filter_features_for_kvm(cpu); +-#endif + if (check_cpuid && kvm_check_features_against_host(cpu) + && enforce_cpuid) { + error_setg(errp, "Host's CPU doesn't support requested features"); + return; + } ++#ifdef CONFIG_KVM ++ filter_features_for_kvm(cpu); ++#endif + } + + #ifndef CONFIG_USER_ONLY +-- +1.8.1.2 + diff -Nru qemu-1.4.0+dfsg/debian/patches/series qemu-1.4.0+dfsg/debian/patches/series --- qemu-1.4.0+dfsg/debian/patches/series 2013-04-02 19:53:09.000000000 +0000 +++ qemu-1.4.0+dfsg/debian/patches/series 2013-04-05 20:27:25.000000000 +0000 @@ -68,6 +68,59 @@ expose-vmx_qemu64cpu.patch gridcentric/ramblock-filename gridcentric/silent_stop.patch -0001-fix-wrong-output-with-info-chardev-for-tcp-socket.patch +#0001-fix-wrong-output-with-info-chardev-for-tcp-socket.patch - dupd by 1.4.1/0005 #FUTEX_WAIT_BITSET.patch -0002-migration-buffer-retry-on-eagain.patch +1.4.1/0001-target-ppc-Fix-G2leGP3-PVR.patch +1.4.1/0002-coroutine-trim-down-nesting-level-in-perf_nesting-te.patch +1.4.1/0003-block-complete-all-IOs-before-.bdrv_truncate.patch +1.4.1/0004-tap-forbid-creating-multiqueue-tap-when-hub-is-used.patch +1.4.1/0005-qemu-char.c-fix-waiting-for-telnet-connection-messag.patch +1.4.1/0006-net-reduce-the-unnecessary-memory-allocation-of-mult.patch +1.4.1/0007-help-add-docs-for-multiqueue-tap-options.patch +1.4.1/0008-vga-fix-byteswapping.patch +1.4.1/0009-qmp-netdev_add-is-like-netdev-not-net-fix-documentat.patch +1.4.1/0010-qemu-ga-make-guest-sync-delimited-available-during-f.patch +1.4.1/0011-scsi-disk-handle-io_canceled-uniformly-and-correctly.patch +1.4.1/0012-iscsi-look-for-pkg-config-file-too.patch +1.4.1/0013-scsi-do-not-call-scsi_read_data-scsi_write_data-for-.patch +1.4.1/0014-scsi-disk-do-not-complete-canceled-UNMAP-requests.patch +1.4.1/0015-rtc-test-Fix-test-failures-with-recent-glib.patch +1.4.1/0016-Allow-virtio-net-features-for-legacy-s390-virtio-bus.patch +1.4.1/0017-pseries-Add-compatible-property-to-root-of-device-tr.patch +1.4.1/0018-qcow2-make-is_allocated-return-true-for-zero-cluster.patch +1.4.1/0019-qemu-ga-use-key-value-store-to-avoid-recycling-fd-ha.patch +1.4.1/0020-qga-main.c-Don-t-use-g_key_file_get-set_int64.patch +1.4.1/0021-tcg-Fix-occasional-TCG-broken-problem-when-ldst-opti.patch +1.4.1/0022-virtio-ccw-Queue-sanity-check-for-notify-hypercall.patch +1.4.1/0023-qemu-bridge-helper-force-usage-of-a-very-high-MAC-ad.patch +1.4.1/0024-configure-Require-at-least-spice-protocol-0.12.3.patch +1.4.1/0025-pseries-Add-cleanup-hook-for-PAPR-virtual-LAN-device.patch +1.4.1/0026-target-ppc-Fix-CPU_POWERPC_MPC8547E.patch +1.4.1/0027-ide-macio-Fix-macio-DMA-initialisation.patch +1.4.1/0028-virtio-blk-fix-unplug-virsh-reboot.patch +1.4.1/0029-Fix-page_cache-leak-in-cache_resize.patch +1.4.1/0030-page_cache-fix-memory-leak.patch +1.4.1/0031-qcow2-flush-refcount-cache-correctly-in-alloc_refcou.patch +1.4.1/0032-qcow2-flush-refcount-cache-correctly-in-qcow2_write_.patch +1.4.1/0033-linux-user-syscall.c-handle-FUTEX_WAIT_BITSET-in-do_.patch +1.4.1/0034-linux-user-fix-futex-strace-of-FUTEX_CLOCK_REALTIME.patch +1.4.1/0035-linux-user-make-bogus-negative-iovec-lengths-fail-EI.patch +1.4.1/0036-linux-user-syscall.c-Don-t-warn-about-unimplemented-.patch +#1.4.1/0037-update-seabios-to-1.7.2.1.patch +1.4.1/0038-oslib-posix-rename-socket_set_nonblock-to-qemu_set_n.patch +1.4.1/0039-net-ensure-socket-backend-uses-non-blocking-fds.patch +1.4.1/0040-qemu-socket-set-passed-fd-non-blocking-in-socket_con.patch +1.4.1/0041-chardev-clear-O_NONBLOCK-on-SCM_RIGHTS-file-descript.patch +1.4.1/0042-usb-tablet-Don-t-claim-wakeup-capability-for-USB-2-v.patch +1.4.1/0043-target-mips-fix-for-incorrect-multiplication-with-MU.patch +1.4.1/0044-target-mips-fix-for-sign-issue-in-MULQ_W-helper.patch +1.4.1/0045-target-mips-fix-DSP-overflow-macro-and-affected-rout.patch +1.4.1/0046-target-mips-fix-rndrashift_short_acc-and-code-for-EX.patch +1.4.1/0047-acpi-initialize-s4_val-used-in-s4-shutdown.patch +1.4.1/0048-doc-Fix-texinfo-table-markup-in-qemu-options.hx.patch +1.4.1/0049-qxl-better-vga-init-in-enter_vga_mode.patch +1.4.1/0050-Revert-block-complete-all-IOs-before-.bdrv_truncate.patch +1.4.1/0051-block-complete-all-IOs-before-resizing-a-device.patch +1.4.1/0052-compiler-fix-warning-with-GCC-4.8.0.patch +1.4.1/0053-help-add-docs-for-missing-queues-option-of-tap.patch +1.4.1/0054-target-i386-Check-for-host-features-before-filter_fe.patch