6 # = QMP monitor control
12 # Enable QMP capabilities.
16 # @enable: An optional list of QMPCapability values to enable. The
17 # client must not enable any capability that is not
18 # mentioned in the QMP greeting message. If the field is not
19 # provided, it means no QMP capabilities will be enabled.
24 # -> { "execute": "qmp_capabilities",
25 # "arguments": { "enable": [ "oob" ] } }
28 # Notes: This command is valid exactly when first connecting: it must be
29 # issued before any other command will be accepted, and will fail once the
30 # monitor is accepting other commands. (see qemu docs/interop/qmp-spec.txt)
32 # The QMP client needs to explicitly enable QMP capabilities, otherwise
33 # all the QMP capabilities will be turned off by default.
38 { 'command': 'qmp_capabilities',
39 'data': { '*enable': [ 'QMPCapability' ] },
40 'allow-preconfig': true }
45 # Enumeration of capabilities to be advertised during initial client
46 # connection, used for agreeing on particular QMP extension behaviors.
48 # @oob: QMP ability to support out-of-band requests.
49 # (Please refer to qmp-spec.txt for more information on OOB)
54 { 'enum': 'QMPCapability',
60 # A three-part version number.
62 # @major: The major version number.
64 # @minor: The minor version number.
66 # @micro: The micro version number.
70 { 'struct': 'VersionTriple',
71 'data': {'major': 'int', 'minor': 'int', 'micro': 'int'} }
77 # A description of QEMU's version.
79 # @qemu: The version of QEMU. By current convention, a micro
80 # version of 50 signifies a development branch. A micro version
81 # greater than or equal to 90 signifies a release candidate for
82 # the next minor version. A micro version of less than 50
83 # signifies a stable release.
85 # @package: QEMU will always set this field to an empty string. Downstream
86 # versions of QEMU should set this to a non-empty string. The
87 # exact format depends on the downstream however it highly
88 # recommended that a unique name is used.
92 { 'struct': 'VersionInfo',
93 'data': {'qemu': 'VersionTriple', 'package': 'str'} }
98 # Returns the current version of QEMU.
100 # Returns: A @VersionInfo object describing the current version of QEMU.
106 # -> { "execute": "query-version" }
119 { 'command': 'query-version', 'returns': 'VersionInfo',
120 'allow-preconfig': true }
125 # Information about a QMP command
127 # @name: The command name
131 { 'struct': 'CommandInfo', 'data': {'name': 'str'} }
136 # Return a list of supported QMP commands by this server
138 # Returns: A list of @CommandInfo for all supported commands
144 # -> { "execute": "query-commands" }
148 # "name":"query-balloon"
151 # "name":"system_powerdown"
156 # Note: This example has been shortened as the real response is too long.
159 { 'command': 'query-commands', 'returns': ['CommandInfo'],
160 'allow-preconfig': true }
165 # Information about a QMP event
167 # @name: The event name
171 { 'struct': 'EventInfo', 'data': {'name': 'str'} }
176 # Return information on QMP events.
179 # @deprecated: This command is deprecated, because its output doesn't
180 # reflect compile-time configuration. Use 'query-qmp-schema'
183 # Returns: A list of @EventInfo.
189 # -> { "execute": "query-events" }
201 # Note: This example has been shortened as the real response is too long.
204 { 'command': 'query-events', 'returns': ['EventInfo'],
205 'features': [ 'deprecated' ] }
210 # This command will cause the QEMU process to exit gracefully. While every
211 # attempt is made to send the QMP response before terminating, this is not
212 # guaranteed. When using this interface, a premature EOF would not be
219 # -> { "execute": "quit" }
220 # <- { "return": {} }
223 'allow-preconfig': true }
228 # An enumeration of monitor modes.
230 # @readline: HMP monitor (human-oriented command line interface)
232 # @control: QMP monitor (JSON-based machine interface)
236 { 'enum': 'MonitorMode', 'data': [ 'readline', 'control' ] }
241 # Options to be used for adding a new monitor.
243 # @id: Name of the monitor
245 # @mode: Selects the monitor mode (default: readline in the system
246 # emulator, control in qemu-storage-daemon)
248 # @pretty: Enables pretty printing (QMP only)
250 # @chardev: Name of a character device to expose the monitor on
254 { 'struct': 'MonitorOptions',
257 '*mode': 'MonitorMode',