Re: [Qemu-devel] [PATCH 2/2] Monitor: Make output buffer dynamic

2013-03-26 Thread Wenchao Xia
Hi, Luiz Personally I hope reduce the dynamic allocated buffer which brings fragments and unexpected memory grow. Instead, how about sacrifice some time to wait output complete, since monitor is not time critical? in this case static buffer's size can decide how many work can be postponded. Follo

Re: [Qemu-devel] [PATCH 0/5] Add some tracepoints for clarification of the cause of troubles

2013-03-26 Thread Kazuya Saito
(2013/03/26 16:15), Paolo Bonzini wrote: > Il 26/03/2013 08:13, Kazuya Saito ha scritto: I'm not sure 4-5 are that useful, but the first 3 patches are definitely good stuff. >> Thanks. I'll modify the patch you pointed out about CPU number and >> re-post it. >> I'd like to add tracep

Re: [Qemu-devel] [PATCH 1/4] net: ensure "socket" backend uses non-blocking fds

2013-03-26 Thread Stefan Hajnoczi
On Tue, Mar 26, 2013 at 10:33:45AM -0600, Eric Blake wrote: > On 03/26/2013 10:07 AM, Stefan Hajnoczi wrote: > > 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 a

Re: [Qemu-devel] [PATCH 1/4] net: ensure "socket" backend uses non-blocking fds

2013-03-26 Thread Stefan Hajnoczi
On Tue, Mar 26, 2013 at 05:25:50PM +0100, Juan Quintela wrote: > Stefan Hajnoczi wrote: > > 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. > > > >

Re: [Qemu-devel] [PATCH v3] block: Add support for Secure Shell (ssh) block device.

2013-03-26 Thread Stefan Hajnoczi
On Tue, Mar 26, 2013 at 07:34:43PM +, Richard W.M. Jones wrote: > > BTW, I'd be interested in tips on what software/techniques people use > for benchmarking qemu block devices. > > So far I've been testing this by booting various guests and timing how > long they take to reach various stages

[Qemu-devel] [PATCH] hw/i386/pc: reject to boot a wrong header magic kernel

2013-03-26 Thread liguang
if head magic is missing or wrong unexpectedly, we'd better to reject booting. e.g. I make a mistake to boot a vmlinuz for MIPS(which I think it's for x86) like this: qemu-system-x86_64 -kernel vmlinuz -initrd demord then qemu report: "qemu: linux kernel too old to load a ram disk" that's misleadin

[Qemu-devel] [Bug 1158912] Re: QEMU Version 1.4.0 - SLIRP hangs VM

2013-03-26 Thread Kenneth Salerno
Sorry for the confusion, I was impatient for the first bisect run to complete - this time I figured out how to automate the testing portion of the git bisect run script so I could walk away and let it run until full completion. Here is the result: acbb090b2400f627a801074c4e3e006c7501bb26 is the f

Re: [Qemu-devel] [RFC] qmp interface for save vmstate to image

2013-03-26 Thread Wenchao Xia
> With a deeper thinking, I'd like to share some more analyse: Vmstate saving equals memory snapshotting, to do it in theory methods can be concluded as: 1 get a mirror of it just in the time sending the "snapshot" request, kernel cow that region. 2 get a mirror of it by gradually coping out the

Re: [Qemu-devel] [RFC PATCH v4 00/30] ACPI memory hotplug

2013-03-26 Thread li guang
在 2013-03-26二的 17:43 +0100,Vasilis Liaskovitis写道: > Hi, > > On Tue, Mar 19, 2013 at 03:28:38PM +0800, li guang wrote: > [...] > > > > > This is v4 of the ACPI memory hotplug functionality. Only x86_64 > > > > > target is > > > > > supported (both i440fx and q35). There are still several issues, b

Re: [Qemu-devel] [RFC PATCH v4 00/30] ACPI memory hotplug

2013-03-26 Thread li guang
在 2013-03-26二的 17:58 +0100,Vasilis Liaskovitis写道: > Hi, > > On Tue, Mar 19, 2013 at 02:30:25PM +0800, li guang wrote: > > 在 2013-01-10四的 19:57 +0100,Vasilis Liaskovitis写道: > > > > > > > > > > IIRC q35 supports memory hotplug natively (picked up in some > > > > > discussion). Is that correct? > >

Re: [Qemu-devel] coroutine: hung when using gthread backend

2013-03-26 Thread Wenchao Xia
于 2013-3-26 17:56, Peter Maydell 写道: On 26 March 2013 09:54, Stefan Hajnoczi wrote: On Tue, Mar 26, 2013 at 08:03:50AM +0100, Paolo Bonzini wrote: coroutine backend gthread hardly works for qemu, only qemu-io and qemu-img. Do you know why it doesn't work? Because nobody tests it? -- PMM

Re: [Qemu-devel] coroutine: hung when using gthread backend

2013-03-26 Thread Wenchao Xia
于 2013-3-27 0:21, Stefan Hajnoczi 写道: On Tue, Mar 26, 2013 at 11:03:53AM +0100, Paolo Bonzini wrote: Il 26/03/2013 10:54, Stefan Hajnoczi ha scritto: On Tue, Mar 26, 2013 at 08:03:50AM +0100, Paolo Bonzini wrote: Il 26/03/2013 03:50, Wenchao Xia ha scritto: When I using tcg with coroutine

