[Qemu-devel] [PATCH 04/46] qemu-io: add option to enable tracing

2012-04-05 Thread Kevin Wolf
From: Stefan Hajnoczi It can be useful to enable QEMU tracing when trying out block layer interfaces via qemu-io. Tracing can be enabled using the new -T FILE option where the given file contains a list of trace events to enable (just like the qemu --trace events=FILE option). $ echo qemu_vfr

[Qemu-devel] [PATCH V2 03/10] hw/sd.c: make sd_dataready() return bool

2012-04-05 Thread Igor Mitsyanko
For the sake of code clarity Signed-off-by: Igor Mitsyanko Reviewed-by: Peter Maydell --- hw/sd.c |2 +- hw/sd.h |2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/hw/sd.c b/hw/sd.c index eae1c20..e1c998c 100644 --- a/hw/sd.c +++ b/hw/sd.c @@ -1704,7 +1704,7 @@ uint8_

[Qemu-devel] [PATCH V2 02/10] hw/sd.c: convert binary variables to bool

2012-04-05 Thread Igor Mitsyanko
Several members of SDState have type int when they actually are binary variables. Change type of these variables to bool to improve code readability. Change SD API to be in consistency with new variables type. Signed-off-by: Igor Mitsyanko Reviewed-by: Peter Maydell --- hw/sd.c | 24 +++

[Qemu-devel] [PATCH] tcg/i386: Use GDB JIT debugging interface only for hosts with ELF

2012-04-05 Thread Stefan Weil
Not all i386 / x86_64 hosts use ELF. Ask the compiler whether ELF is used. On w64, gdb crashes when ELF_HOST_MACHINE is defined. Cc: Richard Henderson Cc: Blue Swirl Signed-off-by: Stefan Weil --- tcg/i386/tcg-target.c |4 +++- 1 files changed, 3 insertions(+), 1 deletions(-) diff --git

[Qemu-devel] [PATCH 30/46] qemu-img: add dirty flag status

2012-04-05 Thread Kevin Wolf
From: Dong Xu Wang Some block drivers can verify their image files are clean or not. So we can show it while using "qemu-img info". Signed-off-by: Dong Xu Wang Reviewed-by: Stefan Hajnoczi Signed-off-by: Kevin Wolf --- block.h|1 + qemu-img.c |3 +++ 2 files changed, 4 insertions

[Qemu-devel] [PATCH 16/46] vdi: move end-of-I/O handling at the end

2012-04-05 Thread Kevin Wolf
From: Paolo Bonzini The next step is to take code that only triggers after the first operation, and move it at the end of vdi_aio_read_cb and vdi_aio_write_cb. Acked-by: Stefan Weil Signed-off-by: Paolo Bonzini Signed-off-by: Kevin Wolf --- block/vdi.c | 123 +++-

[Qemu-devel] [PATCH 5/7] block: pass new base image format to bdrv_change_backing_file

2012-04-05 Thread Paolo Bonzini
The format was not written to the image, only the file name. This will overwrite an auto-probe image with the right format. Format probing is unsafe and we want to avoid it whenever possible. An alternative would be to look out the backing file from the image above base. Signed-off-by: Paolo Bonz

[Qemu-devel] [PATCH 46/46] qed: remove incoming live migration blocker

2012-04-05 Thread Kevin Wolf
From: Benoît Canet Signed-off-by: Benoit Canet Reviewed-by: Stefan Hajnoczi Signed-off-by: Kevin Wolf --- block/qed.c |9 - block/qed.h |2 -- 2 files changed, 0 insertions(+), 11 deletions(-) diff --git a/block/qed.c b/block/qed.c index aea2772..366cde7 100644 --- a/block/qe

[Qemu-devel] [PATCH 40/46] block: Add new BDRV_O_INCOMING flag to notice incoming live migration

2012-04-05 Thread Kevin Wolf
From: Benoît Canet >From original patch with Patchwork-id: 31110 by Stefan Hajnoczi "Add a flag to indicate that incoming migration is pending and care needs to be taken for data consistency. Block drivers should not modify the image file before incoming migration is complete since the migrati

[Qemu-devel] [PATCH v3 04/10] qemu-thread: Factor out qemu_error_exit

2012-04-05 Thread Jan Kiszka
Will be used in another wrapper module soon. Signed-off-by: Jan Kiszka --- qemu-thread-posix.c | 30 +++--- qemu-thread-win32.c | 18 +- qemu-thread.h |2 ++ 3 files changed, 26 insertions(+), 24 deletions(-) diff --git a/qemu-thread-posix.c

[Qemu-devel] [PATCH 31/46] qed: track dirty flag status

2012-04-05 Thread Kevin Wolf
From: Dong Xu Wang Signed-off-by: Dong Xu Wang Reviewed-by: Stefan Hajnoczi Signed-off-by: Kevin Wolf --- block/qed.c |1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/block/qed.c b/block/qed.c index d6c1580..19d87f3 100644 --- a/block/qed.c +++ b/block/qed.c @@ -1434,6

[Qemu-devel] [PATCH 4/7] block: close unused image files at the end of streaming

