[Qemu-devel] [Bug 1349972] Re: qcow2-refcount: qemu-io crashes on 'discard' command

2015-05-05 Thread Sam Azer
FWIW: While trying to restore (apply) a snapshot on a Windows VM (ie: qemu-img snapshot -a snapshotname windows.qcow2 where the image file is 150gb in size,) I got the above error: qemu-img: /build/buildd/qemu-2.0.0+dfsg/block/qcow2-refcount.c:467: update_refcount_discard: Assertion `d->bytes + l

Re: [Qemu-devel] [PATCH v6 15/17] target-s390x: Extend arch specific QMP command query-cpu-definitions

2015-05-05 Thread Eduardo Habkost
On Mon, Apr 27, 2015 at 04:53:29PM +0200, Michael Mueller wrote: [...] > diff --git a/target-s390x/kvm.c b/target-s390x/kvm.c > index 4d75ff0..94fede5 100644 > --- a/target-s390x/kvm.c > +++ b/target-s390x/kvm.c > @@ -276,12 +276,59 @@ static int cpu_model_set(KVMState *s, uint64_t attr, > void *a

Re: [Qemu-devel] [PATCH 3/3] target-mips: Misaligned Memory Accesses for MSA

2015-05-05 Thread Leon Alrae
On 01/05/15 16:24, Yongbok Kim wrote: > MIPS SIMD Architecture vector loads and stores require misalignment support. > MSA Memory access should work as an atomic operation. Therefore, it has to > check validity of all the addresses for the operation. As far as I can tell mips_cpu_do_unaligned_acce

Re: [Qemu-devel] [PATCH v4 0/4] scripts: qmp-shell: add transaction support

2015-05-05 Thread Luiz Capitulino
On Tue, 05 May 2015 11:34:02 -0400 John Snow wrote: > > > On 05/05/2015 08:52 AM, Luiz Capitulino wrote: > > I lost track of it. Is v4 a new posting? > > Yup. Latest with fixes. Eric re-reviewed it all and Kashyap (and I) > tested it. OK, I'm queuing it for my next pass over my qmp-patches m

[Qemu-devel] [Bug 1450881] Re: qemu-system-sparc MUTEX_HELD assert and libC lock errors

2015-05-05 Thread Mark Cave-Ayland
Yes, this is a known issue which I can reproduce using a Solaris installation. I still have a few outstanding bugs on my list to do before I can start looking into this one, but I will keep this bug up to date as/when I can start work on it - apologies for not being able to be more specific than th

Re: [Qemu-devel] [PATCH 2/4] block: Remove bdrv_reset_dirty

2015-05-05 Thread Eric Blake
On 05/05/2015 06:46 AM, Fam Zheng wrote: > Using this function woule always be wrong because a dirty bitmap must s/woule/would/ > have a specific owner that consumes the dirty bits and calls > bdrv_reset_dirty_bitmap(). > > Remove the unused function to avoid future misuse. > > Signed-off-by: F

Re: [Qemu-devel] [PATCH 3/4] qemu-iotests: Make block job methods common

2015-05-05 Thread John Snow
On 05/05/2015 08:46 AM, Fam Zheng wrote: > Signed-off-by: Fam Zheng > --- > tests/qemu-iotests/041| 66 > ++- > tests/qemu-iotests/iotests.py | 28 ++ > 2 files changed, 43 insertions(+), 51 deletions(-) > > diff --git a/tests/qe

[Qemu-devel] [PATCH v3 1/5] qtest: allow arbitrarily long sends

2015-05-05 Thread John Snow
qtest currently has a static buffer of size 1024 that if we overflow, ignores the additional data silently which leads to hangs or stream failures. Use glib's string facilities to allow arbitrarily long data, but split this off into a new function, qtest_sendf. Static data can still be sent using

[Qemu-devel] [PATCH v3 3/5] qtest: add memset to qtest protocol

2015-05-05 Thread John Snow
Previously, memset was just a frontend to write() and only stupidly sent the pattern many times across the wire. Let's not discuss who stupidly wrote it like that in the first place. (Hint: It was me.) Signed-off-by: John Snow --- qtest.c | 20 tests/libqtest.c |

[Qemu-devel] [PATCH v3 0/5] qtest: base64 r/w and faster memset

2015-05-05 Thread John Snow
Adds new qtest protocol commands for base64 reads and writes, as well as a proper command for memset instead of faking it via write. This improves the ahci-test performance on my machine from about 14 seconds to about ~3.5. v3: - Including a memset optimization. v2: - Resend as non-RFC. == For

[Qemu-devel] [PATCH v3 4/5] qtest: precompute hex nibs

2015-05-05 Thread John Snow
Instead of letting printf and friends do this for us one byte at a time, fill a buffer ourselves and then send the entire buffer in one go. This gives a moderate speed improvement over the old method. Signed-off-by: John Snow --- qtest.c | 20 tests/libqtest.c | 17

[Qemu-devel] [PATCH v3 5/5] libqos/ahci: Swap memread/write with bufread/write

2015-05-05 Thread John Snow
Where it makes sense, use the new faster primitives. For generally small reads/writes such as for the PRDT and FIS packets, stick with the more wasteful but easier to debug memread/memwrite. For ahci-test; With this patch: real0m3.675s user0m2.582s sys 0m1.718s Without this /series/:

[Qemu-devel] [PATCH v3 2/5] qtest: Add base64 encoded read/write

2015-05-05 Thread John Snow
For larger pieces of data that won't need to be debugged and viewing the hex nibbles is unlikely to be useful, we can encode data using base64 instead of encoding each byte as %02x, which leads to some space savings and faster reads/writes. For now, the default is left as hex nibbles in memwrite()

Re: [Qemu-devel] [PATCH v3 0/9] ahci: enable migration

2015-05-05 Thread John Snow
On 04/30/2015 02:07 PM, John Snow wrote: > The day we all feared is here, and I am proposing we allow the migration > of the AHCI device tentatively for the 2.4 development window. > > There are some more NCQ migration tests are needed, but I felt that it was > important to get migration enabled

[Qemu-devel] [Bug 1452062] [NEW] qemu-img will fail to convert images in 2.3.0

2015-05-05 Thread David Hill
Public bug reported: Hello guys, There seems to be a bug in qemu-img with 2.3.0 that wasn't there in 2.2.1 qemu convert will always fail converting. See the output below: Started by upstream project "Create windows image" build number 73 originally caused by: Started by user anonymo

Re: [Qemu-devel] [PATCH v3 1/5] qtest: allow arbitrarily long sends

2015-05-05 Thread Eric Blake
On 05/05/2015 04:22 PM, John Snow wrote: > qtest currently has a static buffer of size 1024 that if we > overflow, ignores the additional data silently which leads > to hangs or stream failures. > > Use glib's string facilities to allow arbitrarily long data, > but split this off into a new functi

[Qemu-devel] [PULL] Queued tcg patch

2015-05-05 Thread Richard Henderson
Only one tcg related patch since the 2.3 freeze. r~ The following changes since commit 874e9aeeeb74c5459639a93439a502d262847e68: Merge remote-tracking branch 'remotes/kraxel/tags/pull-sdl-20150505-1' into staging (2015-05-05 14:06:12 +0100) are available in the git repository

[Qemu-devel] [PULL] tcg: optimise memory layout of TCGTemp

2015-05-05 Thread Richard Henderson
From: "Emilio G. Cota" This brings down the size of the struct from 56 to 32 bytes on 64-bit, and to 20 bytes on 32-bit. This leads to memory savings: Before: $ find . -name 'tcg.o' | xargs size textdata bss dec hex filename 41131 29800 88 71019 1156b ./aarch64-so

Re: [Qemu-devel] [PATCH v3 1/5] qtest: allow arbitrarily long sends

2015-05-05 Thread John Snow
On 05/05/2015 07:22 PM, Eric Blake wrote: > On 05/05/2015 04:22 PM, John Snow wrote: >> qtest currently has a static buffer of size 1024 that if we >> overflow, ignores the additional data silently which leads to >> hangs or stream failures. >> >> Use glib's string facilities to allow arbitrari

Re: [Qemu-devel] [PATCH] s390x: Fix stoc direction

2015-05-05 Thread Richard Henderson
On 04/14/2015 06:45 PM, Alexander Graf wrote: > The store conditional instruction wants to store when the condition > is fulfilled, so we should branch out when it's not true. > > The code today branches out when the condition is true, clearly > reversing the logic. Fix it up by negating the condi

Re: [Qemu-devel] [PATCH] translate-all: remove redundant page_find from tb_invalidate_phys_page

2015-05-05 Thread Richard Henderson
On 04/08/2015 02:37 PM, Emilio G. Cota wrote: > The callers have just looked up the page descriptor, so there's no > point in searching again for it. > > Signed-off-by: Emilio G. Cota > --- > translate-all.c | 11 +++ > 1 file changed, 3 insertions(+), 8 deletions(-) Reviewed-by: Richar

Re: [Qemu-devel] [PATCH 1/4] block: Fix dirty bitmap in bdrv_co_discard

2015-05-05 Thread Fam Zheng
On Tue, 05/05 15:06, Paolo Bonzini wrote: > > > On 05/05/2015 14:46, Fam Zheng wrote: > > Unsetting dirty globally with discard is not very correct. The discard may > > zero > > out sectors (depending on can_write_zeroes_with_unmap), we should replicate > > this change to destinition side to mak

Re: [Qemu-devel] [PATCH 3/4] qemu-iotests: Make block job methods common

2015-05-05 Thread Fam Zheng
On Tue, 05/05 18:17, John Snow wrote: > > > On 05/05/2015 08:46 AM, Fam Zheng wrote: > > Signed-off-by: Fam Zheng > > --- > > tests/qemu-iotests/041| 66 > > ++- > > tests/qemu-iotests/iotests.py | 28 ++ > > 2 files changed, 43 i

Re: [Qemu-devel] [PATCH v6 1/6] Qemu-Xen-vTPM: Support for Xen stubdom vTPM command line options

2015-05-05 Thread Xu, Quan
> -Original Message- > From: Eric Blake [mailto:ebl...@redhat.com] > Sent: Tuesday, May 05, 2015 10:29 PM > To: Xu, Quan; stefano.stabell...@eu.citrix.com; stef...@linux.vnet.ibm.com > Cc: qemu-devel@nongnu.org; wei.l...@citrix.com; dgde...@tycho.nsa.gov; > xen-de...@lists.xen.org > Subje

Re: [Qemu-devel] [PATCH COLO v3 01/14] docs: block replication's description

2015-05-05 Thread Fam Zheng
On Wed, 05/06 02:26, Dong, Eddie wrote: > > > > -Original Message- > > From: Dr. David Alan Gilbert [mailto:dgilb...@redhat.com] > > Sent: Tuesday, May 05, 2015 11:24 PM > > To: Stefan Hajnoczi > > Cc: Paolo Bonzini; Wen Congyang; Fam Zheng; Kevin Wolf; Lai Jiangshan; qemu > > block; Jian

Re: [Qemu-devel] qemu-ga and logging domain

2015-05-05 Thread David Gibson
On Thu, Apr 30, 2015 at 10:37:21PM -0500, Michael Roth wrote: > Quoting David Gibson (2015-04-30 20:29:23) > > Michael, > > > > I was just looking at some of the logging stuff in qemu-ga, and it > > seems to be doing something very odd with the "domain". > > > > static void ga_log(const gchar *do

Re: [Qemu-devel] [RFC PATCH v3 06/24] spapr: Consolidate cpu init code into a routine

2015-05-05 Thread Bharata B Rao
On Mon, May 04, 2015 at 06:10:59PM +0200, Thomas Huth wrote: > On Fri, 24 Apr 2015 12:17:28 +0530 > Bharata B Rao wrote: > > > Factor out bits of sPAPR specific CPU initialization code into > > a separate routine so that it can be called from CPU hotplug > > path too. > > > > Signed-off-by: Bhar

Re: [Qemu-devel] [RFC PATCH v3 07/24] cpu: Prepare Socket container type

2015-05-05 Thread Bharata B Rao
On Tue, May 05, 2015 at 11:47:30AM +1000, David Gibson wrote: > On Fri, Apr 24, 2015 at 12:17:29PM +0530, Bharata B Rao wrote: > > From: Andreas Färber > > > > Signed-off-by: Andreas Färber > > Signed-off-by: Bharata B Rao > > So, how to organize this generically is still under discussion. Fo

Re: [Qemu-devel] [RFC PATCH v3 08/24] ppc: Prepare CPU socket/core abstraction

2015-05-05 Thread Bharata B Rao
On Mon, May 04, 2015 at 05:15:04PM +0200, Thomas Huth wrote: > On Fri, 24 Apr 2015 12:17:30 +0530 > Bharata B Rao wrote: > > > Signed-off-by: Bharata B Rao > > Signed-off-by: Andreas Färber > > Not sure if QEMU is fully following the kernel Sob-process, but if > that's the case, I think your S

Re: [Qemu-devel] [RFC PATCH v3 10/24] ppc: Update cpu_model in MachineState

2015-05-05 Thread Bharata B Rao
On Tue, May 05, 2015 at 04:49:08PM +1000, David Gibson wrote: > On Fri, Apr 24, 2015 at 12:17:32PM +0530, Bharata B Rao wrote: > > Keep cpu_model field in MachineState uptodate so that it can be used > > from the CPU hotplug path. > > > > Signed-off-by: Bharata B Rao > > Reviewed-by: David Gibson

[Qemu-devel] [PATCH v2 1/6] mirror: Discard target sectors if not allocated at source side

2015-05-05 Thread Fam Zheng
If guest discards a source cluster during mirror, we would want to discard target side as well. Signed-off-by: Fam Zheng --- block/mirror.c | 12 ++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/block/mirror.c b/block/mirror.c index 58f391a..37a5b61 100644 --- a/block/

[Qemu-devel] [PATCH v2 0/6] block: Mirror discarded sectors

2015-05-05 Thread Fam Zheng
v2: Fix typo and add Eric's rev-by in patch 3. Add patch 1 to discard target in mirror job. (Paolo) Add patch 6 to improve iotests.wait_ready. (John) This fixes the mirror assert failure reported by wangxiaolong: https://lists.gnu.org/archive/html/qemu-devel/2015-04/msg04458.html The dir

[Qemu-devel] [PATCH v2 5/6] qemu-iotests: Add test case for mirror with unmap

2015-05-05 Thread Fam Zheng
This checks that the discard on mirror source that effectively zeroes data is also reflected by the data of target. Signed-off-by: Fam Zheng --- tests/qemu-iotests/131 | 59 ++ tests/qemu-iotests/131.out | 5 tests/qemu-iotests/group | 1 +

[Qemu-devel] [PATCH v2 6/6] iotests: Use event_wait in wait_ready

2015-05-05 Thread Fam Zheng
Only poll the specific type of event we are interested in, to avoid stealing events that should be consumed by someone else. Suggested-by: John Snow Signed-off-by: Fam Zheng --- tests/qemu-iotests/iotests.py | 9 ++--- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/tests/qemu

[Qemu-devel] [PATCH v2 3/6] block: Remove bdrv_reset_dirty

2015-05-05 Thread Fam Zheng
Using this function would always be wrong because a dirty bitmap must have a specific owner that consumes the dirty bits and calls bdrv_reset_dirty_bitmap(). Remove the unused function to avoid future misuse. Reviewed-by: Eric Blake Signed-off-by: Fam Zheng --- block.c | 12 -

[Qemu-devel] [PATCH v2 2/6] block: Fix dirty bitmap in bdrv_co_discard

2015-05-05 Thread Fam Zheng
Unsetting dirty globally with discard is not very correct. The discard may zero out sectors (depending on can_write_zeroes_with_unmap), we should replicate this change to destinition side to make sure that the guest sees the same data. Calling bdrv_reset_dirty also troubles mirror job because the

[Qemu-devel] [PATCH v2 4/6] qemu-iotests: Make block job methods common

2015-05-05 Thread Fam Zheng
Signed-off-by: Fam Zheng --- tests/qemu-iotests/041| 66 ++- tests/qemu-iotests/iotests.py | 28 ++ 2 files changed, 43 insertions(+), 51 deletions(-) diff --git a/tests/qemu-iotests/041 b/tests/qemu-iotests/041 index 59a8f73..3d46e

Re: [Qemu-devel] [RFC PATCH v3 12/24] spapr: CPU hotplug support

2015-05-05 Thread Bharata B Rao
On Mon, May 04, 2015 at 05:53:23PM +0200, Thomas Huth wrote: > On Fri, 24 Apr 2015 12:17:34 +0530 > Bharata B Rao wrote: > > > Support CPU hotplug via device-add command. Set up device tree > > entries for the hotplugged CPU core and use the exising EPOW event > > infrastructure to send CPU hotpl

Re: [Qemu-devel] [PATCH v3 1/6] spapr_pci: remove duplicate macros

2015-05-05 Thread Nikunj A Dadhania
Thomas Huth writes: > On Tue, 5 May 2015 14:23:51 +0530 > Nikunj A Dadhania wrote: > >> Signed-off-by: Nikunj A Dadhania >> --- >> hw/ppc/spapr_pci.c | 11 --- >> 1 file changed, 11 deletions(-) >> >> diff --git a/hw/ppc/spapr_pci.c b/hw/ppc/spapr_pci.c >> index 2e7590c..4df3a33 1006

[Qemu-devel] Bug report - Windows XP guest failure

2015-05-05 Thread Programmingkid
Just wanted to note that for the i386 target, Windows XP as a guest fails to boot. When it safe mode, loading always stops at Windows\System32\Drivers\Mup.sys. The guest boots in QEMU 2.2.0, so this seems to indicate a bug with the May 5th or earlier patch set.

Re: [Qemu-devel] [RFC PATCH v3 18/24] xics_kvm: Don't enable KVM_CAP_IRQ_XICS if already enabled

2015-05-05 Thread Bharata B Rao
On Tue, May 05, 2015 at 05:22:52PM +1000, David Gibson wrote: > On Fri, Apr 24, 2015 at 12:17:40PM +0530, Bharata B Rao wrote: > > When supporting CPU hot removal by parking the vCPU fd and reusing > > it during hotplug again, there can be cases where we try to reenable > > KVM_CAP_IRQ_XICS CAP for

Re: [Qemu-devel] [PATCH v3 2/6] spapr_pci: encode missing 64-bit memory address space

2015-05-05 Thread Nikunj A Dadhania
Thomas Huth writes: > On Tue, 5 May 2015 14:23:52 +0530 > Nikunj A Dadhania wrote: > >> The properties reg/assigned-resources need to encode 64-bit memory >> address space as part of phys.hi dword. >> >> 00 if configuration space >> 01 if IO region, >> 10 if 32-bit MEM region >> 11 if

Re: [Qemu-devel] [PATCH v3 4/6] spapr_pci: enumerate and add PCI device tree

2015-05-05 Thread Nikunj A Dadhania
Thomas Huth writes: > On Tue, 5 May 2015 14:23:54 +0530 > Nikunj A Dadhania wrote: > >> All the PCI enumeration and device node creation was off-loaded to >> SLOF. With PCI hotplug support, code needed to be added to add device >> node. This creates multiple copy of the code one in SLOF and oth

Re: [Qemu-devel] [PATCH v3 5/6] spapr_pci: fix boot-time device tree fields for pci hotplug

2015-05-05 Thread Nikunj A Dadhania
David Gibson writes: > On Tue, May 05, 2015 at 02:23:55PM +0530, Nikunj A Dadhania wrote: >> From: Michael Roth >> >> We need to set the proper drc_index values in ibm,my-drc-index >> fields in order to allow a PCI device that was present at >> boot-time to be unplugged. >> >> Previously SLOF

Re: [Qemu-devel] [PATCH COLO v3 01/14] docs: block replication's description

2015-05-05 Thread Dong, Eddie
> -Original Message- > From: Dr. David Alan Gilbert [mailto:dgilb...@redhat.com] > Sent: Tuesday, May 05, 2015 11:24 PM > To: Stefan Hajnoczi > Cc: Paolo Bonzini; Wen Congyang; Fam Zheng; Kevin Wolf; Lai Jiangshan; qemu > block; Jiang, Yunhong; Dong, Eddie; qemu devel; Max Reitz; Gonglei;

Re: [Qemu-devel] [PATCH v15 00/10] KVM platform device passthrough

2015-05-05 Thread Eric Auger

Re: [Qemu-devel] [PATCH v3 6/6] spapr_pci: populate ibm,loc-code

2015-05-05 Thread Nikunj A Dadhania
Thomas Huth writes: > On Tue, 5 May 2015 14:23:56 +0530 > Nikunj A Dadhania wrote: > >> Each hardware instance has a platform unique location code. The OF >> device tree that describes a part of a hardware entity must include >> the “ibm,loc-code” property with a value that represents the loca

Re: [Qemu-devel] [RFC PATCH v3 12/24] spapr: CPU hotplug support

2015-05-05 Thread Bharata B Rao
On Tue, May 05, 2015 at 04:59:51PM +1000, David Gibson wrote: > On Fri, Apr 24, 2015 at 12:17:34PM +0530, Bharata B Rao wrote: > > Support CPU hotplug via device-add command. Set up device tree > > entries for the hotplugged CPU core and use the exising EPOW event > > infrastructure to send CPU hot

Re: [Qemu-devel] [PATCH v3 4/5] qtest: precompute hex nibs

2015-05-05 Thread Markus Armbruster
John Snow writes: > Instead of letting printf and friends do this for us > one byte at a time, fill a buffer ourselves and then > send the entire buffer in one go. > > This gives a moderate speed improvement over the old > method. Out of curiosity: how much of the improvement is due to doing our

Re: [Qemu-devel] [RFC PATCH v3 06/24] spapr: Consolidate cpu init code into a routine

2015-05-05 Thread Thomas Huth
On Wed, 6 May 2015 09:58:09 +0530 Bharata B Rao wrote: > On Mon, May 04, 2015 at 06:10:59PM +0200, Thomas Huth wrote: > > On Fri, 24 Apr 2015 12:17:28 +0530 > > Bharata B Rao wrote: > > > > > Factor out bits of sPAPR specific CPU initialization code into > > > a separate routine so that it can

Re: [Qemu-devel] [RFC PATCH v3 17/24] cpus: Reclaim vCPU objects

2015-05-05 Thread Bharata B Rao
On Tue, May 05, 2015 at 05:20:04PM +1000, David Gibson wrote: > On Fri, Apr 24, 2015 at 12:17:39PM +0530, Bharata B Rao wrote: > > From: Gu Zheng > > > > In order to deal well with the kvm vcpus (which can not be removed without > > any > > protection), we do not close KVM vcpu fd, just record a

Re: [Qemu-devel] [PATCH v15 00/10] KVM platform device passthrough

2015-05-05 Thread Eric Auger
Dear All, Please ignore the previous void message. For unknown reason the reply systematically ignores the content of the message? Retrying breaking the history... Content was: I am looking for "Tested-by" for this series and related Machvirt dynamic sysbus device instantiation. Did anyone try th

Re: [Qemu-devel] [RFC PATCH v3 08/24] ppc: Prepare CPU socket/core abstraction

2015-05-05 Thread Thomas Huth
On Wed, 6 May 2015 10:10:15 +0530 Bharata B Rao wrote: > On Mon, May 04, 2015 at 05:15:04PM +0200, Thomas Huth wrote: > > On Fri, 24 Apr 2015 12:17:30 +0530 > > Bharata B Rao wrote: > > > > > Signed-off-by: Bharata B Rao > > > Signed-off-by: Andreas Färber > > > > Not sure if QEMU is fully f

Re: [Qemu-devel] [PATCH 6/7] monitor: "i": Add ARM specifics

2015-05-05 Thread Peter Crosthwaite
On Tue, May 5, 2015 at 10:43 AM, Richard Henderson wrote: > On 05/05/2015 10:19 AM, Peter Maydell wrote: >> On 5 May 2015 at 05:45, Peter Crosthwaite wrote: >>> Add the ARM specific disassembly flags setup, so ARM can be correctly >>> disassembled from the monitor. >>> >>> Signed-off-by: Peter Cr

<    1   2   3   4