qemu-patch-raspberry4/include/block
Max Reitz 7748543420 block: Add status callback to bdrv_amend_options()
Depending on the changed options and the image format,
bdrv_amend_options() may take a significant amount of time. In these
cases, a way to be informed about the operation's status is desirable.

Since the operation is rather complex and may fundamentally change the
image, implementing it as AIO or a coroutine does not seem feasible. On
the other hand, implementing it as a block job would be significantly
more difficult than a simple callback and would not add benefits other
than progress report to the amending operation, because it should not
actually be run as a block job at all.

A callback may not be very pretty, but it's very easy to implement and
perfectly fits its purpose here.

Signed-off-by: Max Reitz <mreitz@redhat.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
Reviewed-by: Benoît Canet <benoit.canet@nodalink.com>
Reviewed-by: Kevin Wolf <kwolf@redhat.com>
Message-id: 1414404776-4919-2-git-send-email-mreitz@redhat.com
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
2014-11-03 11:41:48 +00:00
..
accounting.h block: Make the block accounting functions operate on BlockAcctStats 2014-09-10 10:41:29 +02:00
aio.h block: Rename BlockDriverCompletionFunc to BlockCompletionFunc 2014-10-20 13:41:27 +02:00
block.h block: Add status callback to bdrv_amend_options() 2014-11-03 11:41:48 +00:00
block_int.h block: Add status callback to bdrv_amend_options() 2014-11-03 11:41:48 +00:00
blockjob.h blockjob: Add "ready" field 2014-11-03 11:41:48 +00:00
coroutine.h coroutine: Drop co_sleep_ns 2014-08-29 10:46:58 +01:00
coroutine_int.h coroutine: stop using AioContext in CoQueue 2013-05-24 16:17:56 +02:00
nbd.h nbd: Handle NBD_OPT_LIST option. 2014-06-30 12:50:17 +02:00
qapi.h block/qapi: Convert qmp_query_block() to BlockBackend 2014-10-20 14:03:50 +02:00
scsi.h scsi: Print command name in debug 2014-06-18 08:47:10 +02:00
snapshot.h qemu-nbd: support internal snapshot export 2013-12-04 15:19:00 +01:00
thread-pool.h block: Rename BlockDriverCompletionFunc to BlockCompletionFunc 2014-10-20 13:41:27 +02:00