diff options
author | Maxim Levitsky <mlevitsk@redhat.com> | 2020-06-25 14:55:45 +0200 |
---|---|---|
committer | Max Reitz <mreitz@redhat.com> | 2020-07-06 08:49:28 +0200 |
commit | ced914d0ab9fb2c900f873f6349a0b8eecd1fdbe (patch) | |
tree | 651ec691a6528c21cb9aed02589cd7843cb3abde /include/block | |
parent | 11d80bfc6da00d8b53bf1cc2da19b4a2e0b23961 (diff) | |
download | qemu-ced914d0ab9fb2c900f873f6349a0b8eecd1fdbe.zip qemu-ced914d0ab9fb2c900f873f6349a0b8eecd1fdbe.tar.gz qemu-ced914d0ab9fb2c900f873f6349a0b8eecd1fdbe.tar.bz2 |
block/core: add generic infrastructure for x-blockdev-amend qmp command
blockdev-amend will be used similiar to blockdev-create
to allow on the fly changes of the structure of the format based block devices.
Current plan is to first support encryption keyslot management for luks
based formats (raw and embedded in qcow2)
Signed-off-by: Maxim Levitsky <mlevitsk@redhat.com>
Reviewed-by: Daniel P. Berrangé <berrange@redhat.com>
Message-Id: <20200608094030.670121-12-mlevitsk@redhat.com>
Signed-off-by: Max Reitz <mreitz@redhat.com>
Diffstat (limited to 'include/block')
-rw-r--r-- | include/block/block_int.h | 21 |
1 files changed, 15 insertions, 6 deletions
diff --git a/include/block/block_int.h b/include/block/block_int.h index ed33551..1b86b59 100644 --- a/include/block/block_int.h +++ b/include/block/block_int.h @@ -141,12 +141,27 @@ struct BlockDriver { int (*bdrv_file_open)(BlockDriverState *bs, QDict *options, int flags, Error **errp); void (*bdrv_close)(BlockDriverState *bs); + + int coroutine_fn (*bdrv_co_create)(BlockdevCreateOptions *opts, Error **errp); int coroutine_fn (*bdrv_co_create_opts)(BlockDriver *drv, const char *filename, QemuOpts *opts, Error **errp); + + int coroutine_fn (*bdrv_co_amend)(BlockDriverState *bs, + BlockdevAmendOptions *opts, + bool force, + Error **errp); + + int (*bdrv_amend_options)(BlockDriverState *bs, + QemuOpts *opts, + BlockDriverAmendStatusCB *status_cb, + void *cb_opaque, + bool force, + Error **errp); + int (*bdrv_make_empty)(BlockDriverState *bs); /* @@ -441,12 +456,6 @@ struct BlockDriver { BdrvCheckResult *result, BdrvCheckMode fix); - int (*bdrv_amend_options)(BlockDriverState *bs, QemuOpts *opts, - BlockDriverAmendStatusCB *status_cb, - void *cb_opaque, - bool force, - Error **errp); - void (*bdrv_debug_event)(BlockDriverState *bs, BlkdebugEvent event); /* TODO Better pass a option string/QDict/QemuOpts to add any rule? */ |