[libvirt] [PULL v3 02/19] block: move bdrv_can_store_new_dirty_bitmap to block/dirty-bitmap.c

2019-10-17 Thread John Snow
From: Vladimir Sementsov-Ogievskiy block/dirty-bitmap.c seems to be more appropriate for it and bdrv_remove_persistent_dirty_bitmap already in it. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: John Snow Message-id: 20190920082543.23444-2-vsement...@virtuozzo.com Signed-off-by: John

[libvirt] [PULL v3 08/19] block/dirty-bitmap: refactor bdrv_dirty_bitmap_next

2019-10-17 Thread John Snow
From: Vladimir Sementsov-Ogievskiy bdrv_dirty_bitmap_next is always used in same pattern. So, split it into _next and _first, instead of combining two functions into one and add FOR_EACH_DIRTY_BITMAP macro. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: John Snow Message-id

[libvirt] [PULL v3 11/19] iotests: add test-case to 165 to test reopening qcow2 bitmaps to RW

2019-10-17 Thread John Snow
From: Vladimir Sementsov-Ogievskiy Reopening bitmaps to RW was broken prior to previous commit. Check that it works now. Signed-off-by: Vladimir Sementsov-Ogievskiy Message-id: 20190927122355.7344-4-vsement...@virtuozzo.com Signed-off-by: John Snow --- tests/qemu-iotests/165 | 57

[libvirt] [PULL v3 09/19] block: switch reopen queue from QSIMPLEQ to QTAILQ

2019-10-17 Thread John Snow
From: Vladimir Sementsov-Ogievskiy We'll need reverse-foreach in the following commit, QTAILQ support it, so move to QTAILQ. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: Max Reitz Message-id: 20190927122355.7344-2-vsement...@virtuozzo.com Signed-off-by: John Snow --- include

[libvirt] [PULL v3 06/19] block/dirty-bitmap: add bs link

