Am 11.11.2020 um 15:25 hat Paolo Bonzini geschrieben:
> This is yet another RFC on the command-line parsing overhaul. Here,
> I'm switching HMP, -object and -readconfig away from QemuOpts. There are
> pending QemuOpts and keyval patches that make the syntaxes the same
> apart from:
>
> - "implicit value" options (where the lack of value is turned
> into "on" or "off"), which will be deprecated
>
> - the processing of invalid, empty or overlong keys which can be considered
> bugfixes.
>
> Along the way, the object_add HMP command grows help support.
>
> The plan on top of this is to also keyval-ify -M and -accel. The reason
> for this, in my evil plan, is to allow for compound properties. These
> compound properties would be used for replacements of options like -smp
> (-M smp.xxx), -icount (-accel tcg,icount.xxx) and -chardev (as in -object
> chardev-socket,addr.host).
I haven't reviewed everything in detail, but this approach looks
workable to me.
Of course, at the moment -object is a bit different from other options
in that it doesn't have a QAPI object for the options, but you just
directly pass QDicts to user_creatable_add_dict(). But plugging in a
visitor for other options groups doesn't suddenly require a different
design, so this is fine.
Kevin