Re: [Qemu-block] [PATCH v9 01/13] qcow2: Unallocate unmapped zero clusters if no backing file

2017-05-12 Thread John Snow
On 05/12/2017 12:06 PM, Max Reitz wrote: > On 2017-05-11 16:56, Eric Blake wrote: >> [revisiting this older patch version, even though the final version in >> today's pull request changed somewhat from this approach] >> >> On 04/12/2017 04:49 AM, Kevin Wolf wrote: >>> Am 11.04.2017 um 03:17 hat

[Qemu-block] QEMU seg-fault with intermediate image streaming -- bdrv_reopen() in stream_start()

2017-05-12 Thread Kashyap Chamarthy
Reproducer -- [Disk image chain: disk1.qcow2 <- b.qcow2 <- c.qcow2] $ qemu-system-x86_64 -display none -nodefconfig -nodefaults \ -m 512 -device virtio-scsi-pci,id=scsi \ -device virtio-serial-pci \ -drive driver=qcow2,file.driver=file,file.filename=./disk1.qcow2,id=virtio0

Re: [Qemu-block] [PATCH 7/7] curl: do not do aio_poll when waiting for a free CURLState

2017-05-12 Thread Jeff Cody
On Wed, May 10, 2017 at 04:32:05PM +0200, Paolo Bonzini wrote: > Instead, put the CURLAIOCB on a wait list; curl_clean_state will > wake the corresponding coroutine. > > Because of CURL's callback-based structure, we cannot easily convert > everything to CoMutex/CoQueue; keeping the QemuMutex is

Re: [Qemu-block] [PATCH 6/7] curl: convert readv to coroutines

2017-05-12 Thread Jeff Cody
On Wed, May 10, 2017 at 04:32:04PM +0200, Paolo Bonzini wrote: > This is pretty simple. The bottom half goes away because, unlike > bdrv_aio_readv, coroutine-based read can return immediately without > yielding. However, for simplicity I kept the former bottom half > handler in a separate

Re: [Qemu-block] [PATCH 5/7] curl: convert CURLAIOCB to byte values

2017-05-12 Thread Jeff Cody
On Wed, May 10, 2017 at 04:32:03PM +0200, Paolo Bonzini wrote: > This is in preparation for the conversion from bdrv_aio_readv to > bdrv_co_preadv, and it also requires changing some of the size_t values > to uint64_t. This was broken before for disks > 2TB, but now it would > break at 4GB. > >

Re: [Qemu-block] [PATCH 4/7] curl: split curl_find_state/curl_init_state

2017-05-12 Thread Jeff Cody
On Wed, May 10, 2017 at 04:32:02PM +0200, Paolo Bonzini wrote: > If curl_easy_init fails, a CURLState is left with s->in_use = 1. Split > curl_init_state in two, so that we can distinguish the two failures and > call curl_clean_state if needed. > > While at it, simplify curl_find_state, removing

Re: [Qemu-block] [PATCH v4] qemu-img: Check for backing image if specified during create

2017-05-12 Thread John Snow
On 05/12/2017 03:46 PM, Eric Blake wrote: > On 05/12/2017 01:07 PM, Max Reitz wrote: >> On 2017-05-11 20:27, John Snow wrote: >>> Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=1213786 >>> >>> Or, rather, force the open of a backing image if one was specified >>> for creation. Using a

Re: [Qemu-block] [PATCH v4] qemu-img: Check for backing image if specified during create

2017-05-12 Thread Eric Blake
On 05/12/2017 01:07 PM, Max Reitz wrote: > On 2017-05-11 20:27, John Snow wrote: >> Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=1213786 >> >> Or, rather, force the open of a backing image if one was specified >> for creation. Using a similar -unsafe option as rebase, allow qemu-img >> to

Re: [Qemu-block] [PATCH v4] qemu-img: Check for backing image if specified during create

2017-05-12 Thread Max Reitz
On 2017-05-11 20:27, John Snow wrote: > Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=1213786 > > Or, rather, force the open of a backing image if one was specified > for creation. Using a similar -unsafe option as rebase, allow qemu-img > to ignore the backing file validation if possible. >

Re: [Qemu-block] [PATCH v8 0/4] Improve convert and dd commands

2017-05-12 Thread Max Reitz
On 2017-05-09 11:48, Daniel P. Berrange wrote: > Update to > > v1: https://lists.gnu.org/archive/html/qemu-devel/2017-01/msg05699.html > v2: https://lists.gnu.org/archive/html/qemu-devel/2017-02/msg00728.html > v3: https://lists.gnu.org/archive/html/qemu-devel/2017-02/msg04391.html > v4:

Re: [Qemu-block] [PULL 05/58] qemu-img: Update documentation for -U

2017-05-12 Thread Max Reitz
On 2017-05-11 16:32, Kevin Wolf wrote: > From: Fam Zheng > > Signed-off-by: Fam Zheng > Signed-off-by: Kevin Wolf > --- > qemu-img-cmds.hx | 36 ++-- > 1 file changed, 18 insertions(+), 18 deletions(-) > >

Re: [Qemu-block] [PATCH] qcow2: remove extra local_error variable

2017-05-12 Thread Max Reitz
On 2017-05-11 17:03, Alberto Garcia wrote: > Commit d7086422b1c1e75e320519cfe26176db6ec97a37 added a local_err > variable global to the qcow2_amend_options() function, so there's no > need to have this other one. > > Signed-off-by: Alberto Garcia > --- > block/qcow2.c | 5

Re: [Qemu-block] [PATCH v9 01/13] qcow2: Unallocate unmapped zero clusters if no backing file

2017-05-12 Thread Max Reitz
On 2017-05-11 16:56, Eric Blake wrote: > [revisiting this older patch version, even though the final version in > today's pull request changed somewhat from this approach] > > On 04/12/2017 04:49 AM, Kevin Wolf wrote: >> Am 11.04.2017 um 03:17 hat Eric Blake geschrieben: >>> 'qemu-img map'

Re: [Qemu-block] [PATCH 3/7] curl: avoid recursive locking of BDRVCURLState mutex

2017-05-12 Thread Paolo Bonzini
On 11/05/2017 22:56, Jeff Cody wrote: > On Wed, May 10, 2017 at 04:32:01PM +0200, Paolo Bonzini wrote: >> The curl driver has a ugly hack where, if it cannot find an empty CURLState, >> it just uses aio_poll to wait for one to be empty. This is probably >> buggy when used together with

Re: [Qemu-block] [PULL 00/58] Block layer patches

2017-05-12 Thread Stefan Hajnoczi
On Thu, May 11, 2017 at 04:32:03PM +0200, Kevin Wolf wrote: > The following changes since commit 76d20ea0f1b26ebd5da2f5fb2fdf3250cde887bb: > > Merge remote-tracking branch 'armbru/tags/pull-qapi-2017-05-04-v3' into > staging (2017-05-09 15:49:14 -0400) > > are available in the git repository

[Qemu-block] [PATCH v2] blockdev: Print a warning for legacy drive options that belong to -device

2017-05-12 Thread Thomas Huth
We likely do not want to carry these legacy -drive options along forever. Let's emit a deprecation warning for the -drive options that have a replacement with the -device option, so that the (hopefully few) remaining users are aware of this and can adapt their scripts / behaviour accordingly.

Re: [Qemu-block] [PATCH 02/18] block: access quiesce_counter with atomic ops

2017-05-12 Thread Alberto Garcia
On Thu 11 May 2017 04:41:52 PM CEST, Paolo Bonzini wrote: > Reviewed-by: Stefan Hajnoczi > Signed-off-by: Paolo Bonzini > --- Reviewed-by: Alberto Garcia Berto

Re: [Qemu-block] [PATCH v4 0/6] COLO block replication supports shared disk case

2017-05-12 Thread Hailiang Zhang
On 2017/5/12 3:17, Stefan Hajnoczi wrote: On Wed, Apr 12, 2017 at 10:05:15PM +0800, zhanghailiang wrote: COLO block replication doesn't support the shared disk case, Here we try to implement it and this is the 4th version. Please review and any commits are welcomed. Cc: Dr. David Alan Gilbert

Re: [Qemu-block] [Qemu-devel] [PATCH v4 5/6] replication: Implement block replication for shared disk case

2017-05-12 Thread Hailiang Zhang
On 2017/5/12 3:15, Stefan Hajnoczi wrote: On Wed, Apr 12, 2017 at 10:05:20PM +0800, zhanghailiang wrote: @@ -612,6 +644,16 @@ static void replication_do_checkpoint(ReplicationState *rs, Error **errp) error_propagate(errp, local_err); break; } +

Re: [Qemu-block] [PATCH v4 2/6] replication: add shared-disk and shared-disk-id options

2017-05-12 Thread Hailiang Zhang
On 2017/5/12 3:08, Stefan Hajnoczi wrote: On Wed, Apr 12, 2017 at 10:05:17PM +0800, zhanghailiang wrote: We use these two options to identify which disk is shared Signed-off-by: zhanghailiang Signed-off-by: Wen Congyang Signed-off-by:

Re: [Qemu-block] [PATCH v4 2/6] replication: add shared-disk and shared-disk-id options

2017-05-12 Thread Hailiang Zhang
On 2017/4/18 13:59, Xie Changlong wrote: On 04/12/2017 10:05 PM, zhanghailiang wrote: We use these two options to identify which disk is shared Signed-off-by: zhanghailiang Signed-off-by: Wen Congyang Signed-off-by: Zhang Chen