diff options
author | Max Reitz <mreitz@redhat.com> | 2018-03-12 17:55:26 +0100 |
---|---|---|
committer | Kevin Wolf <kwolf@redhat.com> | 2018-03-19 12:01:39 +0100 |
commit | 49858b5098ee4cf1a50587f83fdeb163cf81d54d (patch) | |
tree | 1d2272928029f16d3440d0c0d0840fc4d6b17e3e /qapi | |
parent | d06195e6a66733851701e8f8b56afd99e073448c (diff) | |
download | qemu-49858b5098ee4cf1a50587f83fdeb163cf81d54d.zip qemu-49858b5098ee4cf1a50587f83fdeb163cf81d54d.tar.gz qemu-49858b5098ee4cf1a50587f83fdeb163cf81d54d.tar.bz2 |
vdi: Pull option parsing from vdi_co_create
In preparation of QAPI-fying VDI image creation, we have to create a
BlockdevCreateOptionsVdi type which is received by a (future)
vdi_co_create().
vdi_co_create_opts() now converts the QemuOpts object into such a
BlockdevCreateOptionsVdi object. The protocol-layer file is still
created in vdi_co_do_create() (and BlockdevCreateOptionsVdi.file is set
to an empty string), but that will be addressed by a follow-up patch.
Note that cluster-size is not part of the QAPI schema because it is not
supported by default.
Signed-off-by: Max Reitz <mreitz@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Diffstat (limited to 'qapi')
-rw-r--r-- | qapi/block-core.json | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/qapi/block-core.json b/qapi/block-core.json index 48f86ce..822ea0a 100644 --- a/qapi/block-core.json +++ b/qapi/block-core.json @@ -3769,6 +3769,24 @@ 'size': 'size' } } ## +# @BlockdevCreateOptionsVdi: +# +# Driver specific image creation options for VDI. +# +# @file Node to create the image format on +# @size Size of the virtual disk in bytes +# @static Whether to create a statically (true) or +# dynamically (false) allocated image +# (default: false, i.e. dynamic) +# +# Since: 2.12 +## +{ 'struct': 'BlockdevCreateOptionsVdi', + 'data': { 'file': 'BlockdevRef', + 'size': 'size', + '*static': 'bool' } } + +## # @BlockdevCreateNotSupported: # # This is used for all drivers that don't support creating images. |