Re: [Qemu-devel] [RFC PATCH 04/10] qemu-ga: Add Windows VSS provider to quiesce applications on fsfreeze

2013-03-26 Thread Tomoki Sekiyama
On 3/26/13 4:44 , "Vadim Rozenfeld" wrote: >On Tue, 2013-03-26 at 08:09 +0100, Paolo Bonzini wrote: >> Il 25/03/2013 21:50, Tomoki Sekiyama ha scritto: >>> Unfortunately, if I remove importlib("stdole2.tlb"), generated .tlb >>>seems >> > rejected to register into Windows COM+ Catalog. >> > >> >

Re: [Qemu-devel] [PATCH] tcg-s390: Fix movi

2013-03-26 Thread Alexander Graf
On 26.03.2013, at 01:11, Richard Henderson wrote: > The code to load the high 64 bits assumed that the insn used to > load the low 64 bits zero-extended. Enforce that. > > Cc: Alexander Graf > Signed-off-by: Richard Henderson Tested-by: Alexander Graf Though running an s390x guest on an s3

Re: [Qemu-devel] Minor fixes to OS X.

2013-03-26 Thread Peter Maydell
On 26 March 2013 22:18, C.W. Betts wrote: > This patch contains minor fixes for the Cocoa UI. (cc'ing Andreas as the Cocoa maintainer) > From c36f0f8e4602fe014a3a383d6bb181401e72e8fe Mon Sep 17 00:00:00 2001 > From: "C.W. Betts" > Date: Sun, 24 Mar 2013 11:52:14 -0600 > Subject: [PATCH 2/3] Min

[Qemu-devel] Minor fixes to OS X.

2013-03-26 Thread C.W. Betts
This patch contains minor fixes for the Cocoa UI. From c36f0f8e4602fe014a3a383d6bb181401e72e8fe Mon Sep 17 00:00:00 2001 From: "C.W. Betts" Date: Sun, 24 Mar 2013 11:52:14 -0600 Subject: [PATCH 2/3] Minor Cocoa UI improvements. Use fileSystemRepresentation to get a file name from an NSString. D

[Qemu-devel] [patch]Make GTK build on OS X

2013-03-26 Thread C.W. Betts
This patch makes the GTK UI build on OS X by including the right headers. From b5cc84343f479d4870961c82fc7b384637e9616c Mon Sep 17 00:00:00 2001 From: "C.W. Betts" Date: Sun, 24 Mar 2013 11:24:05 -0600 Subject: [PATCH 1/3] Make the GTK UI build on OS X. --- ui/gtk.c | 5 + 1 file changed,

Re: [Qemu-devel] [PATCH v2 12/12] savevm: icrease the IO_BUF_SIZE to improve the speed of savevm

2013-03-26 Thread Eric Blake
On 03/22/2013 07:16 AM, Pavel Hrdina wrote: s/icrease/increase/ in the subject Some benchmark numbers in the commit message justifying your change would be nice. > Signed-off-by: Pavel Hrdina > --- > savevm.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/savevm.c b/

Re: [Qemu-devel] [PATCH v2 11/12] vm-snapshot-save: add force parameter

2013-03-26 Thread Eric Blake
On 03/22/2013 07:16 AM, Pavel Hrdina wrote: > HMP command "savevm" now takes extra optional force parameter to specify > whether > replace existing snapshot or not. > > QMP command "vm-snapshot-save" has also extra optional force parameter and > name parameter isn't optional anymore. Again, my q

Re: [Qemu-devel] [PATCH v2 10/12] savevm: update return value from qemu_savevm_state

2013-03-26 Thread Eric Blake
On 03/22/2013 07:16 AM, Pavel Hrdina wrote: > Signed-off-by: Pavel Hrdina > --- The commit message could usefully explain _why_ it is okay to collapse all error values into one. As written, the code appears accurate; and the lone caller (do_savevm) handles the new semantics. But this goes back

Re: [Qemu-devel] [PATCH v2 09/12] block: update return value from bdrv_snapshot_create

2013-03-26 Thread Eric Blake
On 03/22/2013 07:16 AM, Pavel Hrdina wrote: > If we provide error message, we should also provide a return code. > In some cases we could not care about any error message and the return > code is enough for as. > > Signed-off-by: Pavel Hrdina > --- > +++ b/qemu-img.c > @@ -1943,6 +1943,7 @@ stat

[Qemu-devel] [PATCH] Fix some memory leaks in test-visitor-serialization

2013-03-26 Thread Stefan Berger
This patch fixes some of the memory leaks in test-visitor-serialization but not all of them. Signed-off-by: Stefan Berger --- tests/test-visitor-serialization.c | 17 ++--- 1 file changed, 14 insertions(+), 3 deletions(-) Index: qemu-git.pt/tests/test-visitor-serialization.c ==

Re: [Qemu-devel] [PATCH v2 08/12] qemu-img: introduce qemu_img_handle_error

2013-03-26 Thread Eric Blake
On 03/22/2013 07:16 AM, Pavel Hrdina wrote: > Signed-off-by: Pavel Hrdina > --- > qemu-img.c | 11 +-- > 1 file changed, 9 insertions(+), 2 deletions(-) > > diff --git a/qemu-img.c b/qemu-img.c > index 21d02bf..34badad 100644 > --- a/qemu-img.c > +++ b/qemu-img.c > @@ -322,6 +322,14 @@ s

Re: [Qemu-devel] [PATCH v2 07/11] versatile_pci: Implement the correct PCI IRQ mapping

2013-03-26 Thread Michael S. Tsirkin
On Tue, Mar 26, 2013 at 11:17:55AM +, Peter Maydell wrote: > On 26 March 2013 11:08, Arnd Bergmann wrote: > > On Tuesday 26 March 2013, Peter Maydell wrote: > >> On 26 March 2013 10:54, Arnd Bergmann wrote: > >> > Yes, very good. We will probably introduce sparse irq support on > >> > versat

Re: [Qemu-devel] [PATCH 09/10] mipsn32-linux-user: Restrict address space to 31-bits.

2013-03-26 Thread Richard Henderson
On 03/26/2013 12:50 PM, Aurelien Jarno wrote: >>> > > -# ifdef TARGET_MIPS >>> > > +# if HOST_LONG_BITS == 64 \ >>> > > + && (defined(TARGET_ABI_MIPSO32) || defined(TARGET_ABI_MIPSN32)) >>> > > /* MIPS only supports 31 bits of virtual address space for user space >>> > > */ >>> > > -unsigned

Re: [Qemu-devel] [PATCH v2 07/12] qapi: Convert savevm

2013-03-26 Thread Eric Blake
On 03/22/2013 07:16 AM, Pavel Hrdina wrote: > Signed-off-by: Pavel Hrdina > --- > hmp-commands.hx | 4 ++-- > hmp.c | 9 + > hmp.h | 1 + > include/sysemu/sysemu.h | 1 - > qapi-schema.json| 18 ++ > qmp-commands.hx

Re: [Qemu-devel] [PATCH 09/10] mipsn32-linux-user: Restrict address space to 31-bits.

2013-03-26 Thread Aurelien Jarno
On Tue, Mar 05, 2013 at 03:03:44PM +0100, Aurelien Jarno wrote: > On Sun, Feb 10, 2013 at 10:30:49AM -0800, Richard Henderson wrote: > > Signed-off-by: Richard Henderson > > --- > > linux-user/main.c | 12 ++-- > > 1 file changed, 6 insertions(+), 6 deletions(-) > > > > diff --git a/linu

Re: [Qemu-devel] [PATCH v2 06/12] savevm: add error parameter to qemu_savevm_state()

2013-03-26 Thread Eric Blake
On 03/22/2013 07:16 AM, Pavel Hrdina wrote: > Signed-off-by: Pavel Hrdina > --- > savevm.c | 12 ++-- > 1 file changed, 6 insertions(+), 6 deletions(-) > Reviewed-by: Eric Blake -- Eric Blake eblake redhat com+1-919-301-3266 Libvirt virtualization library http://libvirt.org

Re: [Qemu-devel] [PATCH v2 05/12] savevm: add error parameter to qemu_savevm_state_complete()

2013-03-26 Thread Eric Blake
On 03/22/2013 07:16 AM, Pavel Hrdina wrote: > Signed-off-by: Pavel Hrdina > --- > include/sysemu/sysemu.h | 2 +- > migration.c | 2 +- > savevm.c| 5 +++-- > 3 files changed, 5 insertions(+), 4 deletions(-) > > @@ -1734,6 +1734,7 @@ void qemu_savevm_state_complete(Q

Re: [Qemu-devel] [PATCH v3] block: Add support for Secure Shell (ssh) block device.

2013-03-26 Thread Richard W.M. Jones
BTW, I'd be interested in tips on what software/techniques people use for benchmarking qemu block devices. So far I've been testing this by booting various guests and timing how long they take to reach various stages (eg. graphical login), but this has not proven to be reproducible. Rich. -- R

[Qemu-devel] [PULL] virtio,pci,qom

2013-03-26 Thread Michael S. Tsirkin
The following changes since commit b1999e87b4d42305419329cae459e1b43f706d96: Fix TAGS creation (2013-03-15 11:36:49 -0500) are available in the git repository at: git://git.kernel.org/pub/scm/virt/kvm/mst/qemu.git tags/for_anthony for you to fetch changes up to 6214e73cc5b75a4f8d89a70d71727

[Qemu-devel] [PATCH 01/10] target-i386: SSE4.1: fix pinsrb instruction

2013-03-26 Thread Aurelien Jarno
gen_op_mov_TN_reg() loads the value in cpu_T[0], so this temporary should be used instead of cpu_tmp0. Signed-off-by: Aurelien Jarno --- target-i386/translate.c |4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/target-i386/translate.c b/target-i386/translate.c index 7239

[Qemu-devel] [PATCH 00/10] target-i386: fix and enable SSE4.1 and SSE4.2

2013-03-26 Thread Aurelien Jarno
SSE4.1 and SSE4.2 instruction sets are partly broken, at least enough to render a recent glibc with ifunc enabled unusable. This patch series fixes the issues, it has been tested with the valgrind testsuite in user mode and by booting x86 and x86-64 guests with a recent glibc in system mode. Aur

[Qemu-devel] [PATCH 09/10] target-i386: enable SSE4.1 and SSE4.2 in TCG mode

2013-03-26 Thread Aurelien Jarno
Signed-off-by: Aurelien Jarno --- target-i386/cpu.c | 13 +++-- 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/target-i386/cpu.c b/target-i386/cpu.c index a0640db..4b43759 100644 --- a/target-i386/cpu.c +++ b/target-i386/cpu.c @@ -388,16 +388,17 @@ typedef struct x86_def_

[Qemu-devel] [PATCH 02/10] target-i386: SSE4.2: fix pcmpgtq instruction

2013-03-26 Thread Aurelien Jarno
The "Intel 64 and IA-32 Architectures Software Developer's Manual" (at least recent versions) clearly says that the comparison is signed. Signed-off-by: Aurelien Jarno --- target-i386/ops_sse.h |3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/target-i386/ops_sse.h b/targe

[Qemu-devel] [PATCH 06/10] target-i386: SSE4.2: fix pcmpXstrX instructions in "Equal each" mode

2013-03-26 Thread Aurelien Jarno
pcmpXstrX instructions in "Equal each" mode force both invalid element pair to true. It means (upper - MAX(valids, validd)) bits should be set to 1, not (upper - MAX(valids, validd) + 1). Signed-off-by: Aurelien Jarno --- target-i386/ops_sse.h |2 +- 1 file changed, 1 insertion(+), 1 deletio

[Qemu-devel] [PATCH 04/10] target-i386: SSE4.2: fix pcmpXstrm instructions

2013-03-26 Thread Aurelien Jarno
pcmpXstrm instructions returns their result in the XMM0 register and not in the first operand. Signed-off-by: Aurelien Jarno --- target-i386/ops_sse.h | 16 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/target-i386/ops_sse.h b/target-i386/ops_sse.h index 0667c8

[Qemu-devel] [PATCH 03/10] target-i386: SSE4.2: fix pcmpXstri instructions

2013-03-26 Thread Aurelien Jarno
ffs1 returns the first bit set to one starting counting from the most significant bit. pcmpXstri returns the most significant bit set to one, starting counting from the least significant bit. Signed-off-by: Aurelien Jarno --- target-i386/ops_sse.h |4 ++-- 1 file changed, 2 insertions(+), 2

[Qemu-devel] [PATCH 10/10] target-i386: SSE4.2: use clz32/ctz32 instead of reinventing the wheel

2013-03-26 Thread Aurelien Jarno
Signed-off-by: Aurelien Jarno --- target-i386/fpu_helper.c |1 + target-i386/ops_sse.h| 32 ++-- 2 files changed, 3 insertions(+), 30 deletions(-) diff --git a/target-i386/fpu_helper.c b/target-i386/fpu_helper.c index 44f3d27..29a8fb6 100644 --- a/target-i38

[Qemu-devel] [PATCH 07/10] target-i386: SSE4.2: fix pcmpXstrX instructions in "Equal ordered" mode

2013-03-26 Thread Aurelien Jarno
The inner loop should only change the current bit of the result, instead of the whole result. Signed-off-by: Aurelien Jarno --- target-i386/ops_sse.h |5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/target-i386/ops_sse.h b/target-i386/ops_sse.h index 2fc5fdd..77ab410 1

[Qemu-devel] [PATCH 05/10] target-i386: SSE4.2: fix pcmpXstrX instructions in "Ranges" mode

2013-03-26 Thread Aurelien Jarno
Fix the order of the of the comparisons to match the "Intel 64 and IA-32 Architectures Software Developer's Manual". Signed-off-by: Aurelien Jarno --- target-i386/ops_sse.h |4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/target-i386/ops_sse.h b/target-i386/ops_sse.h in

[Qemu-devel] [PATCH 08/10] target-i386: SSE4.2: fix pcmpXstrX instructions with "Masked(-)" polarity

2013-03-26 Thread Aurelien Jarno
valids can equals to -1 if the reg/mem string is empty. Change the expression to have an empty xor mask in that case. Signed-off-by: Aurelien Jarno --- target-i386/ops_sse.h |2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/target-i386/ops_sse.h b/target-i386/ops_sse.h index

Re: [Qemu-devel] [PATCH v5 00/10] virtio-scsi refactoring.

2013-03-26 Thread Anthony Liguori
Applied. Thanks. Regards, Anthony Liguori

Re: [Qemu-devel] [PATCH v4] hw/qdev-properties.c: Improve diagnostic for setting property after realize

2013-03-26 Thread Anthony Liguori
Applied. Thanks. Regards, Anthony Liguori

Re: [Qemu-devel] [PATCH for-next v3 0/5] qtest: tmp105 cleanups and MMIO support

2013-03-26 Thread Anthony Liguori
Applied. Thanks. Regards, Anthony Liguori

Re: [Qemu-devel] [PATCH v7 0/2] qdev: Detect duplicate device properties

2013-03-26 Thread Anthony Liguori
Applied. Thanks. Regards, Anthony Liguori

Re: [Qemu-devel] [PATCH 0/9] chardev: qapi conversion continued

2013-03-26 Thread Anthony Liguori
Applied. Thanks. Regards, Anthony Liguori

[Qemu-devel] [PATCH v2 05/21] qcow2: Improve check for overlapping allocations

2013-03-26 Thread Kevin Wolf
The old code detected an overlapping allocation even when the allocations didn't actually overlap, but were only adjacent. Signed-off-by: Kevin Wolf Reviewed-by: Eric Blake --- block/qcow2-cluster.c | 2 +- tests/qemu-iotests/038.out | 10 +- 2 files changed, 6 insertions(+), 6 de

Re: [Qemu-devel] selecting a sparc framebuffer from command line

2013-03-26 Thread Artyom Tarasenko
On Tue, Mar 26, 2013 at 4:08 PM, Bob Breuer wrote: > On 3/26/2013 6:13 AM, Artyom Tarasenko wrote: >> It looks like we will have more framebuffers beside TCX in the near future. >> One way to use them would be to make new machines combining a base >> machine name with a framebuffer name, like ss5t

[Qemu-devel] [PATCH v2 10/21] qcow2: handle_alloc(): Get rid of keep_clusters parameter

2013-03-26 Thread Kevin Wolf
handle_alloc() is now called with the offset at which the actual new allocation starts instead of the offset at which the whole write request starts, part of which may already be processed. Signed-off-by: Kevin Wolf --- block/qcow2-cluster.c | 44 +++- blo

Re: [Qemu-devel] [PATCH v2 04/12] savevm: add error parameter to qemu_savevm_state_iterate()

2013-03-26 Thread Eric Blake
On 03/22/2013 07:16 AM, Pavel Hrdina wrote: > Signed-off-by: Pavel Hrdina > --- > include/sysemu/sysemu.h | 2 +- > migration.c | 2 +- > savevm.c| 5 ++--- > 3 files changed, 4 insertions(+), 5 deletions(-) > Reviewed-by: Eric Blake > @@ -1811,9 +1811,8 @@ static

[Qemu-devel] [PATCH] [PULL] virtio-ccw fix.

2013-03-26 Thread Cornelia Huck
The ccw notify hypercall handler was missing a sanity check for the queue number, making it possible for an ill-behaving caller to crash qemu. Not good. Please pull. The following changes since commit e769bdc26ded6d7681cddd9f67c5f87a4b5ba53c: hw/qdev: Abort rather than ignoring errors adding d

[Qemu-devel] [PATCH] virtio-ccw: Queue sanity check for notify hypercall.

2013-03-26 Thread Cornelia Huck
Verify that the virtio-ccw notify hypercall passed a reasonable value for queue. Cc: qemu-sta...@nongnu.org Reported-by: Alexander Graf Signed-off-by: Cornelia Huck --- hw/s390x/s390-virtio-ccw.c |3 +++ 1 file changed, 3 insertions(+) diff --git a/hw/s390x/s390-virtio-ccw.c b/hw/s390x/s39

Re: [Qemu-devel] [PATCH 11/12 v3] qmp: add cpu-add qmp command

2013-03-26 Thread Igor Mammedov
On Tue, 26 Mar 2013 10:54:39 -0600 Eric Blake wrote: > On 03/26/2013 10:47 AM, Igor Mammedov wrote: > > Signed-off-by: Igor Mammedov > > --- > > v3: > > * it appears that 'online/offline' in cpu-set are confusing people > > with what command actually does and users might have to distinguis

Re: [Qemu-devel] [RFC PATCH v4 00/30] ACPI memory hotplug

2013-03-26 Thread Vasilis Liaskovitis
Hi, On Tue, Mar 26, 2013 at 10:47:01AM -0400, Luiz Capitulino wrote: > On Tue, 18 Dec 2012 13:41:28 +0100 > Vasilis Liaskovitis wrote: > > > This is v4 of the ACPI memory hotplug functionality. Only x86_64 target is > > supported (both i440fx and q35). There are still several issues, but it's >

Re: [Qemu-devel] [PATCH v3] block: Add support for Secure Shell (ssh) block device.

2013-03-26 Thread Richard W.M. Jones
On Tue, Mar 26, 2013 at 05:23:03PM +0100, Stefan Hajnoczi wrote: > On Tue, Mar 26, 2013 at 02:21:39PM +, Richard W.M. Jones wrote: > > On Tue, Mar 26, 2013 at 10:38:46AM +, Richard W.M. Jones wrote: > > > +/* According to the docs, this just updates a field in the > > > + * sftp_han

Re: [Qemu-devel] [PATCH 11/12 v3] qmp: add cpu-add qmp command

2013-03-26 Thread Eric Blake
On 03/26/2013 10:47 AM, Igor Mammedov wrote: > Signed-off-by: Igor Mammedov > --- > v3: > * it appears that 'online/offline' in cpu-set are confusing people > with what command actually does and users might have to distinguish > if 'offline' is not implemented by parsing error message. T

Re: [Qemu-devel] [RFC PATCH v4 00/30] ACPI memory hotplug

2013-03-26 Thread Vasilis Liaskovitis
Hi, On Tue, Mar 19, 2013 at 02:30:25PM +0800, li guang wrote: > 在 2013-01-10四的 19:57 +0100,Vasilis Liaskovitis写道: > > > > > > > > IIRC q35 supports memory hotplug natively (picked up in some > > > > discussion). Is that correct? > > > > > > > From previous discussion I also understand that q35

[Qemu-devel] [PATCH v2 11/21] qcow2: Finalise interface of handle_alloc()

2013-03-26 Thread Kevin Wolf
The interface works completely on a byte granularity now and duplicated parameters are removed. Signed-off-by: Kevin Wolf --- block/qcow2-cluster.c | 29 - block/qcow2.h | 5 + 2 files changed, 21 insertions(+), 13 deletions(-) diff --git a/block/qcow2-c

[Qemu-devel] [PATCH v2 21/21] qcow2: Gather clusters in a looping loop

2013-03-26 Thread Kevin Wolf
Instead of just checking once in exactly this order if there are dependendies, non-COW clusters and new allocation, this starts looping around these. This way we can, for example, gather non-COW clusters after new allocations as long as the host cluster offsets stay contiguous. Once handle_depende

[Qemu-devel] [PATCH v2 16/21] qcow2: handle_copied(): Implement non-zero host_offset

2013-03-26 Thread Kevin Wolf
Look only for clusters that start at a given physical offset. Signed-off-by: Kevin Wolf --- block/qcow2-cluster.c | 28 1 file changed, 20 insertions(+), 8 deletions(-) diff --git a/block/qcow2-cluster.c b/block/qcow2-cluster.c index 5e5465d..239a997 100644 --- a/bl

[Qemu-devel] [PATCH v2 20/21] qcow2: Move cluster gathering to a non-looping loop

2013-03-26 Thread Kevin Wolf
This patch is mainly to separate the indentation change from the semantic changes. All that really changes here is that everything moves into a while loop, all 'goto done' become 'break' and at the end of the loop a new 'break is inserted. Signed-off-by: Kevin Wolf --- block/qcow2-cluster.c | 13

[Qemu-devel] [PATCH v2 19/21] qcow2: Allow requests with multiple l2metas

2013-03-26 Thread Kevin Wolf
Instead of expecting a single l2meta, have a list of them. This allows to still have a single I/O request for the guest data, even though multiple l2meta may be needed in order to describe both a COW overwrite and a new cluster allocation (typical sequential write case). Signed-off-by: Kevin Wolf

[Qemu-devel] [PATCH v2 14/21] qcow2: handle_copied(): Get rid of nb_clusters parameter

2013-03-26 Thread Kevin Wolf
handle_copied() uses its bytes parameter now to determine how many clusters it should try to find. Signed-off-by: Kevin Wolf --- block/qcow2-cluster.c | 24 ++-- 1 file changed, 18 insertions(+), 6 deletions(-) diff --git a/block/qcow2-cluster.c b/block/qcow2-cluster.c index

[Qemu-devel] [PATCH v2 18/21] qcow2: Use byte granularity in qcow2_alloc_cluster_offset()

2013-03-26 Thread Kevin Wolf
This gets rid of the nb_clusters and keep_clusters and the associated complicated calculations. Just advance the number of bytes that have been processed and everything is fine. This patch advances the variables even after the last operation even though they aren't used any more afterwards to make

[Qemu-devel] [PATCH v2 12/21] qcow2: Clean up handle_alloc()

2013-03-26 Thread Kevin Wolf
Things can be simplified a bit now. No semantic changes. Signed-off-by: Kevin Wolf --- block/qcow2-cluster.c | 110 -- 1 file changed, 53 insertions(+), 57 deletions(-) diff --git a/block/qcow2-cluster.c b/block/qcow2-cluster.c index 8ed1f7d..1141

[Qemu-devel] [PATCH v2 15/21] qcow2: handle_copied(): Get rid of keep_clusters parameter

2013-03-26 Thread Kevin Wolf
Now *bytes is used to return the length of the area that can be written to without performing an allocation or COW. Signed-off-by: Kevin Wolf --- block/qcow2-cluster.c | 23 +-- 1 file changed, 13 insertions(+), 10 deletions(-) diff --git a/block/qcow2-cluster.c b/block/qcow

[Qemu-devel] [PATCH v2 13/21] qcow2: Factor out handle_copied()

2013-03-26 Thread Kevin Wolf
Signed-off-by: Kevin Wolf --- block/qcow2-cluster.c | 134 +++--- trace-events | 1 + 2 files changed, 95 insertions(+), 40 deletions(-) diff --git a/block/qcow2-cluster.c b/block/qcow2-cluster.c index 1141483..9036bd8 100644 --- a/block/qco

[Qemu-devel] [PATCH v2 17/21] qcow2: Prepare handle_alloc/copied() for byte granularity

2013-03-26 Thread Kevin Wolf
This makes handle_alloc() and handle_copied() return byte-granularity host offsets instead of returning always the cluster start. This is required so that qcow2_alloc_cluster_offset() can stop aligning everything to cluster boundaries. Signed-off-by: Kevin Wolf --- block/qcow2-cluster.c | 25 +++

[Qemu-devel] [PATCH v2 08/21] qcow2: Factor out handle_alloc()

2013-03-26 Thread Kevin Wolf
Signed-off-by: Kevin Wolf --- block/qcow2-cluster.c | 240 +++--- trace-events | 1 + 2 files changed, 152 insertions(+), 89 deletions(-) diff --git a/block/qcow2-cluster.c b/block/qcow2-cluster.c index 9550927..454a30c 100644 --- a/block/qc

[Qemu-devel] [PATCH v2 07/21] qcow2: Decouple cluster allocation from cluster reuse code

2013-03-26 Thread Kevin Wolf
This moves some code that prepares the allocation of new clusters to where the actual allocation happens. This is the minimum required to be able to move it to a separate function in the next patch. Signed-off-by: Kevin Wolf --- block/qcow2-cluster.c | 35 --- 1 f

[Qemu-devel] [PATCH v2 09/21] qcow2: handle_alloc(): Get rid of nb_clusters parameter

2013-03-26 Thread Kevin Wolf
We already communicate the same information in *bytes. Signed-off-by: Kevin Wolf --- block/qcow2-cluster.c | 19 +++ 1 file changed, 15 insertions(+), 4 deletions(-) diff --git a/block/qcow2-cluster.c b/block/qcow2-cluster.c index 454a30c..009f62a 100644 --- a/block/qcow2-cluste

[Qemu-devel] [PATCH v2 00/21] qcow2: Rework cluster allocation even more

2013-03-26 Thread Kevin Wolf
This is the start of the latest Delayed COW series. As there seem to be serious problems with the actual Delayed COW (which in fact exist today, but would become a bit easier to hit) and I don't have the time to complete this at the moment, here is another series with preparatory patches, for which

[Qemu-devel] [PATCH v2 06/21] qcow2: Change handle_dependency to byte granularity

2013-03-26 Thread Kevin Wolf
This is a more precise description of what really constitutes a dependency. The behaviour doesn't change at this point because the COW area of the old request is still aligned to cluster boundaries and therefore an overlap is detected wheneven the requests touch any part of the same cluster. Signe

[Qemu-devel] [PATCH v2 03/21] qcow2: Remove bogus unlock of s->lock

2013-03-26 Thread Kevin Wolf
The unlock wakes up the next coroutine, but the currently running coroutine will lock it again before it yields, so this doesn't make a lot of sense. Signed-off-by: Kevin Wolf --- block/qcow2.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/block/qcow2.c b/block/qcow2.c index 8ea696a..3f7e

[Qemu-devel] [PATCH v2 04/21] qcow2: Handle dependencies earlier

2013-03-26 Thread Kevin Wolf
Handling overlapping allocations isn't just a detail of cluster allocation. It is rather one of three ways to get the host cluster offset for a write request: 1. If a request overlaps an in-flight allocations, the cluster offset can be taken from there (this is what handle_dependencies will evo

[Qemu-devel] [PATCH v2 01/21] qemu-iotests: More concurrent allocation scenarios

2013-03-26 Thread Kevin Wolf
Signed-off-by: Kevin Wolf --- tests/qemu-iotests/046 | 49 +- tests/qemu-iotests/046.out | 76 ++ 2 files changed, 124 insertions(+), 1 deletion(-) diff --git a/tests/qemu-iotests/046 b/tests/qemu-iotests/046 index e0176

[Qemu-devel] [PATCH v2 02/21] qcow2: Fix "total clusters" number in bdrv_check

2013-03-26 Thread Kevin Wolf
This should be based on the virtual disk size, not on the size of the image. Interesting observation: With some VM state stored in the image file, percentages higher than 100% are possible, even though snapshots themselves are ignored. This is a qcow2 bug to be fixed another day: The VM state shou

Re: [Qemu-devel] [PATCH v2 03/12] savevm: add error parameter to qemu_savevm_state_begin()

2013-03-26 Thread Eric Blake
On 03/22/2013 07:16 AM, Pavel Hrdina wrote: > Signed-off-by: Pavel Hrdina > --- > include/sysemu/sysemu.h | 3 ++- > migration.c | 2 +- > savevm.c| 6 -- > 3 files changed, 7 insertions(+), 4 deletions(-) > @@ -1807,9 +1808,10 @@ static int qemu_savevm_state(QEMU

[Qemu-devel] [PATCH 11/12 v3] qmp: add cpu-add qmp command

2013-03-26 Thread Igor Mammedov
Signed-off-by: Igor Mammedov --- v3: * it appears that 'online/offline' in cpu-set are confusing people with what command actually does and users might have to distinguish if 'offline' is not implemented by parsing error message. To simplify things replace cpu-set with cpu-add comman

Re: [Qemu-devel] [PATCH v2 02/12] block: add error parameter to del_existing_snapshots()

2013-03-26 Thread Eric Blake
On 03/22/2013 07:16 AM, Pavel Hrdina wrote: > Signed-off-by: Pavel Hrdina > --- > savevm.c | 12 +++- > 1 file changed, 7 insertions(+), 5 deletions(-) Reviewed-by: Eric Blake -- Eric Blake eblake redhat com+1-919-301-3266 Libvirt virtualization library http://libvirt.org s

Re: [Qemu-devel] [RFC PATCH v4 00/30] ACPI memory hotplug

2013-03-26 Thread Vasilis Liaskovitis
Hi, On Tue, Mar 19, 2013 at 03:28:38PM +0800, li guang wrote: [...] > > > > This is v4 of the ACPI memory hotplug functionality. Only x86_64 target > > > > is > > > > supported (both i440fx and q35). There are still several issues, but > > > > it's > > > > been a while since v3 and I wanted to g

Re: [Qemu-devel] [PATCH 4/4] chardev: clear O_NONBLOCK on SCM_RIGHTS file descriptors

2013-03-26 Thread Eric Blake
On 03/26/2013 10:07 AM, Stefan Hajnoczi wrote: > 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 ne

Re: [Qemu-devel] [PATCH 3/4] oslib-posix: rename socket_set_nonblock() to qemu_set_nonblock()

2013-03-26 Thread Eric Blake
On 03/26/2013 10:07 AM, Stefan Hajnoczi wrote: > 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 > --- Reviewed-by: Eric Blake > +++ b/util/oslib-posix.c > @@ -134,14 +134,14 @@

Re: [Qemu-devel] [PATCH 4/4] chardev: clear O_NONBLOCK on SCM_RIGHTS file descriptors

2013-03-26 Thread Juan Quintela
Stefan Hajnoczi wrote: > 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 chang

Re: [Qemu-devel] [PATCH 3/4] oslib-posix: rename socket_set_nonblock() to qemu_set_nonblock()

2013-03-26 Thread Juan Quintela
Stefan Hajnoczi wrote: > 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 > --- > block/nbd.c| 2 +- > block/sheepdog.c | 2 +- > include/qemu/sockets.h | 4 ++

Re: [Qemu-devel] [PATCH 2/4] qemu-socket: set passed fd non-blocking in socket_connect()

2013-03-26 Thread Eric Blake
On 03/26/2013 10:07 AM, Stefan Hajnoczi wrote: > 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

Re: [Qemu-devel] [PATCH 1/4] net: ensure "socket" backend uses non-blocking fds

2013-03-26 Thread Juan Quintela
Stefan Hajnoczi wrote: > 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 >

Re: [Qemu-devel] [PATCH 1/4] net: ensure "socket" backend uses non-blocking fds

2013-03-26 Thread Eric Blake
On 03/26/2013 10:07 AM, Stefan Hajnoczi wrote: > 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.

Re: [Qemu-devel] [PATCH 2/4] qemu-socket: set passed fd non-blocking in socket_connect()

2013-03-26 Thread Juan Quintela
Stefan Hajnoczi wrote: > 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 > --- > util/qemu-sock

[Qemu-devel] [PATCH v2] QOM-ify the TPM support

2013-03-26 Thread Stefan Berger
QOM-ified the TPM support with much code borrowed from the rng implementation. What's missing may be that the tpm/tpm_passthrough.c be moved into backends/ . Signed-off-by: Stefan Berger --- v1->v2: - followed to git revision e769bdc26 --- backends/Makefile.objs |2 backends/tpm.c

Re: [Qemu-devel] [PATCH v3] block: Add support for Secure Shell (ssh) block device.

2013-03-26 Thread Stefan Hajnoczi
On Tue, Mar 26, 2013 at 02:21:39PM +, Richard W.M. Jones wrote: > On Tue, Mar 26, 2013 at 10:38:46AM +, Richard W.M. Jones wrote: > > +/* According to the docs, this just updates a field in the > > + * sftp_handle structure, so there is no network traffic and it > > + * cannot f

Re: [Qemu-devel] coroutine: hung when using gthread backend

2013-03-26 Thread Stefan Hajnoczi
On Tue, Mar 26, 2013 at 11:03:53AM +0100, Paolo Bonzini wrote: > Il 26/03/2013 10:54, Stefan Hajnoczi ha scritto: > > On Tue, Mar 26, 2013 at 08:03:50AM +0100, Paolo Bonzini wrote: > >> Il 26/03/2013 03:50, Wenchao Xia ha scritto: > >>> When I using tcg with coroutine backend = gthread, > >>> x86

Re: [Qemu-devel] [PATCH] virtio-blk-x: fix configuration synchronization.

2013-03-26 Thread KONRAD Frédéric
On 22/03/2013 20:41, Anthony Liguori wrote: KONRAD Frédéric writes: On 22/03/2013 19:52, Kevin Wolf wrote: Am 22.03.2013 um 19:17 hat KONRAD Frédéric geschrieben: On 22/03/2013 17:58, Kevin Wolf wrote: Am 20.03.2013 um 10:00 hat fred.kon...@greensocs.com geschrieben: From: KONRAD Frederic

[Qemu-devel] [PATCH 3/4] oslib-posix: rename socket_set_nonblock() to qemu_set_nonblock()

2013-03-26 Thread Stefan Hajnoczi
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 --- block/nbd.c| 2 +- block/sheepdog.c | 2 +- include/qemu/sockets.h | 4 ++-- migration.c| 2 +- nbd

[Qemu-devel] [PATCH 1/4] net: ensure "socket" backend uses non-blocking fds

2013-03-26 Thread Stefan Hajnoczi
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

[Qemu-devel] [PATCH 2/4] qemu-socket: set passed fd non-blocking in socket_connect()

2013-03-26 Thread Stefan Hajnoczi
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 --- util/qemu-sockets.c | 1 + 1 file changed, 1 insert

[Qemu-devel] [PATCH 4/4] chardev: clear O_NONBLOCK on SCM_RIGHTS file descriptors

2013-03-26 Thread Stefan Hajnoczi
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 exp

[Qemu-devel] [PATCH 0/4] monitor: do not rely on O_NONBLOCK for passed file descriptors

2013-03-26 Thread Stefan Hajnoczi
There are several places where QEMU accidentally relies on the O_NONBLOCK state of passed file descriptors. Exposing O_NONBLOCK state makes it part of the QMP API whenever getfd or fdset_add_fd are used! Whether or not QEMU will use O_NONBLOCK is an implementation detail and should be hidden from

Re: [Qemu-devel] [PATCH 14/22] instrument: [qmp, qapi] Add control interface

2013-03-26 Thread Lluís Vilanova
Eric Blake writes: > On 03/26/2013 08:01 AM, Lluís Vilanova wrote: >> Add QMP commands to control (un)loading of dynamic instrumentation library. >> >> Signed-off-by: Lluís Vilanova >> --- >> include/qapi/qmp/qerror.h |9 + >> instrument/Makefile.objs|1 + >> instrument/qapi-sche

  1   2   3   >