[PATCH] os-posix: Allow 'chroot' via '-run-with' and deprecate the old '-chroot' option
Thomas Huth
thuth at redhat.com
Fri Jun 30 16:11:54 UTC 2023
On 30/06/2023 17.56, Michael Tokarev wrote:
> 30.06.2023 18:01, Thomas Huth wrote:
>> We recently introduced "-run-with" for options that influence the
>> runtime behavior of QEMU. This option has the big advantage that it
>> can group related options (so that it is easier for the users to spot
>> them) and that the options become introspectable via QMP this way.
>> So let's start moving more switches into this option group, starting
>> with "-chroot" now.
> ...
>> +static QemuOptsList qemu_run_with_opts = {
>> + .name = "run-with",
>> + .head = QTAILQ_HEAD_INITIALIZER(qemu_run_with_opts.head),
>> + .desc = {
>> +#if defined(CONFIG_LINUX)
>> + {
>> + .name = "async-teardown",
>> + .type = QEMU_OPT_BOOL,
>> + },
>> +#endif
>> + {
>> + .name = "chroot",
>> + .type = QEMU_OPT_STRING,
>> + },
>> + { /* end of list */ }
>> + },
>> +};
>> +
>> +static void register_teardown(void)
>> +{
>> + qemu_add_opts(&qemu_run_with_opts);
>> +}
>> +opts_init(register_teardown);
>
> Hmm.. Is it still register_teardown? :)
Drat. Should be something like "register_runwith" now, of course. Thanks for
spotting it!
Thomas
> Other than that,
>
> Reviewed-by: Michael Tokarev <mjt at tls.msk.ru>
>
> /mjt
>
More information about the libvir-list
mailing list