qemu-patch-raspberry4/include
John Snow 9bd2b08f27 block: Add bitmap successors
A bitmap successor is an anonymous BdrvDirtyBitmap that is intended to
be created just prior to a sensitive operation (e.g. Incremental Backup)
that can either succeed or fail, but during the course of which we still
want a bitmap tracking writes.

On creating a successor, we "freeze" the parent bitmap which prevents
its deletion, enabling, anonymization, or creating a bitmap with the
same name.

On success, the parent bitmap can "abdicate" responsibility to the
successor, which will inherit its name. The successor will have been
tracking writes during the course of the backup operation. The parent
will be safely deleted.

On failure, we can "reclaim" the successor from the parent, unifying
them such that the resulting bitmap describes all writes occurring since
the last successful backup, for instance. Reclamation will thaw the
parent, but not explicitly re-enable it.

BdrvDirtyBitmap operations that target a single bitmap are protected
by assertions that the bitmap is not frozen and/or disabled.

BdrvDirtyBitmap operations that target a group of bitmaps, such as
bdrv_{set,reset}_dirty will ignore frozen/disabled drives with a
conditional instead.

Internal functions that enable/disable dirty bitmaps have assertions
added to them to prevent modifying frozen bitmaps.

Signed-off-by: John Snow <jsnow@redhat.com>
Reviewed-by: Max Reitz <mreitz@redhat.com>
Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
Message-id: 1429314609-29776-10-git-send-email-jsnow@redhat.com
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
2015-04-28 15:36:10 +02:00
..
block block: Add bitmap successors 2015-04-28 15:36:10 +02:00
disas disas: Implement disassembly output for A64 2014-02-08 14:50:48 +00:00
exec target-arm: Add user-mode transaction attribute 2015-04-26 16:49:25 +01:00
fpu softfloat: expand out STATUS macro 2015-02-06 16:11:38 +00:00
hw Convert (ffs(val) - 1) to ctz32(val) 2015-04-28 15:36:08 +02:00
libdecnumber Fix new typos in comments (found by codespell) 2014-07-18 17:45:36 +04:00
migration migration: Remove unused functions 2015-03-17 15:20:37 +01:00
monitor qom: Implement info qom-tree HMP command 2015-03-17 14:31:21 +01:00
net virtio-net,tap: use standard-headers 2015-02-26 13:04:04 +01:00
qapi block: use bdrv_get_device_or_node_name() in error messages 2015-04-28 15:36:09 +02:00
qemu hbitmap: add hbitmap_merge 2015-04-28 15:36:10 +02:00
qom exec.c: Capture the memory attributes for a watchpoint hit 2015-04-26 16:49:24 +01:00
standard-headers virtio_blk: comment fix 2015-04-28 15:36:09 +02:00
sysemu block-backend: Expose bdrv_write_zeroes() 2015-04-28 15:36:08 +02:00
ui spice: misc fixes. 2015-04-27 20:00:57 +01:00
config.h janitor: move remaining public headers to include/ 2012-12-19 08:32:46 +01:00
elf.h elf-loader: Provide the possibility to relocate s390 ELF files 2015-03-10 09:26:27 +01:00
glib-compat.h glib-compat: fix problems with not-quite glib 2.22 2015-04-02 16:53:42 +01:00
qemu-common.h qxl: refactor rounding up to a nearest power of 2 2015-03-03 08:33:08 +01:00
qemu-io.h qemu-io: Use BlockBackend 2015-02-16 15:07:19 +00:00
qjson.h QJSON: Add JSON writer 2015-02-05 17:16:14 +01:00
trace-tcg.h trace: [tcg] Generate TCG tracing routines 2014-08-12 14:26:12 +01:00
trace.h trace: [tcg] Include event definitions in "trace.h" 2014-08-12 14:26:12 +01:00