qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH RFC] blockdev: copy legacy and common opts to qe


From: Kevin Wolf
Subject: Re: [Qemu-devel] [PATCH RFC] blockdev: copy legacy and common opts to qemu_drive_opts
Date: Mon, 4 Nov 2013 12:27:10 +0100
User-agent: Mutt/1.5.21 (2010-09-15)

Am 04.11.2013 um 08:01 hat Amos Kong geschrieben:
> Currently we have three QemuOptsList (qemu_common_drive_opts,
> qemu_legacy_drive_opts, and qemu_drive_opts), only qemu_drive_opts
> is added to vm_config_groups[].
> 
> We query commandline options by checking information in
> vm_config_groups[], so we can only get a NULL parameter list now.
> 
> This patch copied desc items of qemu_legacy_drive_opts and
> qemu_common_drive_opts to qemu_drive_opts.
> 
> Signed-off-by: Amos Kong <address@hidden>

This breaks driver-specific options because they aren't (and cannot be)
listed in the QemuOptsList.

For example:

$ x86_64-softmmu/qemu-system-x86_64 -drive file.driver=nbd,file.host=localhost
qemu-system-x86_64: -drive file.driver=nbd,file.host=localhost: Invalid 
parameter 'file.driver'

query-command-line-options isn't an appropriate API to query the -drive
capabilities in the blockdev-add world. You really want to have
introspection for that.

For compatibility, we might want to at least expose part of the provided
options there. In this case you should modify the monitor command to
access the local QemuOptsLists of drive_init() and blockdev_init() for
option="drive".

Kevin



reply via email to

[Prev in Thread] Current Thread [Next in Thread]