2012-04-05 Thread Paolo Bonzini
From: Marcelo Tosatti Close the now unused images that were part of the previous backing file chain and adjust ->backing_hd properly. Note that this only works with relative paths. Given the images: /tmp/a/base.raw /tmp/a/snap1.qcow2 /tmp/b/snap2.qcow2 chained as: base(bak:"") <- snap1(ba

Re: [Qemu-devel] [PATCH v3 01/10] Introduce qemu_cond_timedwait for POSIX

2012-04-05 Thread malc
On Thu, 5 Apr 2012, Paolo Bonzini wrote: > Il 05/04/2012 14:53, malc ha scritto: > > On Thu, 5 Apr 2012, Paolo Bonzini wrote: > > > >> Il 05/04/2012 14:30, malc ha scritto: > > Would save that "* 1000". I just wondered why we do not use it elsewhere > > in QEMU and was reluctant to risk s

[Qemu-devel] [PATCH V3 4/8] hw/serial.c: replace register_ioport*

2012-04-05 Thread Julien Grall
This patch replaces all register_ioport* with a MemoryRegion. It permits to use the new Memory stuff like listener. For more flexibility, the IO address space is passed as an argument. Signed-off-by: Julien Grall --- hw/mips_mipssim.c |3 ++- hw/pc.h |2 +- hw/serial.c |

[Qemu-devel] [PATCH 18/46] vdi: move aiocb fields to locals

2012-04-05 Thread Kevin Wolf
From: Paolo Bonzini Most of the AIOCB really holds local variables that need to persist across callback invocation. It can go away now. Acked-by: Stefan Weil Signed-off-by: Paolo Bonzini Signed-off-by: Kevin Wolf --- block/vdi.c | 163 +++

[Qemu-devel] [PATCH 3/4] target-xtensa: add test for LEND invalidation

2012-04-05 Thread Max Filippov
Signed-off-by: Max Filippov --- tests/tcg/xtensa/test_loop.S | 25 + 1 files changed, 25 insertions(+), 0 deletions(-) diff --git a/tests/tcg/xtensa/test_loop.S b/tests/tcg/xtensa/test_loop.S index a5ea933..9ebc18d 100644 --- a/tests/tcg/xtensa/test_loop.S +++ b/tests/t

[Qemu-devel] [PATCH 27/46] block: document job API

2012-04-05 Thread Kevin Wolf
From: Paolo Bonzini I am not sure that these are really proper GtkDoc, but they follow the existing documentation in block_int.h. Signed-off-by: Paolo Bonzini Reviewed-by: Stefan Hajnoczi Signed-off-by: Kevin Wolf --- block_int.h | 115 +++

[Qemu-devel] [PATCH] configure: require glib 2.12, 2.20 for mingw32

2012-04-05 Thread Paolo Bonzini
These are pretty sane requirements to move forward with glib usage. 2.12 is the version found in RHEL/CentOS 5, and 2.20 is the first version to support g_poll. Without g_poll, we cannot integrate well with the glib main loop. Signed-off-by: Paolo Bonzini --- configure | 12 ++-- 1 fi

[Qemu-devel] [PATCH v3 06/10] Use QemuEvent in main loop

2012-04-05 Thread Jan Kiszka
QemuEvent provides the same service, just in a central place. Signed-off-by: Jan Kiszka --- main-loop.c | 104 +++--- 1 files changed, 13 insertions(+), 91 deletions(-) diff --git a/main-loop.c b/main-loop.c index db23de0..998d291 100644 ---

[Qemu-devel] [PATCH V2 01/10] hw/sd.c: convert wp_groups in SDState to bitfield

2012-04-05 Thread Igor Mitsyanko
Representing each group write protection flag with only one bit instead of int variable significantly reduces memory consumption. Signed-off-by: Igor Mitsyanko --- hw/sd.c | 33 +++-- 1 files changed, 19 insertions(+), 14 deletions(-) diff --git a/hw/sd.c b/hw/sd.c

[Qemu-devel] [PULL 0/4] target-xtensa queue

2012-04-05 Thread Max Filippov
The following changes since commit 8f8d364f2447e58768132fc10f48a67af371ee38: Merge branch 's390-for-upstream' of git://repo.or.cz/qemu/agraf (2012-04-04 20:45:03 +) are available in the git repository at: git://jcmvbkbc.spb.ru/dumb/qemu-xtensa.git xtensa Lluís Vilanova (1): targe

[Qemu-devel] [PATCH 01/46] trace-events: Rename 'next' argument

2012-04-05 Thread Kevin Wolf
'next' is a systemtap keyword, so it's a bad idea to use it as an argument name. Signed-off-by: Kevin Wolf --- trace-events |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/trace-events b/trace-events index db2cd39..a5f276d 100644 --- a/trace-events +++ b/trace-events @@

Re: [Qemu-devel] Debug single program in QEMU

2012-04-05 Thread Yue Chen
Hi, thanks again for your reply. It seems that, from the instruction log, we can find out "*which instructions belong to which process(task)*" according to CR3 register. 2012/3/15 陳韋任 > O.K., then. You must specify which mode you're running, user mode or > system > mode? User mode should

[Qemu-devel] [PATCH 0/7] Miscellaneous fixes for block and snapshots

2012-04-05 Thread Paolo Bonzini
These patches fix a few miscellaneous bugs in live snapshots and block streaming. Paolo Bonzini (7): block: add mode argument to blockdev-snapshot-sync block: fail live snapshot if disk has no medium block: fix snapshot with QED format block: close unused image files at the end of streamin

Re: [Qemu-devel] [PATCH 08/10] coroutine: process the coroutines woken by child when child yield

2012-04-05 Thread Kevin Wolf
Am 03.04.2012 10:38, schrieb Lai Jiangshan: > If the child wake up someone, process them. > > It would the child complete its works if woken coroutine release the locks > that the child needs. > > It may help for the cache, if the child wake up some someone, they are > probably accessing the same

[Qemu-devel] [PATCH 34/46] sheepdog: fix send req helpers

2012-04-05 Thread Kevin Wolf
From: Liu Yuan We should return if reading of the header fails. Cc: Kevin Wolf Cc: MORITA Kazutaka Signed-off-by: Liu Yuan Acked-by: MORITA Kazutaka Signed-off-by: Kevin Wolf --- block/sheepdog.c |2 ++ 1 files changed, 2 insertions(+), 0 deletions(-) diff --git a/block/sheepdog.c b/b

[Qemu-devel] [PATCH 44/46] migration: clear BDRV_O_INCOMING flags on end of incoming live migration

2012-04-05 Thread Kevin Wolf
From: Benoît Canet Signed-off-by: Benoît Canet Reviewed-by: Stefan Hajnoczi Signed-off-by: Kevin Wolf --- migration.c |1 + 1 files changed, 1 insertions(+), 0 deletions(-) diff --git a/migration.c b/migration.c index 8c119ba..94f7839 100644 --- a/migration.c +++ b/migration.c @@ -91,6 +

[Qemu-devel] [PATCH V3 0/8] memory: unify ioport registration

2012-04-05 Thread Julien Grall
This is the third version of patch series about ioport registration. For the moment some part of QEMU use register_ioport* functions to register ioport. These functions don't permit the logging of range with Memory Listener. Modifications between V1 and V2: - Remove the use of get_system_io. I

[Qemu-devel] [PATCH v3 03/10] Switch compatfd to QEMU thread

2012-04-05 Thread Jan Kiszka
qemu_thread_create already does signal blocking and detaching for us. Signed-off-by: Jan Kiszka --- compatfd.c | 16 +++- 1 files changed, 3 insertions(+), 13 deletions(-) diff --git a/compatfd.c b/compatfd.c index 42f81ca..8d5a63f 100644 --- a/compatfd.c +++ b/compatfd.c @@ -14,1

[Qemu-devel] [PATCH 38/46] qemu-iotests: Fix call syntax for qemu-io

2012-04-05 Thread Kevin Wolf
From: Stefan Weil qemu-io requires options first, then fixed parameters. GNU getopt also allows options at the end, but POSIX getopt doesn't. Try "export POSIXLY_CORRECT=y" to get the POSIX behaviour with GNU getopt, too. Cc: Kevin Wolf Signed-off-by: Stefan Weil Signed-off-by: Kevin Wolf --

[Qemu-devel] [PATCH 6/7] block: push bdrv_change_backing_file error checking up from drivers

2012-04-05 Thread Paolo Bonzini
Signed-off-by: Paolo Bonzini --- block.c |5 + block/qcow2.c |5 - 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/block.c b/block.c index e806ad8..e293882 100644 --- a/block.c +++ b/block.c @@ -1403,6 +1403,11 @@ int bdrv_change_backing_file(BlockDriverState

[Qemu-devel] [PATCH 2/4] target-xtensa: improve unit tests debugging

2012-04-05 Thread Max Filippov
- add testcase announcement; - add global symbols for individual tests; - add host-debug-* makefile target. Signed-off-by: Max Filippov --- tests/tcg/xtensa/Makefile |3 +++ tests/tcg/xtensa/macros.inc | 17 + 2 files changed, 20 insertions(+), 0 deletions(-) diff --git

[Qemu-devel] [PATCH 45/46] qed: honor BDRV_O_INCOMING for incoming live migration

2012-04-05 Thread Kevin Wolf
From: Benoît Canet >From original commit with Patchwork-id: 31108 by Stefan Hajnoczi "The QED image format includes a file header bit to mark images dirty. QED normally checks dirty images on open and fixes inconsistent metadata. This is undesirable during live migration since the dirty bit ma

Re: [Qemu-devel] [PATCH v3 01/10] Introduce qemu_cond_timedwait for POSIX

2012-04-05 Thread malc
On Thu, 5 Apr 2012, Jan Kiszka wrote: > On 2012-04-05 14:56, Paolo Bonzini wrote: > > Il 05/04/2012 14:53, malc ha scritto: > >> On Thu, 5 Apr 2012, Paolo Bonzini wrote: > >> > >>> Il 05/04/2012 14:30, malc ha scritto: > >> Would save that "* 1000". I just wondered why we do not use it >

[Qemu-devel] [PATCH 37/46] qemu-iotests: Fix call syntax for qemu-img

2012-04-05 Thread Kevin Wolf
From: Stefan Weil qemu-img requires first options, then file name, then size. GNU getopt also allows options at the end, but POSIX getopt doesn't. Try "export POSIXLY_CORRECT=y" to get the POSIX behaviour with GNU getopt, too. Cc: Kevin Wolf Signed-off-by: Stefan Weil Signed-off-by: Kevin Wol

[Qemu-devel] [PATCH V2 08/10] SD card: introduce "spi_mode" property for SD card objects

2012-04-05 Thread Igor Mitsyanko
And drop passing is_spi argument to SDCardClass::init function. After this, SDCardClass::init is trivialized enough to replace it with Object::realize callback in the future. "spi_mode" property should be set before realizing SD card object. It defaults to "false". Signed-off-by: Igor Mitsyanko

[Qemu-devel] [PATCH 12/46] qerror: fix QERR_PROPERTY_VALUE_OUT_OF_RANGE description

2012-04-05 Thread Kevin Wolf
From: Stefan Hajnoczi Fix a typo in the description for QERR_PROPERTY_VALUE_OUT_OF_RANGE where "'" was used instead of ")". Signed-off-by: Stefan Hajnoczi Reviewed-by: Paolo Bonzini Signed-off-by: Kevin Wolf --- qerror.c |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git

[Qemu-devel] [PATCH v8 06/10] Add XBZRLE to ram_save_block and ram_save_live

2012-04-05 Thread Orit Wasserman
Add migration state to store XBRLE params (enablement and cache size). In the outgoing migration check to see if the page is cached and changed than send compressed page by using save_xbrle_page function. In the incoming migration check to see if RAM_SAVE_FLAG_XBRLE is set and decompress the page (

[Qemu-devel] [Bug 974229] Re: qemu-kvm-1.0: segfault using vnc-console => not threadsafe!

2012-04-05 Thread warum
puh, it did take a while, but meanwhile another segfault has occured, which has nothing to do with the above one. due to the long time, it took to happen, it might not be as reproducible as needed for efficient debugging, at least I've currently no further time for this. I'll now try V0.15.1 and ho

[Qemu-devel] [Bug 974229] Re: qemu-kvm-1.0: segfault using vnc-console => not threadsafe!

2012-04-05 Thread Serge Hallyn
Thanks for reporting this bug. Since vnc-thread-support is not compiled into the qemu-kvm package, the bug is invalid there. I will mark it as affecting the upstream QEMU project. Note you'll want to use git://git.qemu.org/qemu.git as the upstream code base. ** Also affects: qemu Importance

[Qemu-devel] [PATCH 4/4] target-xtensa: fix tb invalidation for IBREAK and LOOP

2012-04-05 Thread Max Filippov
Instruction breakpoint/zero overhead loop handling code is built into TBs pointed to by IBREAKA/LEND SRs. When these or related SRs get changed TBs at virtual addresses corresponding to their old and their new values must be invalidated. Virtual address range is passed to the tb_invalidate_phys_pa

[Qemu-devel] Fixing multithreaded app support in i386 user mode?

2012-04-05 Thread Dan Kegel
There's been some noise over the years about getting multithreaded apps working in i386 user mode, e.g. https://bugs.launchpad.net/qemu/+bug/902413 https://bugs.launchpad.net/qemu-linaro/+bug/758424 http://lists.gnu.org/archive/html/qemu-devel/2009-08/msg01041.html http://lists.gnu.org/archive/htm

[Qemu-devel] [PATCH 03/46] qcow2: Remove unused parameter in get_cluster_table()

2012-04-05 Thread Kevin Wolf
Since everything goes through the cache, callers don't use the L2 table offset any more. Signed-off-by: Kevin Wolf Reviewed-by: Stefan Hajnoczi --- block/qcow2-cluster.c | 18 -- 1 files changed, 8 insertions(+), 10 deletions(-) diff --git a/block/qcow2-cluster.c b/block/qcow

[Qemu-devel] [PATCH v2 3/5] acpi_piix4: Remove PCI_RMV_BASE write code

2012-04-05 Thread Alex Williamson
Clarify this register as read-only and remove write code. No change in existing behavior. Signed-off-by: Alex Williamson --- docs/specs/acpi_pci_hotplug.txt |2 +- hw/acpi_piix4.c |6 -- 2 files changed, 1 insertions(+), 7 deletions(-) diff --git a/docs/specs/acpi_

[Qemu-devel] [PATCH V3 6/8] hw/dma.c: replace register_ioport*

2012-04-05 Thread Julien Grall
This patch replaces all register_ioport* be the new memory API functions. It permits to use the new Memory stuff like listener. Signed-off-by: Julien Grall --- hw/dma.c | 84 - 1 files changed, 60 insertions(+), 24 deletions(-) diff

[Qemu-devel] [PATCH 14/46] block: enforce constraints on block size properties

2012-04-05 Thread Kevin Wolf
From: Stefan Hajnoczi Nicolae Mogoreanu noticed that I/O requests can lead to QEMU crashes when the logical_block_size property is smaller than 512 bytes. Using the new "blocksize" property we can properly enforce constraints on the block size such that QEMU's block layer is able to operate cor

[Qemu-devel] [PATCH 1/4] target-xtensa: Move helpers.h to helper.h

2012-04-05 Thread Max Filippov
From: Lluís Vilanova Provides a file naming scheme consistent with other targets. Signed-off-by: Lluís Vilanova Signed-off-by: Max Filippov --- target-xtensa/{helpers.h => helper.h} |0 target-xtensa/op_helper.c |2 +- target-xtensa/translate.c |6 +++--- x

Re: [Qemu-devel] [PATCH 0/0] MSI/MSIX injection for Xen HVM guests

2012-04-05 Thread Paolo Bonzini
Il 05/04/2012 12:43, Stefano Stabellini ha scritto: >>> > > Implement a simple Xen APIC module and use it to deliver MSI/MSIX for >>> > > Xen HVM guests. >> > >> > Only skimmed the patch but yeah, this is what I had in mind. Thanks! > It looks good to me too. > Paolo, can I add your acked-by? Ac

[Qemu-devel] [PATCH 1/7] block: add mode argument to blockdev-snapshot-sync

2012-04-05 Thread Paolo Bonzini
This was missing in the patch that added the argument. Signed-off-by: Paolo Bonzini --- qmp-commands.hx |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/qmp-commands.hx b/qmp-commands.hx index 9447871..a5accc9 100644 --- a/qmp-commands.hx +++ b/qmp-commands.hx @@ -762,7 +76

[Qemu-devel] [PATCH V2 05/10] hw/sd.c: add SD card save/load support

2012-04-05 Thread Igor Mitsyanko
This patch updates SD card emulation to support save/load of card's state. Signed-off-by: Igor Mitsyanko --- hw/sd.c | 89 +- 1 files changed, 64 insertions(+), 25 deletions(-) diff --git a/hw/sd.c b/hw/sd.c index 7160e8c..6f6be88 10

[Qemu-devel] [PATCH V2 06/10] hw/sd.c: convert to QOM object

2012-04-05 Thread Igor Mitsyanko
A straightforward conversion of SD card implementation to a proper QEMU object. Signed-off-by: Igor Mitsyanko --- hw/milkymist-memcard.c | 24 ++-- hw/omap_mmc.c | 28 hw/pl181.c | 14 -- hw/pxa2xx_mmci.c

[Qemu-devel] [PATCH v3 10/10] Remove EventNotifier

2012-04-05 Thread Jan Kiszka
Obsoleted by QemuEvent. Signed-off-by: Jan Kiszka --- Makefile.objs|2 +- event_notifier.c | 61 -- event_notifier.h | 28 3 files changed, 1 insertions(+), 90 deletions(-) delete mode 100644 event_notifier

[Qemu-devel] [PATCH v3 08/10] Use QemuEvent for POSIX AIO

2012-04-05 Thread Jan Kiszka
Use QemuEvent for signaling POSIX AIO completions. If native eventfd support is available, this avoids multiple read accesses to drain multiple pending signals. Signed-off-by: Jan Kiszka --- posix-aio-compat.c | 62 ++-- 1 files changed, 7 insert

[Qemu-devel] [PATCH V3 8/8] smb: replace_register_ioport*

2012-04-05 Thread Julien Grall
This patch fix smb_ioport_* to be compliant with read/write memory callback. Moreover it replaces all register_ioport* which use theses functions by the new Memory API. Signed-off-by: Julien Grall --- hw/acpi_piix4.c | 16 ++-- hw/pm_smbus.c |7 --- hw/pm_smbus.h |6

Re: [Qemu-devel] [PATCH 0/5] Spread the use of QEMU threading & locking API

2012-04-05 Thread Jan Kiszka
On 2012-04-05 09:51, Paolo Bonzini wrote: > Il 04/04/2012 19:19, Jan Kiszka ha scritto: Yep, this screams for something like QemuEvent which pleases all users of current qemu_eventfd and EventNotifier - and fit into the existing threading/synchronization abstraction layou

[Qemu-devel] [PATCH 29/46] qed: image fragmentation statistics

2012-04-05 Thread Kevin Wolf
From: Dong Xu Wang Signed-off-by: Dong Xu Wang Reviewed-by: Stefan Hajnoczi Signed-off-by: Kevin Wolf --- block/qed-check.c |9 + 1 files changed, 9 insertions(+), 0 deletions(-) diff --git a/block/qed-check.c b/block/qed-check.c index e4a49ce..94327ff 100644 --- a/block/qed-chec

[Qemu-devel] [PATCH 06/46] aio: move BlockDriverAIOCB to qemu-aio.h

2012-04-05 Thread Kevin Wolf
From: Paolo Bonzini And remove several block_int.h inclusions that should not be there. Signed-off-by: Paolo Bonzini Reviewed-by: Stefan Hajnoczi Signed-off-by: Kevin Wolf --- block.h |2 -- block_int.h | 18 -- dma-helpers.c |1 - hw/ide/core.c |

[Qemu-devel] [PATCH 3/7] block: fix snapshot with QED format

2012-04-05 Thread Paolo Bonzini
QED's opaque data includes a pointer back to the BlockDriverState. Creating a snapshot whose format is QED breaks the relationship when bdrv_append shuffles data between bs_new and bs_top. To avoid this, add a "rebind" function that tells the driver about the new relationship between the BlockDriv

Re: [Qemu-devel] ldub_code(s->pc++)

2012-04-05 Thread James Greensky
Get an unsigned byte from guest memory image after translating from guest virtual to host virtual address and verifying code read permissions. -Jim On Thu, Apr 5, 2012 at 1:26 PM, Davide wrote: > What does "ldub_code(s->pc++);" do??? >

[Qemu-devel] [Bug 902413] Re: qemu-i386-user on ARM host: wine hangs/spins when trying to run anything

2012-04-05 Thread Dan Kegel
See also https://bugs.launchpad.net/ubuntu/+source/qemu-linaro/+bug/758424 -- You received this bug notification because you are a member of qemu- devel-ml, which is subscribed to QEMU. https://bugs.launchpad.net/bugs/902413 Title: qemu-i386-user on ARM host: wine hangs/spins when trying to ru

Re: [Qemu-devel] [PATCH 7/7 v5] VMXNET3 paravirtualized device implementation Interface type "vmxnet3" added.

2012-04-05 Thread Yan Vugenfirer
On Thu, Apr 5, 2012 at 8:25 AM, Gerhard Wiesinger wrote: > > On Wed, 4 Apr 2012, Izik Eidus wrote: >> >> What about this patch?, everything that was asked from Dmitry was >> accomplished... >> What prevent us from progressing with merging this patch? > > > As already discussed on the list patch v

[Qemu-devel] [PATCH 2/7] block: fail live snapshot if disk has no medium

2012-04-05 Thread Paolo Bonzini
This would cause a segfault accessing states->old_bs->drv. Signed-off-by: Paolo Bonzini --- blockdev.c |9 ++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/blockdev.c b/blockdev.c index 4d17486..be9cdc5 100644 --- a/blockdev.c +++ b/blockdev.c @@ -752,14 +752,17 @@ voi

Re: [Qemu-devel] What do these instructions do??

2012-04-05 Thread Max Filippov
> In target-i386/translate.c there are this instructions: > int op, f, val; > op = (b >> 3) & 7; > f = (b >> 1) & 3; > if ((b & 1) == 0) >   ot = OT_BYTE; > else >   ot = dflag + OT_WORD; > What does this code do?? It extracts some useful subfields from one-byte opcodes, e.g. op is the arithmetic

Re: [Qemu-devel] [PATCH 23/25] qom: add realized property

2012-04-05 Thread Andreas Färber
Am 03.04.2012 15:03, schrieb Paolo Bonzini: > Il 03/04/2012 14:11, Andreas Färber ha scritto: >> Since this patch is clearly an extended version of my realize patch >> http://patchwork.ozlabs.org/patch/148752/, it should carry my SoB, as >> reminded last night. If you don't want my SoB on the parts

Re: [Qemu-devel] [RFC PATCH] pc: change default machine model and versions

2012-04-05 Thread Eric Blake
On 04/03/2012 01:38 PM, Anthony Liguori wrote: > N.B. This is a small patch with significant implications. Please read > carefully. > > With this patch, we will not introduce any more '-M pc-1.x' beyond 'pc-1.0'. > We will not introduce a new 'pc-X.Y' until the QEMU 2.0 release (1Q 2014). > Inst

[Qemu-devel] [PATCH V2 04/10] hw/sd.c: make sd_wp_addr() return bool

2012-04-05 Thread Igor Mitsyanko
For the sake of code clarity Signed-off-by: Igor Mitsyanko --- hw/sd.c |4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) diff --git a/hw/sd.c b/hw/sd.c index e1c998c..7160e8c 100644 --- a/hw/sd.c +++ b/hw/sd.c @@ -539,9 +539,9 @@ static void sd_function_switch(SDState *sd, uint32_t

[Qemu-devel] [PATCH] qom: Refine container_get() to allow using a custom root

2012-04-05 Thread Andreas Färber
Specify the root to search from as argument. This avoids hardcoding "/machine" in some places and makes it more flexible. Signed-off-by: Andreas Färber Cc: Paolo Bonzini Cc: Anthony Liguori --- hw/qdev-monitor.c |4 ++-- hw/qdev.c |7 --- include/qemu/object.h |

[Qemu-devel] [PATCH V2 00/10] SD save/load support and SD qomification

2012-04-05 Thread Igor Mitsyanko
v1->v2 PATCH1: use bitmap.h heder for bit operations. PATCH6: use wrappers to call SDClass methods Added 4 new patches: PATCH7 and PATCH8 drope passing arguments to SDClass::init functions and replace them with SD card object properties. SDClass::init is trivialized to realize(). PATCH10 adds "ima

[Qemu-devel] [PATCH 25/46] block: fix streaming/closing race

2012-04-05 Thread Kevin Wolf
From: Paolo Bonzini Streaming can issue I/O while qcow2_close is running. This causes the L2 caches to become very confused or, alternatively, could cause a segfault when the streaming coroutine is reentered after closing its block device. The fix is to cancel streaming jobs when closing their

[Qemu-devel] [PATCH v8 09/10] Add set_cachesize command

2012-04-05 Thread Orit Wasserman
Change XBZRLE cache size in MB (the size should be a power of 2). Signed-off-by: Orit Wasserman --- arch_init.c |8 hmp-commands.hx | 15 +++ hmp.c| 13 + hmp.h|1 + migration.c | 31 ++-

[Qemu-devel] [PATCH 22/46] Use DMADirection type for dma_bdrv_io

2012-04-05 Thread Kevin Wolf
From: David Gibson Currently dma_bdrv_io() takes a 'to_dev' boolean parameter to determine the direction of DMA it is emulating. We already have a DMADirection enum designed specifically to encode DMA directions. This patch uses it for dma_bdrv_io() as well. This involves removing the DMADirect

[Qemu-devel] [PATCH 42/46] blockdev: open images with BDRV_O_INCOMING on incoming live migration

2012-04-05 Thread Kevin Wolf
From: Benoît Canet Open images with BDRV_O_INCOMING in order to inform block drivers that an incoming live migration is coming. Signed-off-by: Benoit Canet Reviewed-by: Stefan Hajnoczi Signed-off-by: Kevin Wolf --- blockdev.c |4 1 files changed, 4 insertions(+), 0 deletions(-) dif

[Qemu-devel] [PATCH 10/46] ide: Adds wwn=hex qdev option

2012-04-05 Thread Kevin Wolf
From: Floris Bos Allow the user to specify a disk's World Wide Name. Linux guests can address disks by their unique World Wide Name number (e.g. /dev/disk/by-id/wwn-0x5001517959123522). This patch adds support for assigning a World Wide Name number to a virtual IDE disk. Cc: kw...@redhat.com Si

[Qemu-devel] [PATCH v8 07/10] Add XBZRLE option to migrate command

2012-04-05 Thread Orit Wasserman
Signed-off-by: Orit Wasserman --- hmp-commands.hx | 20 hmp.c|4 +++- migration.c |9 + qapi-schema.json |2 +- qmp-commands.hx |4 +++- 5 files changed, 28 insertions(+), 11 deletions(-) diff --git a/hmp-commands.hx b/hmp-command

[Qemu-devel] ldub_code(s->pc++)

2012-04-05 Thread Davide
What does "ldub_code(s->pc++);" do???

[Qemu-devel] What do these instructions do??

2012-04-05 Thread Davide
In target-i386/translate.c there are this instructions: int op, f, val; op = (b >> 3) & 7; f = (b >> 1) & 3; if ((b & 1) == 0) ot = OT_BYTE; else ot = dflag + OT_WORD; What does this code do??

[Qemu-devel] [PATCH 05/46] block: push recursive flushing up from drivers

2012-04-05 Thread Kevin Wolf
From: Paolo Bonzini Signed-off-by: Paolo Bonzini Signed-off-by: Kevin Wolf --- block.c | 22 ++ block/blkdebug.c |7 --- block/cow.c |6 -- block/qcow.c |6 -- block/qcow2.c|6 -- block/qed.c |8 bloc

[Qemu-devel] [PATCH V3 7/8] hw/apm.c: replace register_ioport*

2012-04-05 Thread Julien Grall
This patch replaces all register_ioport* by a MemorySection. It permits to use the new Memory stuff like listener. Moreover, the PCI is added as an argument for apm_init, so we can register IO inside the pci IO address space. Signed-off-by: Julien Grall --- hw/acpi_piix4.c |2 +- hw/apm.c

[Qemu-devel] [PATCH v3 09/10] virtio: Switch to QemuEvent

2012-04-05 Thread Jan Kiszka
Replace EventNotifier with the new generic QemuEvent service. CC: Michael S. Tsirkin Signed-off-by: Jan Kiszka --- hw/vhost.c |4 +- hw/virtio-pci.c | 61 ++ hw/virtio.c | 12 +- hw/virtio.h |6 ++-- 4 files ch

[Qemu-devel] [PATCH 7/7] block: update in-memory backing file and format

2012-04-05 Thread Paolo Bonzini
These are needed to print "info block" output correctly. QCOW2 does this already because it needs it to write the header, but QED does not, and common code is a better place to do it. Signed-off-by: Paolo Bonzini --- block.c | 11 +-- 1 file changed, 9 insertions(+), 2 deletions(-) d

Re: [Qemu-devel] [PATCH 7/7 v5] VMXNET3 paravirtualized device implementation Interface type "vmxnet3" added.

2012-04-05 Thread Gerhard Wiesinger
On Thu, 5 Apr 2012, Yan Vugenfirer wrote: On Thu, Apr 5, 2012 at 8:25 AM, Gerhard Wiesinger wrote: On Wed, 4 Apr 2012, Izik Eidus wrote: What about this patch?, everything that was asked from Dmitry was accomplished... What prevent us from progressing with merging this patch? As already

[Qemu-devel] [RFC PATCH v3 9/9] repagent: Moved to use qemu-socket instead of platform dependent.

2012-04-05 Thread Ori Mamluk
Used as repagent patch v3 --- block/repagent/repagent.c|4 ++-- block/repagent/repagent.h|2 +- block/repagent/repagent_client.c | 35 --- 3 files changed, 11 insertions(+), 30 deletions(-) diff --git a/block/repagent/repagent.c b/blo

[Qemu-devel] [PATCH v2 0/2] softfloat: fix 'int32 is 32 bits' assumptions

2012-04-05 Thread Peter Maydell
This is a resend of some patches I sent out back in January when we were kicking the int32-vs-int32_t issue around. These patches fix some assumptions that are made by various bits of code that the softfloat 'int32' and 'uint32' types are exactly 32 bits rather than at least 32 bits. They're worth

[Qemu-devel] [PATCH v2 1/2] softfloat: float*_to_int32_round_to_zero: don't assume int32 is 32 bits

2012-04-05 Thread Peter Maydell
Code in the float64_to_int32_round_to_zero() function was assuming that int32 would not be wider than 32 bits; this meant it might not correctly detect the overflow case. We take the simple approach of using int32_t. Also fix equivalent issues in the functions for other float sizes. Signed-off-by:

Re: [Qemu-devel] [PATCH v2 0/2] Xilinx Zynq PL330 support

2012-04-05 Thread Peter Maydell
On 5 April 2012 00:37, John Williams wrote: > On Fri, Mar 30, 2012 at 5:58 PM, Peter A. G. Crosthwaite > wrote: > >> These patches add support for the Primcell PL330 DMA controller > Any obstacles to this going in?  Peter has revised according to all > feedback received so far, and has sign-off

Re: [Qemu-devel] [PATCH v2] hw/vexpress.c: Add NOR flash model

2012-04-05 Thread Peter Maydell
On 21 March 2012 03:37, Liming Wang wrote: > Vexpress motherboard has two 2x16 NOR flash, but pflash_cfi01 > doesn't support interleaving, so here only models two 1x32 flash. > Although it's not exactly modeled, it works fine for running linux. (Sorry for the delay getting round to reviewing this

[Qemu-devel] [PATCH v3 05/10] Introduce QemuEvent abstraction

2012-04-05 Thread Jan Kiszka
Provide generic services for binary events. Blocking wait would be feasible but is not included yet as there are no users. Signed-off-by: Jan Kiszka --- Makefile|2 +- Makefile.objs |5 ++- qemu-event-posix.c | 110 +++

Re: [Qemu-devel] [PATCH] versatilepb: add i2c support

2012-04-05 Thread Peter Maydell
On 2 April 2012 21:17, Oskar Andero wrote: > Signed-off-by: Oskar Andero > --- >  hw/versatilepb.c |   80 > ++ >  1 files changed, 80 insertions(+), 0 deletions(-) This is just a cut-n-paste of the i2c device in hw/realview.c. Instead of dupli

[Qemu-devel] [PATCH v2 5/5] acpi_piix4: Use pci_get/set_byte

2012-04-05 Thread Alex Williamson
Remove stray direct access Signed-off-by: Alex Williamson --- hw/acpi_piix4.c | 53 +++-- 1 files changed, 27 insertions(+), 26 deletions(-) diff --git a/hw/acpi_piix4.c b/hw/acpi_piix4.c index 11c1f85..30d9f12 100644 --- a/hw/acpi_piix4.c +++

[Qemu-devel] [PATCH V3 5/8] hw/pc.c: replace register_ioport*

2012-04-05 Thread Julien Grall
This patch replaces all register_ioport* with portio_* or isa_register_portio_list. It permits to use the new Memory stuff like listener. Signed-off-by: Julien Grall --- hw/pc.c | 58 +++--- 1 files changed, 43 insertions(+), 15 deletions(-)

Re: [Qemu-devel] [patch V5 2/5] Implement i.MX31 Clock Control Module

2012-04-05 Thread Peter Maydell
On 3 April 2012 02:55, Peter Chubb wrote: > === > --- qemu-working.orig/hw/imx.h  2012-04-03 11:48:48.088706634 +1000 > +++ qemu-working/hw/imx.h       2012-04-03 11:48:48.776708322 +1000 > @@ -13,4 +13,18 @@ > >  void imx_serial_crea

Re: [Qemu-devel] [patch V5 3/5] FreeSCALE i.MX31 support: Timers

2012-04-05 Thread Peter Maydell
On 3 April 2012 02:55, Peter Chubb wrote: > +    case 2: /* LR - set ticks */ > +        s->lr = value; > +        /* > +         * Artificially limit tick rate to something > +         * achievable under QEMU.  Otherwise, QEMU spends all > +         * its time generating timer interrupts, and the

Re: [Qemu-devel] [patch V5 5/5] FreeSCALE i.MX31 support: KZM-ARM11-01 evaluation board

2012-04-05 Thread Peter Maydell
On 3 April 2012 02:55, Peter Chubb wrote: > Board support for Kyoto Micro's KZM-ARM11-01, an evaluation board built > around the FreeScale i.MX31. > > > Signed-off-by: Philip O'Sullivan > Signed-off-by: Peter Chubb Reviewed-by: Peter Maydell -- PMM

[Qemu-devel] [PATCH v2 1/5] acpi_piix4: Disallow write to up/down PCI hotplug registers

2012-04-05 Thread Alex Williamson
The write side of these registers is never used and actually can't be used as defined because any read/modify/write sequence from the guest potentially races with qemu. Drop the write support and define these as read-only registers. Signed-off-by: Alex Williamson --- docs/specs/acpi_pci_hotplu

[Qemu-devel] [PATCH v2 2/5] acpi_piix4: Fix PCI hotplug race

2012-04-05 Thread Alex Williamson
As Michael Tsirkin demonstrated, current PCI hotplug is vulnerable to a few races. The first is a race with other hotplug operations because we clear the up & down registers at each event. If a new event comes before the last is processed, up/down is cleared and the event is lost. To fix this fo

[Qemu-devel] [PATCH v2 0/5] PCI hotplug fixes/cleanup

2012-04-05 Thread Alex Williamson
Incorporating feedback from v1. Re-ordered so first 2 patches are fixes, allowing easier backport. Instead of declaring the eject register is write-only we define it to be a feature bits register and define the base feature set in the docs (a feature register seems easier to maintain than a versi

Re: [Qemu-devel] [PATCH V2 10/10] hw/sd.c: introduce SD card "image" property and allow SD hot-insert

2012-04-05 Thread Paolo Bonzini
Il 05/04/2012 17:48, Igor Mitsyanko ha scritto: > New SD card "image" property can be used to: > - change image file attached to virtual SD card > - hot-insert new image file into newly initialized BlockDriverState (this was > not > possible before). > > Example usage: > ./qom-set /machine/milkym

[Qemu-devel] [PATCH 09/46] ide: Change serial number strncpy() to pstrcpy()

2012-04-05 Thread Kevin Wolf
From: Floris Bos strncpy may not null-terminate the destination string. Cc: kw...@redhat.com Signed-off-by: Floris Bos Signed-off-by: Kevin Wolf --- blockdev.c|5 +++-- hw/ide/core.c |2 +- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/blockdev.c b/blockdev.c inde

[Qemu-devel] [PATCH 15/46] vdi: basic conversion to coroutines

2012-04-05 Thread Kevin Wolf
From: Paolo Bonzini Even a basic conversion changing the bdrv_aio_readv/bdrv_aio_writev calls to bdrv_co_readv/bdrv_co_writev, and callbacks to goto statements can eliminate a lot of code. This is because error handling is simplified and indirections through bottom halves can go away. After thi

[Qemu-devel] [PATCH 11/46] block/vpc: write checksum back to footer after check

2012-04-05 Thread Kevin Wolf
From: Zhang Shengju After validation check, the 'checksum' is not written back to footer, which leave it with zero. This results in errors while loadding it under Microsoft's Hyper-V environment, and also errors from utilities like Citrix's vhd-util. Signed-off-by: Zhang Shengju Signed-off-by:

  1   2   >