QMP queue
Our lovely new command to query command-line options by Amos.
The changes (since 9953f8822cc316eec9962f0a2858c3439a80adec) are available in the following repository:
git://repo.or.cz/qemu/qmp-unstable.git queue/qmp
Amos Kong (1):
monitor: introduce query-command-line-options
qapi-schema.json | 66 +++++++++++++++++++++++++++++++++++++++++++++++++++++ qmp-commands.hx | 47 ++++++++++++++++++++++++++++++++++++++ util/qemu-config.c | 67 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 180 insertions(+)
Signature · 1 line
1.8.1.4
[Qemu-devel] [PULL] monitor: introduce query-command-line-options
From: Amos Kong <[email protected]>
Libvirt has no way to probe if an option or property is supported, This patch introduces a new qmp command to query command line option information. hmp command isn't added because it's not needed.
Signed-off-by Amos Kong <[email protected]>
CC Luiz Capitulino <[email protected]>
CC Osier Yang <[email protected]>
CC Anthony Liguori <[email protected]>
Signed-off-by Luiz Capitulino <[email protected]>
Reviewed-by Eric Blake <[email protected]>
--- qapi-schema.json | 66 +++++++++++++++++++++++++++++++++++++++++++++++++++++ qmp-commands.hx | 47 ++++++++++++++++++++++++++++++++++++++ util/qemu-config.c | 67 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 180 insertions(+)
qapi-schema.json +66 -0
@@ -3505,3 +3505,69 @@ '*asl_compiler_rev': 'uint32', '*file': 'str', '*data': 'str' }} + +## +# @CommandLineParameterType: +# +# Possible types for an option parameter. +# +# @string: accepts a character string +# +# @boolean: accepts "on" or "off" +# +# @number: accepts a number +# +# @size: accepts a number followed by an optional suffix (K)ilo, +# (M)ega, (G)iga, (T)era +# +# Since 1.5 +## +{ 'enum': 'CommandLineParameterType', + 'data': ['string', 'boolean', 'number', 'size'] } + +## +# @CommandLineParameterInfo: +# +# Details about a single parameter of a command line option. +# +# @name: parameter name +# +# @type: parameter @CommandLineParameterType +# +# @help: #optional human readable text string, not suitable for parsing. +# +# Since 1.5 +## +{ 'type': 'CommandLineParameterInfo', + 'data': { 'name': 'str', + 'type': 'CommandLineParameterType', + '*help': 'str' } } + +## +# @CommandLineOptionInfo: +# +# Details about a command line option, including its list of parameter details +# +# @option: option name +# +# @parameters: an array of @CommandLineParameterInfo +# +# Since 1.5 +## +{ 'type': 'CommandLineOptionInfo', + 'data': { 'option': 'str', 'parameters': ['CommandLineParameterInfo'] } } + +## +# @query-command-line-options: +# +# Query command line option schema. +# +# @option: #optional option name +# +# Returns: list of @CommandLineOptionInfo for all options (or for the given +# @option). Returns an error if the given @option doesn't exist. +# +# Since 1.5 +## +{'command': 'query-command-line-options', 'data': { '*option': 'str' }, + 'returns': ['CommandLineOptionInfo'] }
qmp-commands.hx +47 -0
53 lines not on this page · raw message
util/qemu-config.c +67 -0
79 lines not on this page · raw message
Signature · 1 line
1.8.1.4
Pulled. Thanks.
Regards,
Anthony Liguori