On 09/25/2015 08:03 AM, [email protected] wrote: > From: Marc-André Lureau <[email protected]> > > This was initially done to add qmp_capabilities documentation to the > schema. Then I figured it would also help to get rid of the "middle > mode" monitor dispatch code. > > Signed-off-by: Marc-André Lureau <[email protected]> > --- > monitor.c | 4 ++-- > qapi-schema.json | 17 +++++++++++++++++ > qmp-commands.hx | 2 +- > 3 files changed, 20 insertions(+), 3 deletions(-) >
> +++ b/qapi-schema.json
> @@ -21,6 +21,23 @@
> { 'include': 'qapi/introspect.json' }
>
> ##
> +# @qmp_capabilities:
> +#
> +# Enable QMP capabilities.
> +#
> +# Arguments: None.
> +#
> +# Example:
> +#
> +# -> { "execute": "qmp_capabilities" }
> +# <- { "return": {} }
> +#
> +# Notes: This command must be issued before issuing any other command.
I'd also mention that it is only accepted once; maybe this is better?
Notes: This command is valid exactly when first connecting: it must be
issued before any other command will be accepted, and will fail once the
monitor is accepting other commands.
Otherwise, I'm a fan of this patch.
--
Eric Blake eblake redhat com +1-919-301-3266
Libvirt virtualization library http://libvirt.org
signature.asc
Description: OpenPGP digital signature
