Re: [Qemu-block] [Qemu-devel] [PATCH 3/3] block: mirror - zero unallocated target sectors when zero init not present

2015-09-28 Thread Eric Blake
On 09/28/2015 03:32 PM, Jeff Cody wrote: > I guess that makes sense. What about the case when the target is a raw > device without zero init? There is no backing file... Of course, perhaps > in the raw case the user should be using sync==full anyways. > >> >> 2) even with mode == "existing"

Re: [Qemu-block] [PATCH 16/16] block: Remove bdrv_swap()

2015-09-28 Thread Alberto Garcia
On Thu 17 Sep 2015 03:48:20 PM CEST, Kevin Wolf wrote: > bdrv_swap() is unused now. Remove it and all functions that have > no other users than bdrv_swap(). In particular, this removes the > .bdrv_rebind callbacks from block drivers. > > Signed-off-by: Kevin Wolf Reviewed-by:

Re: [Qemu-block] [Qemu-devel] [PATCH 06/10][TRIVIAL] macio-ide: add to storage category

2015-09-28 Thread Thomas Huth
On 26/09/15 18:22, Laurent Vivier wrote: > macio-ide is an IDE controller, so add it > to the storage category. > > Signed-off-by: Laurent Vivier > --- > hw/ide/macio.c | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/hw/ide/macio.c b/hw/ide/macio.c > index

Re: [Qemu-block] [Qemu-devel] [PATCH 01/10][TRIVIAL] adb: add to input category

2015-09-28 Thread Thomas Huth
On 26/09/15 18:22, Laurent Vivier wrote: > The Apple Desktop Bus is used to connect a keyboard and a mouse, > so add it to the input category. > > Signed-off-by: Laurent Vivier > --- > hw/input/adb.c | 2 ++ > 1 file changed, 2 insertions(+) > > diff --git a/hw/input/adb.c

Re: [Qemu-block] [Qemu-devel] [PATCH 03/10][TRIVIAL] escc: add to input category

2015-09-28 Thread Thomas Huth
On 26/09/15 18:22, Laurent Vivier wrote: > ESCC is a serial port controller, so add it > to the input category. > > Signed-off-by: Laurent Vivier > --- > hw/char/escc.c | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/hw/char/escc.c b/hw/char/escc.c > index

Re: [Qemu-block] [PATCH 3/3] block: mirror - zero unallocated target sectors when zero init not present

2015-09-28 Thread Paolo Bonzini
On 28/09/2015 05:29, Jeff Cody wrote: > This only occurs under two conditions: > > 1. 'mode' != "existing" > 2. bdrv_has_zero_init(target) == NULL > I'm not sure if mode != "existing" actually matters. I think what actually matters is sync == "full". The reasons are: 1) with sync

Re: [Qemu-block] [PATCH 2/3] block: mirror - split out part of mirror_run()

2015-09-28 Thread Paolo Bonzini
On 28/09/2015 05:29, Jeff Cody wrote: > This is code relocation, to pull the part of mirror_run() that > calls mirror_iteration out into a separate function. > > Signed-off-by: Jeff Cody > --- > block/mirror.c | 206 >

Re: [Qemu-block] [Qemu-devel] [PATCH 04/10][TRIVIAL] grackle: add to bridge category

2015-09-28 Thread Thomas Huth
On 26/09/15 18:22, Laurent Vivier wrote: > Grackle is the PCI host controller of oldworld powermac, > so add it to the bridge category. > > Signed-off-by: Laurent Vivier > --- > hw/pci-host/grackle.c | 2 ++ > 1 file changed, 2 insertions(+) > > diff --git

Re: [Qemu-block] [PATCH 10/16] block/io: Make bdrv_requests_pending() public

2015-09-28 Thread Alberto Garcia
On Thu 17 Sep 2015 03:48:14 PM CEST, Kevin Wolf wrote: > Signed-off-by: Kevin Wolf > --- > block/io.c| 2 +- > include/block/block_int.h | 1 + > 2 files changed, 2 insertions(+), 1 deletion(-) Reviewed-by: Alberto Garcia Berto

Re: [Qemu-block] [Qemu-devel] [PATCH 10/10][TRIVIAL] openpic: add to misc category

2015-09-28 Thread Thomas Huth
On 26/09/15 18:22, Laurent Vivier wrote: > openpic is a programmable interrupt controller, so > add it to the misc category. > > Signed-off-by: Laurent Vivier > --- > hw/intc/openpic.c | 1 + > hw/intc/openpic_kvm.c | 1 + > 2 files changed, 2 insertions(+) > > diff

