qemu-e2k/include/block
Vladimir Sementsov-Ogievskiy 1c14eaabdb block: introduce snapshot-access block driver
The new block driver simply utilizes snapshot-access API of underlying
block node.

In further patches we want to use it like this:

[guest]                   [NBD export]
   |                            |
   | root                       | root
   v                 file       v
[copy-before-write]<------[snapshot-access]
   |           |
   | file      | target
   v           v
[active-disk] [temp.img]

This way, NBD client will be able to read snapshotted state of active
disk, when active disk is continued to be written by guest. This is
known as "fleecing", and currently uses another scheme based on qcow2
temporary image which backing file is active-disk. New scheme comes
with benefits - see next commit.

The other possible application is exporting internal snapshots of
qcow2, like this:

[guest]          [NBD export]
   |                  |
   | root             | root
   v       file       v
[qcow2]<---------[snapshot-access]

For this, we'll need to implement snapshot-access API handlers in
qcow2 driver, and improve snapshot-access block driver (and API) to
make it possible to select snapshot by name. Another thing to improve
is size of snapshot. Now for simplicity we just use size of bs->file,
which is OK for backup, but for qcow2 snapshots export we'll need to
imporve snapshot-access API to get size of snapshot.

Signed-off-by: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>
Message-Id: <20220303194349.2304213-12-vsementsov@virtuozzo.com>
[hreitz: Rebased on block GS/IO split]
Signed-off-by: Hanna Reitz <hreitz@redhat.com>
2022-03-07 09:33:31 +01:00
..
accounting.h block: add empty account cookie type 2019-10-10 10:56:18 +02:00
aio-wait.h qemu/atomic.h: rename atomic_ to qatomic_ 2020-09-23 16:07:44 +01:00
aio.h aio-posix: split poll check from ready handler 2022-01-12 17:09:39 +00:00
aio_task.h block: introduce aio task pool 2019-10-10 10:56:17 +02:00
block-common.h block: fix preallocate filter: don't do unaligned preallocate requests 2022-03-07 09:19:20 +01:00
block-copy.h block/block-copy: add block_copy_reset() 2022-03-07 09:33:30 +01:00
block-global-state.h include/block/block: split header into I/O and global state API 2022-03-04 18:18:25 +01:00
block-hmp-cmds.h monitor/hmp: move hmp_info_block* to block-hmp-cmds.c 2020-03-09 18:20:21 +00:00
block-io.h IO_CODE and IO_OR_GS_CODE for block I/O API 2022-03-04 18:18:25 +01:00
block.h include/block/block: split header into I/O and global state API 2022-03-04 18:18:25 +01:00
block_backup.h block/backup: drop unused synchronization interface 2018-12-14 11:52:40 +01:00
block_int-common.h block: introduce snapshot-access block driver 2022-03-07 09:33:31 +01:00
block_int-global-state.h block: introduce assert_bdrv_graph_writable 2022-03-04 18:18:25 +01:00
block_int-io.h block/io: introduce block driver snapshot-access API 2022-03-07 09:33:31 +01:00
block_int.h include/block/block_int: split header into I/O and global state API 2022-03-04 18:18:25 +01:00
blockjob.h include/block/blockjob.h: global state API 2022-03-04 18:18:25 +01:00
blockjob_int.h include/block/blockjob_int.h: split header into I/O and GS API 2022-03-04 18:18:25 +01:00
dirty-bitmap.h block/dirty-bitmap: introduce bdrv_dirty_bitmap_status() 2022-03-07 09:33:30 +01:00
export.h block/export: Move blk to BlockExport 2020-10-02 15:46:40 +02:00
fuse.h fuse: Allow exporting BDSs via FUSE 2020-12-11 17:52:39 +01:00
nbd.h nbd/client-connection: add option for non-blocking connection attempt 2021-06-18 12:21:22 -05:00
nvme.h hw/nvme: 64-bit pi support 2022-03-03 09:30:21 +01:00
qapi.h qapi: Allow getting flat output from 'query-named-block-nodes' 2020-02-20 16:43:42 +01:00
qdict.h vl: plumb keyval-based options into -readconfig 2021-06-04 13:50:04 +02:00
raw-aio.h linux-aio: add `dev_max_batch` parameter to laio_io_unplug() 2021-11-02 13:03:35 +01:00
replication.h replication: move include out of root directory 2021-05-26 14:49:46 +02:00
reqlist.h block/reqlist: add reqlist_wait_all() 2022-03-07 09:33:30 +01:00
snapshot.h include/block/snapshot: global state API + assertions 2022-03-04 18:18:25 +01:00
thread-pool.h Clean up decorations and whitespace around header guards 2016-07-12 16:20:46 +02:00
throttle-groups.h block/throttle-groups: throttle_group_co_io_limits_intercept(): 64bit bytes 2021-02-03 08:14:00 -06:00
write-threshold.h write-threshold: deal with includes 2021-05-14 16:14:10 +02:00