-static QEMUOptionParameter vhdx_create_options[] = {
- {
- .name = BLOCK_OPT_SIZE,
- .type = OPT_SIZE,
- .help = "Virtual disk size; max of 64TB."
- },
- {
- .name = VHDX_BLOCK_OPT_LOG_SIZE,
- .type = OPT_SIZE,
- .value.n = 1 * MiB,
- .help = "Log size; min 1MB."
- },
- {
- .name = VHDX_BLOCK_OPT_BLOCK_SIZE,
- .type = OPT_SIZE,
- .value.n = 0,
- .help = "Block Size; min 1MB, max 256MB. " \
- "0 means auto-calculate based on image size."
- },
- {
- .name = BLOCK_OPT_SUBFMT,
- .type = OPT_STRING,
- .help = "VHDX format type, can be either 'dynamic' or 'fixed'. "\
- "Default is 'dynamic'."
- },
- {
- .name = VHDX_BLOCK_OPT_ZERO,
- .type = OPT_FLAG,
- .help = "Force use of payload blocks of type 'ZERO'. Non-standard."
- },
- { NULL }
+static QemuOptsList vhdx_create_opts = {
+ .name = "vhdx-create-opts",
+ .head = QTAILQ_HEAD_INITIALIZER(vhdx_create_opts.head),
+ .desc = {
+ {
+ .name = BLOCK_OPT_SIZE,
+ .type = QEMU_OPT_SIZE,
+ .help = "Virtual disk size; max of 64TB."
+ },
+ {
+ .name = VHDX_BLOCK_OPT_LOG_SIZE,
+ .type = QEMU_OPT_SIZE,
+ .def_value_str = stringify(DEFAULT_LOG_SIZE),
+ .help = "Log size; min 1MB."
+ },
+ {
+ .name = VHDX_BLOCK_OPT_BLOCK_SIZE,
+ .type = QEMU_OPT_SIZE,
+ .def_value_str = stringify(0),
+ .help = "Block Size; min 1MB, max 256MB. " \
+ "0 means auto-calculate based on image size."
+ },
+ {
+ .name = BLOCK_OPT_SUBFMT,
+ .type = QEMU_OPT_STRING,
+ .help = "VHDX format type, can be either 'dynamic' or 'fixed'. "\
+ "Default is 'dynamic'."
+ },
+ {
+ .name = VHDX_BLOCK_OPT_ZERO,
+ .type = QEMU_OPT_BOOL,
+ .help = "Force use of payload blocks of type 'ZERO'. "\
+ "Non-standard, but default. Do not set to 'off' when "\
+ "using 'qemu-img convert' with subformat=dynamic."
+ },
+ { NULL }
+ }