Re: [Qemu-block] [Qemu-devel] [PATCH 09/10][TRIVIAL] macio-nvram: add to misc category

2015-09-28 Thread Thomas Huth
On 26/09/15 18:22, Laurent Vivier wrote: > The macio nvram is a non volatile RAM, so add it > the misc category. > > Signed-off-by: Laurent Vivier > --- > hw/nvram/mac_nvram.c | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/hw/nvram/mac_nvram.c

Re: [Qemu-block] [PATCH 2/3] block: mirror - split out part of mirror_run()

2015-09-28 Thread Kevin Wolf
Am 28.09.2015 um 05:29 hat Jeff Cody geschrieben: > This is code relocation, to pull the part of mirror_run() that > calls mirror_iteration out into a separate function. > > Signed-off-by: Jeff Cody > --- > block/mirror.c | 206 >

Re: [Qemu-block] [PATCH 3/3] block: mirror - zero unallocated target sectors when zero init not present

2015-09-28 Thread Kevin Wolf
Am 28.09.2015 um 05:29 hat Jeff Cody geschrieben: > During mirror, if the target device does not have support zero > initialization, a mirror may result in a corrupt image. I think you want to check this sentence. ("During mirror [...], a mirror may result [...]") > For instance, on mirror to a

Re: [Qemu-block] [PATCH v2] iotests: disable core dumps in test 061

2015-09-28 Thread Max Reitz
On 28.09.2015 16:23, Alberto Garcia wrote: > Commit 934659c460 disabled the supression of segmentation faults in > bash tests. The new output of test 061, however, assumes that a core > dump will be produced if a program aborts. This is not necessarily the > case because core dumps can be disabled

[Qemu-block] [PATCH v2] iotests: disable core dumps in test 061

2015-09-28 Thread Alberto Garcia
Commit 934659c460 disabled the supression of segmentation faults in bash tests. The new output of test 061, however, assumes that a core dump will be produced if a program aborts. This is not necessarily the case because core dumps can be disabled using ulimit. Since we cannot guarantee that

Re: [Qemu-block] [Qemu-devel] [PATCH 06/10][TRIVIAL] macio-ide: add to storage category

2015-09-28 Thread John Snow
On 09/26/2015 12:22 PM, Laurent Vivier wrote: > macio-ide is an IDE controller, so add it > to the storage category. > > Signed-off-by: Laurent Vivier > --- > hw/ide/macio.c | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/hw/ide/macio.c b/hw/ide/macio.c > index

Re: [Qemu-block] [PATCH 1/3] block: allow creation of detached dirty bitmaps

2015-09-28 Thread Stefan Hajnoczi
On Sun, Sep 27, 2015 at 11:29:16PM -0400, Jeff Cody wrote: > This allows the creation of detached dirty bitmaps, so that the > block driver dirty bitmaps can be used without inserting the > bitmap into the dirty bitmap list for a BDS. > > To free a bitmap that was created "detached = true", call

Re: [Qemu-block] [PATCH 3/3] block: mirror - zero unallocated target sectors when zero init not present

2015-09-28 Thread Kevin Wolf
Am 28.09.2015 um 05:29 hat Jeff Cody geschrieben: > During mirror, if the target device does not have support zero > initialization, a mirror may result in a corrupt image. > > For instance, on mirror to a host device with format = raw, whatever > random data is on the target device will still be

Re: [Qemu-block] [PATCH 03/18] qemu-thread: introduce QemuLockCnt

2015-09-28 Thread Paolo Bonzini
On 28/09/2015 12:15, Stefan Hajnoczi wrote: > On Thu, Aug 06, 2015 at 03:36:01PM +0200, Paolo Bonzini wrote: >> > +int qemu_lockcnt_count(QemuLockCnt *lockcnt); > Why use int here when the counter field is unsigned? Nice catch, will fix. Paolo

Re: [Qemu-block] [PATCH 03/18] qemu-thread: introduce QemuLockCnt

2015-09-28 Thread Stefan Hajnoczi
On Thu, Aug 06, 2015 at 03:36:01PM +0200, Paolo Bonzini wrote: > +int qemu_lockcnt_count(QemuLockCnt *lockcnt); Why use int here when the counter field is unsigned?

Re: [Qemu-block] [Qemu-devel] [PATCH v2 00/11] aio: Introduce handler type to fix nested aio_poll for dataplane