2019-10-17 Thread John Snow
From: Vladimir Sementsov-Ogievskiy Add bs field to BdrvDirtyBitmap structure. Drop BlockDriverState parameter from bitmap APIs where possible. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: John Snow Message-id: 20190916141911.5255-3-vsement...@virtuozzo.com [Rebased on top of block

[libvirt] [PULL v3 03/19] block/dirty-bitmap: return int from bdrv_remove_persistent_dirty_bitmap

2019-10-17 Thread John Snow
From: Vladimir Sementsov-Ogievskiy It's more comfortable to not deal with local_err. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: John Snow Message-id: 20190920082543.23444-3-vsement...@virtuozzo.com Signed-off-by: John Snow --- block/qcow2.h| 5 ++--- include

[libvirt] [PULL v3 18/19] MAINTAINERS: Add Vladimir as a reviewer for bitmaps

2019-10-17 Thread John Snow
I already try to make sure all bitmaps patches have been reviewed by both Red Hat and Virtuozzo anyway, so this formalizes the arrangement. Fam meanwhile is no longer as active, so I am removing him as a co-maintainer simply to reflect the current practice. Signed-off-by: John Snow Reviewed

[libvirt] [PULL v3 16/19] block/qcow2-bitmap: fix and improve qcow2_reopen_bitmaps_rw

2019-10-17 Thread John Snow
USE in the image. - Consider unexpected bitmap as a corruption and check other combinations of in-image and in-RAM bitmaps. Signed-off-by: Vladimir Sementsov-Ogievskiy Message-id: 20190927122355.7344-9-vsement...@virtuozzo.com Signed-off-by: John Snow --- block/qcow2-bitmap.c |

[libvirt] [PULL v3 15/19] iotests: add test 260 to check bitmap life after snapshot + commit

2019-10-17 Thread John Snow
From: Vladimir Sementsov-Ogievskiy Signed-off-by: Vladimir Sementsov-Ogievskiy Message-id: 20190927122355.7344-8-vsement...@virtuozzo.com [Maintainer edit: removed 260 from auto group per Peter Maydell. --js] Signed-off-by: John Snow --- tests/qemu-iotests/260 | 89

[libvirt] [PULL v3 14/19] block/qcow2-bitmap: do not remove bitmaps on reopen-ro

2019-10-17 Thread John Snow
bitmaps rw will be fixed in the following patches. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: John Snow Message-id: 20190927122355.7344-7-vsement...@virtuozzo.com Signed-off-by: John Snow --- block/qcow2.h| 3 ++- block/qcow2-bitmap.c | 49

[libvirt] [PULL v3 17/19] qcow2-bitmap: move bitmap reopen-rw code to qcow2_reopen_commit

2019-10-17 Thread John Snow
aps_rw did a wrong check for being writable, when actually it only need writable file child not self. So, as it's fixed, let's move things to correct place. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: John Snow Acked-by: Max Reitz Message-id: 20190927122355.7344-10-v

[libvirt] [PULL v3 19/19] dirty-bitmaps: remove deprecated autoload parameter

2019-10-17 Thread John Snow
This parameter has been deprecated since 2.12.0 and is eligible for removal. Remove this parameter as it is actually completely ignored; let's not give false hope. Signed-off-by: John Snow Reviewed-by: Eric Blake Reviewed-by: Vladimir Sementsov-Ogievskiy Message-id: 20191002232411.29968-1-js

[libvirt] [PULL v3 13/19] block/qcow2-bitmap: drop qcow2_reopen_bitmaps_rw_hint()

2019-10-17 Thread John Snow
From: Vladimir Sementsov-Ogievskiy The function is unused, drop it. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: John Snow Message-id: 20190927122355.7344-6-vsement...@virtuozzo.com Signed-off-by: John Snow --- block/qcow2.h| 2 -- block/qcow2-bitmap.c | 15

[libvirt] [PULL 1/9] IDE: deprecate ide-drive

2019-10-31 Thread John Snow
It's an old compatibility shim that just delegates to ide-cd or ide-hd. I'd like to refactor these some day, and getting rid of the super-object will make that easier. Either way, we don't need this. Signed-off-by: John Snow Reviewed-by: Thomas Huth Reviewed-by: Markus Armbruster ACKed

[libvirt] [PULL 0/9] Ide patches

2019-10-31 Thread John Snow
-request for you to fetch changes up to c35564caf20e8d3431786dddf0fa513daa7d7f3c: hd-geo-test: Add tests for lchs override (2019-10-31 06:11:34 -0400) Pull request John

[libvirt] [PULL 2/9] block: Refactor macros - fix tabbing

2019-10-31 Thread John Snow
From: Sam Eiderman Fixing tabbing in block related macros. Signed-off-by: Sam Eiderman Signed-off-by: Sam Eiderman Reviewed-by: Karl Heubaum Reviewed-by: Arbel Moshe Reviewed-by: Philippe Mathieu-Daudé Signed-off-by: John Snow --- include/hw/block/block.h | 16 hw/ide

[libvirt] [PULL 3/9] block: Support providing LCHS from user

2019-10-31 Thread John Snow
* virtio-blk-pci In future commits we will use the provided LCHS and pass it to the BIOS through fw_cfg to be supplied using INT13 routines. Reviewed-by: Karl Heubaum Reviewed-by: Arbel Moshe Signed-off-by: Sam Eiderman Signed-off-by: Sam Eiderman Reviewed-by: Philippe Mathieu-Da

[libvirt] [PULL 4/9] bootdevice: Add interface to gather LCHS

2019-10-31 Thread John Snow
-by: Philippe Mathieu-Daudé Signed-off-by: John Snow --- include/sysemu/sysemu.h | 3 +++ bootdevice.c| 55 + 2 files changed, 58 insertions(+) diff --git a/include/sysemu/sysemu.h b/include/sysemu/sysemu.h index 44f18eb739..5bc5c79cbc 100644

[libvirt] [PULL 7/9] bootdevice: Refactor get_boot_devices_list

2019-10-31 Thread John Snow
-Daudé Signed-off-by: Sam Eiderman Signed-off-by: Sam Eiderman Tested-by: Philippe Mathieu-Daudé Signed-off-by: John Snow --- bootdevice.c | 61 +--- 1 file changed, 34 insertions(+), 27 deletions(-) diff --git a/bootdevice.c b/bootdevice.c index

[libvirt] [PULL 8/9] bootdevice: FW_CFG interface for LCHS values

2019-10-31 Thread John Snow
n Signed-off-by: Sam Eiderman Tested-by: Philippe Mathieu-Daudé Signed-off-by: John Snow --- include/sysemu/sysemu.h | 1 + bootdevice.c| 31 +++ hw/nvram/fw_cfg.c | 14 +++--- 3 files changed, 43 insertions(+), 3 deletions(-) diff --git a/inc

[libvirt] [PULL 6/9] bootdevice: Gather LCHS from all relevant devices

2019-10-31 Thread John Snow
Reviewed-by: Arbel Moshe Signed-off-by: Sam Eiderman Signed-off-by: Sam Eiderman Reviewed-by: Philippe Mathieu-Daudé Tested-by: Philippe Mathieu-Daudé Signed-off-by: John Snow --- hw/block/virtio-blk.c | 6 ++ hw/ide/qdev.c | 5 + hw/scsi/scsi-disk.c | 12 3

[libvirt] [PULL 5/9] scsi: Propagate unrealize() callback to scsi-hd

2019-10-31 Thread John Snow
-off-by: John Snow --- include/hw/scsi/scsi.h | 1 + hw/scsi/scsi-bus.c | 16 2 files changed, 17 insertions(+) diff --git a/include/hw/scsi/scsi.h b/include/hw/scsi/scsi.h index d77a92361b..332ef602f4 100644 --- a/include/hw/scsi/scsi.h +++ b/include/hw/scsi/scsi.h @@ -59,6

[libvirt] [PULL 9/9] hd-geo-test: Add tests for lchs override

2019-10-31 Thread John Snow
. Reviewed-by: Karl Heubaum Reviewed-by: Arbel Moshe Signed-off-by: Sam Eiderman Signed-off-by: Sam Eiderman Signed-off-by: John Snow --- tests/hd-geo-test.c| 551 + tests/Makefile.include | 2 +- 2 files changed, 552 insertions(+), 1 deletion(-) diff

[libvirt] [PATCH 1/1] dirty-bitmaps: remove deprecated autoload parameter

2019-09-24 Thread John Snow
This parameter has been deprecated since 2.12.0 and is eligible for removal. Remove this parameter as it is actually completely ignored; let's not give false hope. Signed-off-by: John Snow --- qemu-deprecated.texi | 20 +++- qapi/block-core.json | 6 +- blockdev.c

[libvirt] [PATCH 0/1] dirty-bitmaps: remove deprecated autoload parameter

2019-09-24 Thread John Snow
happens if we actually stop dropping features we claimed were deprecated. John Snow (1): dirty-bitmaps: remove deprecated autoload parameter qemu-deprecated.texi | 20 +++- qapi/block-core.json | 6 +- blockdev.c | 6 -- 3 files changed, 16 insertions(+), 16

Re: [libvirt] QEMU bitmap backup usability FAQ

2019-09-25 Thread John Snow
On 8/20/19 6:25 PM, John Snow wrote: > Hi, downstream here at Red Hat I've been fielding some questions about > the usability and feature readiness of Bitmaps (and related features) in > QEMU. > > Here are some questions I answered internally that I am copying to the > li

Re: [libvirt] [PATCH 1/1] dirty-bitmaps: remove deprecated autoload parameter

2019-09-25 Thread John Snow
On 9/25/19 3:20 AM, Vladimir Sementsov-Ogievskiy wrote: > 25.09.2019 2:01, John Snow wrote: >> This parameter has been deprecated since 2.12.0 and is eligible for >> removal. Remove this parameter as it is actually completely ignored; >> let's not give false hope. >>

Re: [libvirt] QEMU bitmap backup usability FAQ

2019-09-25 Thread John Snow
On 9/25/19 11:11 AM, Vladimir Sementsov-Ogievskiy wrote: > 25.09.2019 16:52, John Snow wrote: >> >> >> On 8/20/19 6:25 PM, John Snow wrote: >>> Hi, downstream here at Red Hat I've been fielding some questions about >>> the usability and feature rea

[libvirt] [PATCH 1/1] IDE: deprecate ide-drive

2019-10-06 Thread John Snow
It's an old compatibility shim that just delegates to ide-cd or ide-hd. I'd like to refactor these some day, and getting rid of the super-object will make that easier. Either way, we don't need this. Signed-off-by: John Snow --- qemu-deprecated.texi | 5 + hw/ide/qdev.c

[libvirt] [PATCH 0/1] IDE: Deprecate ide-drive

2019-10-06 Thread John Snow
John Snow (1): IDE: deprecate ide-drive qemu-deprecated.texi | 5 + hw/ide/qdev.c | 3 +++ tests/qemu-iotests/051.pc.out | 6 -- 3 files changed, 12 insertions(+), 2 deletions(-) -- 2.21.0 -- libvir-list mailing list libvir-list@redhat.com https

Re: [libvirt] [PATCH 1/1] IDE: deprecate ide-drive

2019-10-07 Thread John Snow
On 10/7/19 5:49 AM, Markus Armbruster wrote: > John Snow writes: > >> It's an old compatibility shim that just delegates to ide-cd or ide-hd. >> I'd like to refactor these some day, and getting rid of the super-object >> will make that easier. > > Device &q

[libvirt] [PATCH v2 1/1] IDE: deprecate ide-drive

2019-10-09 Thread John Snow
It's an old compatibility shim that just delegates to ide-cd or ide-hd. I'd like to refactor these some day, and getting rid of the super-object will make that easier. Either way, we don't need this. Libvirt-checked-by: Peter Krempa Signed-off-by: John Snow --- qemu-deprecated.texi

[libvirt] [PATCH v2 0/1] IDE: Deprecate ide-drive

2019-10-09 Thread John Snow
V2: Change phrasings and spellings as Markus suggested. John Snow (1): IDE: deprecate ide-drive qemu-deprecated.texi | 5 + hw/ide/qdev.c | 3 +++ tests/qemu-iotests/051.pc.out | 6 -- 3 files changed, 12 insertions(+), 2 deletions(-) -- 2.21.0 -- libvir

Re: [libvirt] [PATCH 1/1] IDE: deprecate ide-drive

2019-10-09 Thread John Snow
On 10/8/19 2:51 AM, Markus Armbruster wrote: >> I'll respin to hit the tests with a stiffer scrub-brush. > Thanks! 051 is the only test I can find that uses ide-drive, and the non-pc version of the test doesn't seem to use it, so this actually seems sufficient. I'd like to keep the test for

Re: [libvirt] [PATCH v2 1/1] IDE: deprecate ide-drive

2019-10-10 Thread John Snow
On 10/10/19 7:54 AM, Peter Krempa wrote: > On Thu, Oct 10, 2019 at 13:42:26 +0200, Philippe Mathieu-Daudé wrote: >> On 10/10/19 1:26 PM, Peter Krempa wrote: >>> On Thu, Oct 10, 2019 at 13:22:37 +0200, Philippe Mathieu-Daudé wrote: >>>> On 10/10/19 12:43 AM, John

Re: [libvirt] [PATCH v3] dirty-bitmaps: remove deprecated autoload parameter

2019-10-09 Thread John Snow
On 10/2/19 7:24 PM, John Snow wrote: > This parameter has been deprecated since 2.12.0 and is eligible for > removal. Remove this parameter as it is actually completely ignored; > let's not give false hope. > > Signed-off-by: John Snow > Reviewed-by: Eric Blake >

[libvirt] [PATCH v2] dirty-bitmaps: remove deprecated autoload parameter

2019-10-03 Thread John Snow
This parameter has been deprecated since 2.12.0 and is eligible for removal. Remove this parameter as it is actually completely ignored; let's not give false hope. Signed-off-by: John Snow Reviewed-by: Eric Blake Reviewed-by: Vladimir Sementsov-Ogievskiy --- V2: Change 2.12.0 -> 4.

Re: [libvirt] [PATCH v2] dirty-bitmaps: remove deprecated autoload parameter

2019-10-03 Thread John Snow
On 10/2/19 7:22 PM, John Snow wrote: > This parameter has been deprecated since 2.12.0 and is eligible for > removal. Remove this parameter as it is actually completely ignored; > let's not give false hope. > > Signed-off-by: John Snow > Reviewed-by: Eric Blake >

[libvirt] [PATCH v3] dirty-bitmaps: remove deprecated autoload parameter

2019-10-03 Thread John Snow
This parameter has been deprecated since 2.12.0 and is eligible for removal. Remove this parameter as it is actually completely ignored; let's not give false hope. Signed-off-by: John Snow Reviewed-by: Eric Blake Reviewed-by: Vladimir Sementsov-Ogievskiy --- V2: Change 2.12.0 -> 4.

[libvirt] [PULL 16/19] block/qcow2-bitmap: fix and improve qcow2_reopen_bitmaps_rw

2019-10-11 Thread John Snow
USE in the image. - Consider unexpected bitmap as a corruption and check other combinations of in-image and in-RAM bitmaps. Signed-off-by: Vladimir Sementsov-Ogievskiy Message-id: 20190927122355.7344-9-vsement...@virtuozzo.com Signed-off-by: John Snow --- block/qcow2-bitmap.c |

[libvirt] [PULL 17/19] qcow2-bitmap: move bitmap reopen-rw code to qcow2_reopen_commit

2019-10-11 Thread John Snow
aps_rw did a wrong check for being writable, when actually it only need writable file child not self. So, as it's fixed, let's move things to correct place. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: John Snow Acked-by: Max Reitz Message-id: 20190927122355.7344-10-v

[libvirt] [PULL 06/19] block/dirty-bitmap: add bs link

2019-10-11 Thread John Snow
From: Vladimir Sementsov-Ogievskiy Add bs field to BdrvDirtyBitmap structure. Drop BlockDriverState parameter from bitmap APIs where possible. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: John Snow Message-id: 20190916141911.5255-3-vsement...@virtuozzo.com Signed-off-by: John Snow

[libvirt] [PULL 09/19] block: switch reopen queue from QSIMPLEQ to QTAILQ

2019-10-11 Thread John Snow
From: Vladimir Sementsov-Ogievskiy We'll need reverse-foreach in the following commit, QTAILQ support it, so move to QTAILQ. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: Max Reitz Message-id: 20190927122355.7344-2-vsement...@virtuozzo.com Signed-off-by: John Snow --- include

[libvirt] [PULL 10/19] block: reverse order for reopen commits

2019-10-11 Thread John Snow
reopen commit. Reverse reopen order to fix it. Signed-off-by: Vladimir Sementsov-Ogievskiy Acked-by: Max Reitz Acked-by: John Snow Message-id: 20190927122355.7344-3-vsement...@virtuozzo.com Signed-off-by: John Snow --- block.c | 12 +--- 1 file changed, 9 insertions(+), 3 deletions

[libvirt] [PULL 15/19] iotests: add test 260 to check bitmap life after snapshot + commit

2019-10-11 Thread John Snow
From: Vladimir Sementsov-Ogievskiy Signed-off-by: Vladimir Sementsov-Ogievskiy Message-id: 20190927122355.7344-8-vsement...@virtuozzo.com Signed-off-by: John Snow --- tests/qemu-iotests/260 | 89 ++ tests/qemu-iotests/260.out | 52

[libvirt] [PULL 13/19] block/qcow2-bitmap: drop qcow2_reopen_bitmaps_rw_hint()

2019-10-11 Thread John Snow
From: Vladimir Sementsov-Ogievskiy The function is unused, drop it. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: John Snow Message-id: 20190927122355.7344-6-vsement...@virtuozzo.com Signed-off-by: John Snow --- block/qcow2.h| 2 -- block/qcow2-bitmap.c | 15

[libvirt] [PULL 18/19] MAINTAINERS: Add Vladimir as a reviewer for bitmaps

2019-10-11 Thread John Snow
I already try to make sure all bitmaps patches have been reviewed by both Red Hat and Virtuozzo anyway, so this formalizes the arrangement. Fam meanwhile is no longer as active, so I am removing him as a co-maintainer simply to reflect the current practice. Signed-off-by: John Snow Reviewed

[libvirt] [PULL 14/19] block/qcow2-bitmap: do not remove bitmaps on reopen-ro

2019-10-11 Thread John Snow
bitmaps rw will be fixed in the following patches. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: John Snow Message-id: 20190927122355.7344-7-vsement...@virtuozzo.com Signed-off-by: John Snow --- block/qcow2.h| 3 ++- block/qcow2-bitmap.c | 49

[libvirt] [PULL 19/19] dirty-bitmaps: remove deprecated autoload parameter

2019-10-11 Thread John Snow
This parameter has been deprecated since 2.12.0 and is eligible for removal. Remove this parameter as it is actually completely ignored; let's not give false hope. Signed-off-by: John Snow Reviewed-by: Eric Blake Reviewed-by: Vladimir Sementsov-Ogievskiy Message-id: 20191002232411.29968-1-js

[libvirt] [PULL 12/19] block/qcow2-bitmap: get rid of bdrv_has_changed_persistent_bitmaps

2019-10-11 Thread John Snow
drop IN_USE flag for unchanged bitmaps in the image. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: John Snow Message-id: 20190927122355.7344-5-vsement...@virtuozzo.com Signed-off-by: John Snow --- include/block/dirty-bitmap.h | 1 - block/dirty-bitmap.c | 12

Re: [libvirt] [PATCH v2 1/1] IDE: deprecate ide-drive

2019-10-11 Thread John Snow
On 10/11/19 5:12 AM, Peter Krempa wrote: > On Thu, Oct 10, 2019 at 14:08:12 -0400, John Snow wrote: >> On 10/10/19 7:54 AM, Peter Krempa wrote: >>> On Thu, Oct 10, 2019 at 13:42:26 +0200, Philippe Mathieu-Daudé wrote: >>>> On 10/10/19 1:26 PM, Peter Krempa wrote:

[libvirt] [PULL 00/19] Bitmaps patches

2019-10-11 Thread John Snow
John Snow (2): MAINTAINERS: Add Vladimir as a reviewer for bitmaps dirty-bitmaps: remove deprecated autoload parameter Vladimir Sementsov-Ogievskiy (17): util/hbitmap: strict hbitmap_reset block: move bdrv_can_store_new_dirty_bitmap to block/dirty-bitmap.c block/dirty-bitmap: return

[libvirt] [PULL 02/19] block: move bdrv_can_store_new_dirty_bitmap to block/dirty-bitmap.c

2019-10-11 Thread John Snow
From: Vladimir Sementsov-Ogievskiy block/dirty-bitmap.c seems to be more appropriate for it and bdrv_remove_persistent_dirty_bitmap already in it. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: John Snow Message-id: 20190920082543.23444-2-vsement...@virtuozzo.com Signed-off-by: John

[libvirt] [PULL 07/19] block/dirty-bitmap: drop BdrvDirtyBitmap.mutex

2019-10-11 Thread John Snow
ore obvious that it's not per-bitmap lock. Still, for simplicity, leave bdrv_dirty_bitmap_lock/unlock functions as an external API. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: John Snow Message-id: 20190916141911.5255-4-vsement...@virtuozzo.com Signed-off-by: John Snow --- block/di

[libvirt] [PULL 05/19] block/dirty-bitmap: drop meta

2019-10-11 Thread John Snow
From: Vladimir Sementsov-Ogievskiy Drop meta bitmaps, as they are unused. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: John Snow Message-id: 20190916141911.5255-2-vsement...@virtuozzo.com Signed-off-by: John Snow --- include/block/dirty-bitmap.h | 5 block/dirty-bitmap.c

[libvirt] [PULL 03/19] block/dirty-bitmap: return int from bdrv_remove_persistent_dirty_bitmap

2019-10-11 Thread John Snow
From: Vladimir Sementsov-Ogievskiy It's more comfortable to not deal with local_err. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: John Snow Message-id: 20190920082543.23444-3-vsement...@virtuozzo.com Signed-off-by: John Snow --- block/qcow2.h| 5 ++--- include

[libvirt] [PULL 04/19] block/qcow2: proper locking on bitmap add/remove paths

2019-10-11 Thread John Snow
qcow2_can_store_new_dirty_bitmap and qcow2_remove_persistent_dirty_bitmap to coroutine context. Since we work in coroutines in correct aio context, we don't need context acquiring in blockdev.c anymore, drop it. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: John Snow Message-id

[libvirt] [PULL 01/19] util/hbitmap: strict hbitmap_reset

2019-10-11 Thread John Snow
hb->orig_size. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: Max Reitz Message-Id: <20190806152611.280389-1-vsement...@virtuozzo.com> [Maintainer edit: Max's suggestions from on-list. --js] Signed-off-by: John Snow --- include/qemu/hbitmap.h | 5 + tests/test-hbitmap.c

[libvirt] [PULL 11/19] iotests: add test-case to 165 to test reopening qcow2 bitmaps to RW

2019-10-11 Thread John Snow
From: Vladimir Sementsov-Ogievskiy Reopening bitmaps to RW was broken prior to previous commit. Check that it works now. Signed-off-by: Vladimir Sementsov-Ogievskiy Message-id: 20190927122355.7344-4-vsement...@virtuozzo.com Signed-off-by: John Snow --- tests/qemu-iotests/165 | 57

[libvirt] [PULL 08/19] block/dirty-bitmap: refactor bdrv_dirty_bitmap_next

2019-10-11 Thread John Snow
From: Vladimir Sementsov-Ogievskiy bdrv_dirty_bitmap_next is always used in same pattern. So, split it into _next and _first, instead of combining two functions into one and add FOR_EACH_DIRTY_BITMAP macro. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: John Snow Message-id

Re: [libvirt] [PULL 01/19] util/hbitmap: strict hbitmap_reset

2019-10-11 Thread John Snow
On 10/11/19 5:48 PM, Eric Blake wrote: > On 10/11/19 4:25 PM, John Snow wrote: >> From: Vladimir Sementsov-Ogievskiy >> >> hbitmap_reset has an unobvious property: it rounds requested region up. >> It may provoke bugs, like in recently fixed write-blocking mode of

[libvirt] [PULL v2 04/19] block/qcow2: proper locking on bitmap add/remove paths

2019-10-14 Thread John Snow
qcow2_can_store_new_dirty_bitmap and qcow2_remove_persistent_dirty_bitmap to coroutine context. Since we work in coroutines in correct aio context, we don't need context acquiring in blockdev.c anymore, drop it. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: John Snow Message-id

[libvirt] [PULL v2 06/19] block/dirty-bitmap: add bs link

2019-10-14 Thread John Snow
From: Vladimir Sementsov-Ogievskiy Add bs field to BdrvDirtyBitmap structure. Drop BlockDriverState parameter from bitmap APIs where possible. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: John Snow Message-id: 20190916141911.5255-3-vsement...@virtuozzo.com [Rebased on top of block

[libvirt] [PULL v2 11/19] iotests: add test-case to 165 to test reopening qcow2 bitmaps to RW

2019-10-14 Thread John Snow
From: Vladimir Sementsov-Ogievskiy Reopening bitmaps to RW was broken prior to previous commit. Check that it works now. Signed-off-by: Vladimir Sementsov-Ogievskiy Message-id: 20190927122355.7344-4-vsement...@virtuozzo.com Signed-off-by: John Snow --- tests/qemu-iotests/165 | 57

[libvirt] [PULL v2 18/19] MAINTAINERS: Add Vladimir as a reviewer for bitmaps

2019-10-14 Thread John Snow
I already try to make sure all bitmaps patches have been reviewed by both Red Hat and Virtuozzo anyway, so this formalizes the arrangement. Fam meanwhile is no longer as active, so I am removing him as a co-maintainer simply to reflect the current practice. Signed-off-by: John Snow Reviewed

[libvirt] [PULL v2 09/19] block: switch reopen queue from QSIMPLEQ to QTAILQ

2019-10-14 Thread John Snow
From: Vladimir Sementsov-Ogievskiy We'll need reverse-foreach in the following commit, QTAILQ support it, so move to QTAILQ. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: Max Reitz Message-id: 20190927122355.7344-2-vsement...@virtuozzo.com Signed-off-by: John Snow --- include

[libvirt] [PULL v2 16/19] block/qcow2-bitmap: fix and improve qcow2_reopen_bitmaps_rw

2019-10-14 Thread John Snow
USE in the image. - Consider unexpected bitmap as a corruption and check other combinations of in-image and in-RAM bitmaps. Signed-off-by: Vladimir Sementsov-Ogievskiy Message-id: 20190927122355.7344-9-vsement...@virtuozzo.com Signed-off-by: John Snow --- block/qcow2-bitmap.c |

[libvirt] [PULL v2 17/19] qcow2-bitmap: move bitmap reopen-rw code to qcow2_reopen_commit

2019-10-14 Thread John Snow
aps_rw did a wrong check for being writable, when actually it only need writable file child not self. So, as it's fixed, let's move things to correct place. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: John Snow Acked-by: Max Reitz Message-id: 20190927122355.7344-10-v

[libvirt] [PULL v2 15/19] iotests: add test 260 to check bitmap life after snapshot + commit

2019-10-14 Thread John Snow
From: Vladimir Sementsov-Ogievskiy Signed-off-by: Vladimir Sementsov-Ogievskiy Message-id: 20190927122355.7344-8-vsement...@virtuozzo.com Signed-off-by: John Snow --- tests/qemu-iotests/260 | 89 ++ tests/qemu-iotests/260.out | 52

[libvirt] [PULL v2 13/19] block/qcow2-bitmap: drop qcow2_reopen_bitmaps_rw_hint()

2019-10-14 Thread John Snow
From: Vladimir Sementsov-Ogievskiy The function is unused, drop it. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: John Snow Message-id: 20190927122355.7344-6-vsement...@virtuozzo.com Signed-off-by: John Snow --- block/qcow2.h| 2 -- block/qcow2-bitmap.c | 15

[libvirt] [PULL v2 03/19] block/dirty-bitmap: return int from bdrv_remove_persistent_dirty_bitmap

2019-10-14 Thread John Snow
From: Vladimir Sementsov-Ogievskiy It's more comfortable to not deal with local_err. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: John Snow Message-id: 20190920082543.23444-3-vsement...@virtuozzo.com Signed-off-by: John Snow --- block/qcow2.h| 5 ++--- include

[libvirt] [PULL v2 10/19] block: reverse order for reopen commits

2019-10-14 Thread John Snow
reopen commit. Reverse reopen order to fix it. Signed-off-by: Vladimir Sementsov-Ogievskiy Acked-by: Max Reitz Acked-by: John Snow Message-id: 20190927122355.7344-3-vsement...@virtuozzo.com Signed-off-by: John Snow --- block.c | 12 +--- 1 file changed, 9 insertions(+), 3 deletions

[libvirt] [PULL v2 02/19] block: move bdrv_can_store_new_dirty_bitmap to block/dirty-bitmap.c

2019-10-14 Thread John Snow
From: Vladimir Sementsov-Ogievskiy block/dirty-bitmap.c seems to be more appropriate for it and bdrv_remove_persistent_dirty_bitmap already in it. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: John Snow Message-id: 20190920082543.23444-2-vsement...@virtuozzo.com Signed-off-by: John

[libvirt] [PULL v2 07/19] block/dirty-bitmap: drop BdrvDirtyBitmap.mutex

2019-10-14 Thread John Snow
ore obvious that it's not per-bitmap lock. Still, for simplicity, leave bdrv_dirty_bitmap_lock/unlock functions as an external API. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: John Snow Message-id: 20190916141911.5255-4-vsement...@virtuozzo.com Signed-off-by: John Snow --- block/di

[libvirt] [PULL v2 05/19] block/dirty-bitmap: drop meta

2019-10-14 Thread John Snow
From: Vladimir Sementsov-Ogievskiy Drop meta bitmaps, as they are unused. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: John Snow Message-id: 20190916141911.5255-2-vsement...@virtuozzo.com Signed-off-by: John Snow --- include/block/dirty-bitmap.h | 5 block/dirty-bitmap.c

[libvirt] [PULL v2 01/19] util/hbitmap: strict hbitmap_reset

2019-10-14 Thread John Snow
hb->orig_size. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: Max Reitz Message-Id: <20190806152611.280389-1-vsement...@virtuozzo.com> [Maintainer edit: Max's suggestions from on-list. --js] [Maintainer edit: Eric's suggestion for aligned macro. --js] Signed-off-by: John S

[libvirt] [PULL v2 00/19] Bitmaps patches

2019-10-14 Thread John Snow
John Snow (2): MAINTAINERS: Add Vladimir as a reviewer for bitmaps dirty-bitmaps: remove deprecated autoload parameter Vladimir Sementsov-Ogievskiy (17): util/hbitmap: strict hbitmap_reset block: move bdrv_can_store_new_dirty_bitmap to block/dirty-bitmap.c block/dirty-bitmap

Re: [libvirt] [PULL 01/19] util/hbitmap: strict hbitmap_reset

2019-10-14 Thread John Snow
On 10/11/19 7:18 PM, John Snow wrote: > > > On 10/11/19 5:48 PM, Eric Blake wrote: >> On 10/11/19 4:25 PM, John Snow wrote: >>> From: Vladimir Sementsov-Ogievskiy >>> >>> hbitmap_reset has an unobvious property: it rounds requested region up. >&

[libvirt] [PULL v2 12/19] block/qcow2-bitmap: get rid of bdrv_has_changed_persistent_bitmaps

2019-10-14 Thread John Snow
drop IN_USE flag for unchanged bitmaps in the image. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: John Snow Message-id: 20190927122355.7344-5-vsement...@virtuozzo.com Signed-off-by: John Snow --- include/block/dirty-bitmap.h | 1 - block/dirty-bitmap.c | 12

[libvirt] [PULL v2 19/19] dirty-bitmaps: remove deprecated autoload parameter

2019-10-14 Thread John Snow
This parameter has been deprecated since 2.12.0 and is eligible for removal. Remove this parameter as it is actually completely ignored; let's not give false hope. Signed-off-by: John Snow Reviewed-by: Eric Blake Reviewed-by: Vladimir Sementsov-Ogievskiy Message-id: 20191002232411.29968-1-js

[libvirt] [PULL v2 08/19] block/dirty-bitmap: refactor bdrv_dirty_bitmap_next

2019-10-14 Thread John Snow
From: Vladimir Sementsov-Ogievskiy bdrv_dirty_bitmap_next is always used in same pattern. So, split it into _next and _first, instead of combining two functions into one and add FOR_EACH_DIRTY_BITMAP macro. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: John Snow Message-id

[libvirt] [PULL v2 14/19] block/qcow2-bitmap: do not remove bitmaps on reopen-ro

2019-10-14 Thread John Snow
bitmaps rw will be fixed in the following patches. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: John Snow Message-id: 20190927122355.7344-7-vsement...@virtuozzo.com Signed-off-by: John Snow --- block/qcow2.h| 3 ++- block/qcow2-bitmap.c | 49

[PULL v2 10/11] nbd/server: use bdrv_dirty_bitmap_next_dirty_area

2020-03-18 Thread John Snow
becomes clean enough to not require any comment. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: Eric Blake Message-id: 20200205112041.6003-10-vsement...@virtuozzo.com Signed-off-by: John Snow --- nbd/server.c | 59 +--- 1 file changed, 19

[PULL v2 11/11] block/qcow2-bitmap: use bdrv_dirty_bitmap_next_dirty

2020-03-18 Thread John Snow
From: Vladimir Sementsov-Ogievskiy store_bitmap_data() loop does bdrv_set_dirty_iter() on each iteration, which means that we actually don't need iterator itself and we can use simpler bitmap API. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: Max Reitz Reviewed-by: John Snow

[PULL v2 09/11] nbd/server: introduce NBDExtentArray

2020-03-18 Thread John Snow
Signed-off-by: John Snow --- nbd/server.c | 210 +-- 1 file changed, 118 insertions(+), 92 deletions(-) diff --git a/nbd/server.c b/nbd/server.c index 3106aaf3b4..f90bb33a75 100644 --- a/nbd/server.c +++ b/nbd/server.c @@ -1909,27 +1909,98 @@ static

[PULL v2 02/11] hbitmap: assert that we don't create bitmap larger than INT64_MAX

2020-03-18 Thread John Snow
images, which can't exceed INT64_MAX anyway. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: Max Reitz Reviewed-by: Eric Blake Reviewed-by: John Snow Message-id: 20200205112041.6003-2-vsement...@virtuozzo.com Signed-off-by: John Snow --- util/hbitmap.c | 2 ++ 1 file changed, 2 insertions

[PULL v2 03/11] hbitmap: move hbitmap_iter_next_word to hbitmap.c

2020-03-18 Thread John Snow
From: Vladimir Sementsov-Ogievskiy The function is definitely internal (it's not used by third party and it has complicated interface). Move it to .c file. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: Max Reitz Reviewed-by: John Snow Message-id: 20200205112041.6003-3-vsement

[PULL v2 05/11] hbitmap: drop meta bitmaps as they are unused

2020-03-18 Thread John Snow
From: Vladimir Sementsov-Ogievskiy Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: Max Reitz Reviewed-by: John Snow Message-id: 20200205112041.6003-5-vsement...@virtuozzo.com Signed-off-by: John Snow --- include/qemu/hbitmap.h | 21 tests/test-hbitmap.c | 115

[PULL v2 01/11] build: Silence clang warning on older glib autoptr usage

2020-03-18 Thread John Snow
. Reported-by: Peter Maydell Signed-off-by: Eric Blake Reviewed-by: John Snow Message-id: 20200317175534.196295-1-ebl...@redhat.com Signed-off-by: John Snow --- configure | 20 1 file changed, 20 insertions(+) diff --git a/configure b/configure index 06fcd070fb..479336bf6e

[PULL v2 07/11] block/dirty-bitmap: add _next_dirty API

2020-03-18 Thread John Snow
some new checks. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: Max Reitz Reviewed-by: John Snow Message-id: 20200205112041.6003-7-vsement...@virtuozzo.com Signed-off-by: John Snow --- include/block/dirty-bitmap.h | 2 + include/qemu/hbitmap.h | 13 block/dirty-bitmap.c

[PULL v2 00/11] Bitmaps patches

2020-03-18 Thread John Snow
The following changes since commit d649689a8ecb2e276cc20d3af6d416e3c299cb17: Merge remote-tracking branch 'remotes/bonzini/tags/for-upstream' into staging (2020-03-17 18:33:05 +) are available in the Git repository at: https://github.com/jnsnow/qemu.git tags/bitmaps-pull-request for

[PULL v2 06/11] block/dirty-bitmap: switch _next_dirty_area and _next_zero to int64_t

2020-03-18 Thread John Snow
with hbitmap_next_zero, therefore we want hbitmap_next_zero parameter type to be int64_t too. So, for convenience update all parameters of *_next_zero and *_next_dirty_area to be int64_t. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: Max Reitz Reviewed-by: John Snow Message-id

[PULL v2 08/11] block/dirty-bitmap: improve _next_dirty_area API

2020-03-18 Thread John Snow
y to limit resulting area size, not limiting searching area. This will be used in NBD code in further commit. (Note that now bdrv_dirty_bitmap_next_dirty_area is unused) Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: Max Reitz Reviewed-by: John Snow Message-id: 20200205112041.6003

[PULL v2 04/11] hbitmap: unpublish hbitmap_iter_skip_words

2020-03-18 Thread John Snow
From: Vladimir Sementsov-Ogievskiy Function is internal and even commented as internal. Drop its definition from .h file. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: Max Reitz Reviewed-by: John Snow Message-id: 20200205112041.6003-4-vsement...@virtuozzo.com Signed-off-by: John

Re: [PULL v2 00/11] Bitmaps patches

2020-03-19 Thread John Snow
On 3/19/20 1:57 PM, Peter Maydell wrote: > On Wed, 18 Mar 2020 at 20:24, John Snow wrote: >> >> The following changes since commit d649689a8ecb2e276cc20d3af6d416e3c299cb17: >> >> Merge remote-tracking branch 'remotes/bonzini/tags/for-upstream' into >> s

[PULL 00/10] Bitmaps patches

2020-03-16 Thread John Snow
The following changes since commit 6e8a73e911f066527e775e04b98f31ebd19db600: Merge remote-tracking branch 'remotes/stefanha/tags/block-pull-request' into staging (2020-03-11 14:41:27 +) are available in the Git repository at: https://github.com/jnsnow/qemu.git tags/bitmaps-pull-request

[PULL 08/10] nbd/server: introduce NBDExtentArray

2020-03-16 Thread John Snow
Signed-off-by: John Snow --- nbd/server.c | 210 +-- 1 file changed, 118 insertions(+), 92 deletions(-) diff --git a/nbd/server.c b/nbd/server.c index 3106aaf3b4..f90bb33a75 100644 --- a/nbd/server.c +++ b/nbd/server.c @@ -1909,27 +1909,98 @@ static

[PULL 10/10] block/qcow2-bitmap: use bdrv_dirty_bitmap_next_dirty

2020-03-16 Thread John Snow
From: Vladimir Sementsov-Ogievskiy store_bitmap_data() loop does bdrv_set_dirty_iter() on each iteration, which means that we actually don't need iterator itself and we can use simpler bitmap API. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: Max Reitz Reviewed-by: John Snow

[PULL 02/10] hbitmap: move hbitmap_iter_next_word to hbitmap.c

2020-03-16 Thread John Snow
From: Vladimir Sementsov-Ogievskiy The function is definitely internal (it's not used by third party and it has complicated interface). Move it to .c file. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: Max Reitz Reviewed-by: John Snow Message-id: 20200205112041.6003-3-vsement

[PULL 09/10] nbd/server: use bdrv_dirty_bitmap_next_dirty_area

2020-03-16 Thread John Snow
becomes clean enough to not require any comment. Signed-off-by: Vladimir Sementsov-Ogievskiy Reviewed-by: Eric Blake Message-id: 20200205112041.6003-10-vsement...@virtuozzo.com Signed-off-by: John Snow --- nbd/server.c | 59 +--- 1 file changed, 19

<    1   2   3   >