2015-09-28 Thread Stefan Hajnoczi
On Fri, Sep 11, 2015 at 02:22:14PM +0200, Kevin Wolf wrote: > Am 11.09.2015 um 13:46 hat Fam Zheng geschrieben: > > On Fri, 09/11 12:39, Kevin Wolf wrote: > > > Am 29.07.2015 um 06:42 hat Fam Zheng geschrieben: > > > > v2: Switch to disable/enable model. [Paolo] > > > > > > > > Most existing

Re: [Qemu-block] [PATCH 3/3] block: mirror - zero unallocated target sectors when zero init not present

2015-09-28 Thread Stefan Hajnoczi
On Sun, Sep 27, 2015 at 11:29:18PM -0400, Jeff Cody wrote: > +if (s->zero_cycle) { > +ret = bdrv_get_block_status(s->target, sector_num, nb_sectors, > ); > +if (!(ret & BDRV_BLOCK_ZERO)) { > +bdrv_aio_write_zeroes(s->target, sector_num, op->nb_sectors, > +

Re: [Qemu-block] [Qemu-devel] [PATCH 3/3] block: mirror - zero unallocated target sectors when zero init not present

2015-09-28 Thread Jeff Cody
On Sep 28, 2015 4:12 PM, "Paolo Bonzini" wrote: > > Replying from mobile; please excuse any formatting issues. > > On 28/09/2015 05:29, Jeff Cody wrote: > > This only occurs under two conditions: > > > > 1. 'mode' != "existing" > > 2. bdrv_has_zero_init(target) ==

Re: [Qemu-block] [PATCH 2/3] block: mirror - split out part of mirror_run()

2015-09-28 Thread Max Reitz
On 28.09.2015 05:29, Jeff Cody wrote: > This is code relocation, to pull the part of mirror_run() that > calls mirror_iteration out into a separate function. > > Signed-off-by: Jeff Cody > --- > block/mirror.c | 206 > ++---

Re: [Qemu-block] [PATCH 1/3] block: allow creation of detached dirty bitmaps

2015-09-28 Thread Max Reitz
On 28.09.2015 05:29, Jeff Cody wrote: > This allows the creation of detached dirty bitmaps, so that the > block driver dirty bitmaps can be used without inserting the > bitmap into the dirty bitmap list for a BDS. > > To free a bitmap that was created "detached = true", call >

[Qemu-block] [PATCH] qtest/ide-test: ppc64be correction for ATAPI tests

2015-09-28 Thread John Snow
the 16bit ide data register is LE by definition. Signed-off-by: John Snow --- tests/ide-test.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/ide-test.c b/tests/ide-test.c index 5594738..b6e9e1a 100644 --- a/tests/ide-test.c +++

Re: [Qemu-block] [PATCH 3/3] block: mirror - zero unallocated target sectors when zero init not present

2015-09-28 Thread Max Reitz
On 28.09.2015 05:29, Jeff Cody wrote: > During mirror, if the target device does not have support zero > initialization, a mirror may result in a corrupt image. > > For instance, on mirror to a host device with format = raw, whatever > random data is on the target device will still be there for

Re: [Qemu-block] [Qemu-devel] [PATCH 3/3] block: mirror - zero unallocated target sectors when zero init not present

2015-09-28 Thread Eric Blake
On 09/28/2015 08:13 AM, Paolo Bonzini wrote: > > > On 28/09/2015 05:29, Jeff Cody wrote: >> This only occurs under two conditions: >> >> 1. 'mode' != "existing" >> 2. bdrv_has_zero_init(target) == NULL >> > > I'm not sure if mode != "existing" actually matters. I think what > actually

Re: [Qemu-block] [Qemu-devel] [PATCH 3/3] block: mirror - zero unallocated target sectors when zero init not present

2015-09-28 Thread Jeff Cody
On Sep 28, 2015 5:34 PM, "Kevin Wolf" wrote: > > Am 28.09.2015 um 05:29 hat Jeff Cody geschrieben: > > During mirror, if the target device does not have support zero > > initialization, a mirror may result in a corrupt image. > > > > For instance, on mirror to a host device with

Re: [Qemu-block] [Qemu-devel] [PATCH 3/3] block: mirror - zero unallocated target sectors when zero init not present

2015-09-28 Thread Jeff Cody
On Sep 28, 2015 5:31 PM, "Kevin Wolf" wrote: > (Responding from mobile phone again) > Am 28.09.2015 um 05:29 hat Jeff Cody geschrieben: > > During mirror, if the target device does not have support zero > > initialization, a mirror may result in a corrupt image. > > I think