blob: a90aeb1d917fd4484fa63fc1c4b070de0fe5c2ed [file] [log] [blame]
Anthony Liguorie3193602011-09-02 12:34:47 -05001# -*- Mode: Python -*-
2#
3# QAPI Schema
Anthony Liguori48a32be2011-09-02 12:34:48 -05004
5##
Luiz Capitulinodcafd322012-07-27 09:34:50 -03006# @ErrorClass
7#
8# QEMU error classes
9#
10# @GenericError: this is used for errors that don't require a specific error
11# class. This should be the default case for most errors
12#
13# @CommandNotFound: the requested command has not been found
14#
15# @DeviceEncrypted: the requested operation can't be fulfilled because the
16# selected device is encrypted
17#
18# @DeviceNotActive: a device has failed to be become active
19#
20# @DeviceNotFound: the requested device has not been found
21#
22# @KVMMissingCap: the requested operation can't be fulfilled because a
23# required KVM capability is missing
24#
Luiz Capitulinodcafd322012-07-27 09:34:50 -030025# Since: 1.2
26##
27{ 'enum': 'ErrorClass',
28 'data': [ 'GenericError', 'CommandNotFound', 'DeviceEncrypted',
Paolo Bonzini1e998142012-10-23 14:54:21 +020029 'DeviceNotActive', 'DeviceNotFound', 'KVMMissingCap' ] }
Luiz Capitulinodcafd322012-07-27 09:34:50 -030030
31##
Luiz Capitulinob224e5e2012-09-13 16:52:20 -030032# @add_client
33#
34# Allow client connections for VNC, Spice and socket based
35# character devices to be passed in to QEMU via SCM_RIGHTS.
36#
37# @protocol: protocol name. Valid names are "vnc", "spice" or the
38# name of a character device (eg. from -chardev id=XXXX)
39#
40# @fdname: file descriptor name previously passed via 'getfd' command
41#
42# @skipauth: #optional whether to skip authentication. Only applies
43# to "vnc" and "spice" protocols
44#
45# @tls: #optional whether to perform TLS. Only applies to the "spice"
46# protocol
47#
48# Returns: nothing on success.
49#
50# Since: 0.14.0
51##
52{ 'command': 'add_client',
53 'data': { 'protocol': 'str', 'fdname': 'str', '*skipauth': 'bool',
54 '*tls': 'bool' } }
55
56##
Anthony Liguori48a32be2011-09-02 12:34:48 -050057# @NameInfo:
58#
59# Guest name information.
60#
61# @name: #optional The name of the guest
62#
63# Since 0.14.0
64##
65{ 'type': 'NameInfo', 'data': {'*name': 'str'} }
66
67##
68# @query-name:
69#
70# Return the name information of a guest.
71#
72# Returns: @NameInfo of the guest
73#
74# Since 0.14.0
75##
76{ 'command': 'query-name', 'returns': 'NameInfo' }
Luiz Capitulinob9c15f12011-08-26 17:38:13 -030077
78##
79# @VersionInfo:
80#
81# A description of QEMU's version.
82#
83# @qemu.major: The major version of QEMU
84#
85# @qemu.minor: The minor version of QEMU
86#
87# @qemu.micro: The micro version of QEMU. By current convention, a micro
88# version of 50 signifies a development branch. A micro version
89# greater than or equal to 90 signifies a release candidate for
90# the next minor version. A micro version of less than 50
91# signifies a stable release.
92#
93# @package: QEMU will always set this field to an empty string. Downstream
94# versions of QEMU should set this to a non-empty string. The
95# exact format depends on the downstream however it highly
96# recommended that a unique name is used.
97#
98# Since: 0.14.0
99##
100{ 'type': 'VersionInfo',
101 'data': {'qemu': {'major': 'int', 'minor': 'int', 'micro': 'int'},
102 'package': 'str'} }
103
104##
105# @query-version:
106#
107# Returns the current version of QEMU.
108#
109# Returns: A @VersionInfo object describing the current version of QEMU.
110#
111# Since: 0.14.0
112##
113{ 'command': 'query-version', 'returns': 'VersionInfo' }
Luiz Capitulino292a2602011-09-12 15:10:53 -0300114
115##
116# @KvmInfo:
117#
118# Information about support for KVM acceleration
119#
120# @enabled: true if KVM acceleration is active
121#
122# @present: true if KVM acceleration is built into this executable
123#
124# Since: 0.14.0
125##
126{ 'type': 'KvmInfo', 'data': {'enabled': 'bool', 'present': 'bool'} }
127
128##
129# @query-kvm:
130#
131# Returns information about KVM acceleration
132#
133# Returns: @KvmInfo
134#
135# Since: 0.14.0
136##
137{ 'command': 'query-kvm', 'returns': 'KvmInfo' }
138
Luiz Capitulino1fa9a5e2011-09-12 17:54:20 -0300139##
140# @RunState
141#
Lei Li6932a692012-08-23 13:14:25 +0800142# An enumeration of VM run states.
Luiz Capitulino1fa9a5e2011-09-12 17:54:20 -0300143#
144# @debug: QEMU is running on a debugger
145#
Luiz Capitulino0a24c7b2012-04-27 13:16:41 -0300146# @finish-migrate: guest is paused to finish the migration process
147#
Paolo Bonzini1e998142012-10-23 14:54:21 +0200148# @inmigrate: guest is paused waiting for an incoming migration. Note
149# that this state does not tell whether the machine will start at the
150# end of the migration. This depends on the command-line -S option and
151# any invocation of 'stop' or 'cont' that has happened since QEMU was
152# started.
Luiz Capitulino1fa9a5e2011-09-12 17:54:20 -0300153#
154# @internal-error: An internal error that prevents further guest execution
155# has occurred
156#
157# @io-error: the last IOP has failed and the device is configured to pause
158# on I/O errors
159#
160# @paused: guest has been paused via the 'stop' command
161#
162# @postmigrate: guest is paused following a successful 'migrate'
163#
164# @prelaunch: QEMU was started with -S and guest has not started
165#
Luiz Capitulino1fa9a5e2011-09-12 17:54:20 -0300166# @restore-vm: guest is paused to restore VM state
167#
168# @running: guest is actively running
169#
170# @save-vm: guest is paused to save the VM state
171#
172# @shutdown: guest is shut down (and -no-shutdown is in use)
173#
Luiz Capitulinoad02b962012-04-27 13:33:36 -0300174# @suspended: guest is suspended (ACPI S3)
175#
Luiz Capitulino1fa9a5e2011-09-12 17:54:20 -0300176# @watchdog: the watchdog action is configured to pause and has been triggered
Hu Taoede085b2013-04-26 11:24:40 +0800177#
178# @guest-panicked: guest has been panicked as a result of guest OS panic
Luiz Capitulino1fa9a5e2011-09-12 17:54:20 -0300179##
180{ 'enum': 'RunState',
181 'data': [ 'debug', 'inmigrate', 'internal-error', 'io-error', 'paused',
182 'postmigrate', 'prelaunch', 'finish-migrate', 'restore-vm',
Hu Taoede085b2013-04-26 11:24:40 +0800183 'running', 'save-vm', 'shutdown', 'suspended', 'watchdog',
184 'guest-panicked' ] }
Luiz Capitulino1fa9a5e2011-09-12 17:54:20 -0300185
186##
Benoît Canetc249ee62012-09-05 13:09:01 +0200187# @SnapshotInfo
188#
189# @id: unique snapshot id
190#
191# @name: user chosen name
192#
193# @vm-state-size: size of the VM state
194#
195# @date-sec: UTC date of the snapshot in seconds
196#
197# @date-nsec: fractional part in nano seconds to be used with date-sec
198#
199# @vm-clock-sec: VM clock relative to boot in seconds
200#
201# @vm-clock-nsec: fractional part in nano seconds to be used with vm-clock-sec
202#
203# Since: 1.3
204#
205##
206
207{ 'type': 'SnapshotInfo',
208 'data': { 'id': 'str', 'name': 'str', 'vm-state-size': 'int',
209 'date-sec': 'int', 'date-nsec': 'int',
210 'vm-clock-sec': 'int', 'vm-clock-nsec': 'int' } }
211
212##
213# @ImageInfo:
214#
215# Information about a QEMU image file
216#
217# @filename: name of the image file
218#
219# @format: format of the image file
220#
221# @virtual-size: maximum capacity in bytes of the image
222#
223# @actual-size: #optional actual size on disk in bytes of the image
224#
225# @dirty-flag: #optional true if image is not cleanly closed
226#
227# @cluster-size: #optional size of a cluster in bytes
228#
229# @encrypted: #optional true if the image is encrypted
230#
231# @backing-filename: #optional name of the backing file
232#
233# @full-backing-filename: #optional full path of the backing file
234#
235# @backing-filename-format: #optional the format of the backing file
236#
237# @snapshots: #optional list of VM snapshots
238#
Wenchao Xia553a7e82013-06-06 12:27:59 +0800239# @backing-image: #optional info of the backing image (since 1.6)
240#
Benoît Canetc249ee62012-09-05 13:09:01 +0200241# Since: 1.3
242#
243##
244
245{ 'type': 'ImageInfo',
246 'data': {'filename': 'str', 'format': 'str', '*dirty-flag': 'bool',
247 '*actual-size': 'int', 'virtual-size': 'int',
248 '*cluster-size': 'int', '*encrypted': 'bool',
249 '*backing-filename': 'str', '*full-backing-filename': 'str',
Wenchao Xia553a7e82013-06-06 12:27:59 +0800250 '*backing-filename-format': 'str', '*snapshots': ['SnapshotInfo'],
251 '*backing-image': 'ImageInfo' } }
Benoît Canetc249ee62012-09-05 13:09:01 +0200252
253##
Federico Simoncelli8599ea42013-01-28 06:59:47 -0500254# @ImageCheck:
255#
256# Information about a QEMU image file check
257#
258# @filename: name of the image file checked
259#
260# @format: format of the image file checked
261#
262# @check-errors: number of unexpected errors occurred during check
263#
264# @image-end-offset: #optional offset (in bytes) where the image ends, this
265# field is present if the driver for the image format
266# supports it
267#
268# @corruptions: #optional number of corruptions found during the check if any
269#
270# @leaks: #optional number of leaks found during the check if any
271#
272# @corruptions-fixed: #optional number of corruptions fixed during the check
273# if any
274#
275# @leaks-fixed: #optional number of leaks fixed during the check if any
276#
277# @total-clusters: #optional total number of clusters, this field is present
278# if the driver for the image format supports it
279#
280# @allocated-clusters: #optional total number of allocated clusters, this
281# field is present if the driver for the image format
282# supports it
283#
284# @fragmented-clusters: #optional total number of fragmented clusters, this
285# field is present if the driver for the image format
286# supports it
287#
Stefan Hajnoczie6439d72013-02-07 17:15:04 +0100288# @compressed-clusters: #optional total number of compressed clusters, this
289# field is present if the driver for the image format
290# supports it
291#
Federico Simoncelli8599ea42013-01-28 06:59:47 -0500292# Since: 1.4
293#
294##
295
296{ 'type': 'ImageCheck',
297 'data': {'filename': 'str', 'format': 'str', 'check-errors': 'int',
298 '*image-end-offset': 'int', '*corruptions': 'int', '*leaks': 'int',
299 '*corruptions-fixed': 'int', '*leaks-fixed': 'int',
300 '*total-clusters': 'int', '*allocated-clusters': 'int',
Stefan Hajnoczie6439d72013-02-07 17:15:04 +0100301 '*fragmented-clusters': 'int', '*compressed-clusters': 'int' } }
Federico Simoncelli8599ea42013-01-28 06:59:47 -0500302
303##
Luiz Capitulino1fa9a5e2011-09-12 17:54:20 -0300304# @StatusInfo:
305#
306# Information about VCPU run state
307#
308# @running: true if all VCPUs are runnable, false if not runnable
309#
310# @singlestep: true if VCPUs are in single-step mode
311#
312# @status: the virtual machine @RunState
313#
314# Since: 0.14.0
315#
316# Notes: @singlestep is enabled through the GDB stub
317##
318{ 'type': 'StatusInfo',
319 'data': {'running': 'bool', 'singlestep': 'bool', 'status': 'RunState'} }
320
321##
322# @query-status:
323#
324# Query the run status of all VCPUs
325#
326# Returns: @StatusInfo reflecting all VCPUs
327#
328# Since: 0.14.0
329##
330{ 'command': 'query-status', 'returns': 'StatusInfo' }
331
Luiz Capitulinoefab7672011-09-13 17:16:25 -0300332##
333# @UuidInfo:
334#
335# Guest UUID information.
336#
337# @UUID: the UUID of the guest
338#
339# Since: 0.14.0
340#
341# Notes: If no UUID was specified for the guest, a null UUID is returned.
342##
343{ 'type': 'UuidInfo', 'data': {'UUID': 'str'} }
344
345##
346# @query-uuid:
347#
348# Query the guest UUID information.
349#
350# Returns: The @UuidInfo for the guest
351#
352# Since 0.14.0
353##
354{ 'command': 'query-uuid', 'returns': 'UuidInfo' }
355
Luiz Capitulinoc5a415a2011-09-14 16:05:49 -0300356##
357# @ChardevInfo:
358#
359# Information about a character device.
360#
361# @label: the label of the character device
362#
363# @filename: the filename of the character device
364#
365# Notes: @filename is encoded using the QEMU command line character device
366# encoding. See the QEMU man page for details.
367#
368# Since: 0.14.0
369##
370{ 'type': 'ChardevInfo', 'data': {'label': 'str', 'filename': 'str'} }
371
372##
373# @query-chardev:
374#
375# Returns information about current character devices.
376#
377# Returns: a list of @ChardevInfo
378#
379# Since: 0.14.0
380##
381{ 'command': 'query-chardev', 'returns': ['ChardevInfo'] }
Luiz Capitulinoaa9b79b2011-09-21 14:31:51 -0300382
383##
Lei Li1f590cf2013-01-25 00:03:20 +0800384# @DataFormat:
385#
386# An enumeration of data format.
387#
Markus Armbruster3949e592013-02-06 21:27:24 +0100388# @utf8: Data is a UTF-8 string (RFC 3629)
Lei Li1f590cf2013-01-25 00:03:20 +0800389#
Markus Armbruster3949e592013-02-06 21:27:24 +0100390# @base64: Data is Base64 encoded binary (RFC 3548)
Lei Li1f590cf2013-01-25 00:03:20 +0800391#
392# Since: 1.4
393##
Amos Kongad0f1712013-06-19 17:23:27 +0800394{ 'enum': 'DataFormat',
Lei Li1f590cf2013-01-25 00:03:20 +0800395 'data': [ 'utf8', 'base64' ] }
396
397##
Markus Armbruster3949e592013-02-06 21:27:24 +0100398# @ringbuf-write:
Lei Li1f590cf2013-01-25 00:03:20 +0800399#
Markus Armbruster3949e592013-02-06 21:27:24 +0100400# Write to a ring buffer character device.
Lei Li1f590cf2013-01-25 00:03:20 +0800401#
Markus Armbruster3949e592013-02-06 21:27:24 +0100402# @device: the ring buffer character device name
Lei Li1f590cf2013-01-25 00:03:20 +0800403#
Markus Armbruster3949e592013-02-06 21:27:24 +0100404# @data: data to write
Lei Li1f590cf2013-01-25 00:03:20 +0800405#
Markus Armbruster3949e592013-02-06 21:27:24 +0100406# @format: #optional data encoding (default 'utf8').
407# - base64: data must be base64 encoded text. Its binary
408# decoding gets written.
409# Bug: invalid base64 is currently not rejected.
410# Whitespace *is* invalid.
411# - utf8: data's UTF-8 encoding is written
412# - data itself is always Unicode regardless of format, like
413# any other string.
Lei Li1f590cf2013-01-25 00:03:20 +0800414#
415# Returns: Nothing on success
Lei Li1f590cf2013-01-25 00:03:20 +0800416#
417# Since: 1.4
418##
Markus Armbruster3949e592013-02-06 21:27:24 +0100419{ 'command': 'ringbuf-write',
Markus Armbruster82e59a62013-02-06 21:27:14 +0100420 'data': {'device': 'str', 'data': 'str',
Lei Li1f590cf2013-01-25 00:03:20 +0800421 '*format': 'DataFormat'} }
422
423##
Markus Armbruster3949e592013-02-06 21:27:24 +0100424# @ringbuf-read:
Lei Li49b6d722013-01-25 00:03:21 +0800425#
Markus Armbruster3949e592013-02-06 21:27:24 +0100426# Read from a ring buffer character device.
Lei Li49b6d722013-01-25 00:03:21 +0800427#
Markus Armbruster3949e592013-02-06 21:27:24 +0100428# @device: the ring buffer character device name
Lei Li49b6d722013-01-25 00:03:21 +0800429#
Markus Armbruster3949e592013-02-06 21:27:24 +0100430# @size: how many bytes to read at most
Lei Li49b6d722013-01-25 00:03:21 +0800431#
Markus Armbruster3949e592013-02-06 21:27:24 +0100432# @format: #optional data encoding (default 'utf8').
433# - base64: the data read is returned in base64 encoding.
434# - utf8: the data read is interpreted as UTF-8.
435# Bug: can screw up when the buffer contains invalid UTF-8
436# sequences, NUL characters, after the ring buffer lost
437# data, and when reading stops because the size limit is
438# reached.
439# - The return value is always Unicode regardless of format,
440# like any other string.
Lei Li49b6d722013-01-25 00:03:21 +0800441#
Markus Armbruster3ab651f2013-02-06 21:27:15 +0100442# Returns: data read from the device
Lei Li49b6d722013-01-25 00:03:21 +0800443#
444# Since: 1.4
445##
Markus Armbruster3949e592013-02-06 21:27:24 +0100446{ 'command': 'ringbuf-read',
Lei Li49b6d722013-01-25 00:03:21 +0800447 'data': {'device': 'str', 'size': 'int', '*format': 'DataFormat'},
Markus Armbruster3ab651f2013-02-06 21:27:15 +0100448 'returns': 'str' }
Lei Li49b6d722013-01-25 00:03:21 +0800449
450##
Luiz Capitulinoaa9b79b2011-09-21 14:31:51 -0300451# @CommandInfo:
452#
453# Information about a QMP command
454#
455# @name: The command name
456#
457# Since: 0.14.0
458##
459{ 'type': 'CommandInfo', 'data': {'name': 'str'} }
460
461##
462# @query-commands:
463#
464# Return a list of supported QMP commands by this server
465#
466# Returns: A list of @CommandInfo for all supported commands
467#
468# Since: 0.14.0
469##
470{ 'command': 'query-commands', 'returns': ['CommandInfo'] }
471
Luiz Capitulino7a7f3252011-09-15 14:20:28 -0300472##
Daniel P. Berrange48608532012-05-21 17:59:51 +0100473# @EventInfo:
474#
475# Information about a QMP event
476#
477# @name: The event name
478#
479# Since: 1.2.0
480##
481{ 'type': 'EventInfo', 'data': {'name': 'str'} }
482
483##
484# @query-events:
485#
486# Return a list of supported QMP events by this server
487#
488# Returns: A list of @EventInfo for all supported events
489#
490# Since: 1.2.0
491##
492{ 'command': 'query-events', 'returns': ['EventInfo'] }
493
494##
Luiz Capitulino791e7c82011-09-13 17:37:16 -0300495# @MigrationStats
496#
497# Detailed migration status.
498#
499# @transferred: amount of bytes already transferred to the target VM
500#
501# @remaining: amount of bytes remaining to be transferred to the target VM
502#
503# @total: total amount of bytes involved in the migration process
504#
Peter Lievenf1c72792013-03-26 10:58:37 +0100505# @duplicate: number of duplicate (zero) pages (since 1.2)
506#
507# @skipped: number of skipped zero pages (since 1.5)
Orit Wasserman004d4c12012-08-06 21:42:56 +0300508#
509# @normal : number of normal pages (since 1.2)
510#
Juan Quintela8d017192012-08-13 12:31:25 +0200511# @normal-bytes: number of normal bytes sent (since 1.2)
512#
513# @dirty-pages-rate: number of pages dirtied by second by the
514# guest (since 1.3)
Orit Wasserman004d4c12012-08-06 21:42:56 +0300515#
Michael R. Hines7e114f82013-06-25 21:35:30 -0400516# @mbps: throughput in megabits/sec. (since 1.6)
517#
Orit Wasserman004d4c12012-08-06 21:42:56 +0300518# Since: 0.14.0
Luiz Capitulino791e7c82011-09-13 17:37:16 -0300519##
520{ 'type': 'MigrationStats',
Juan Quintelad5f8a572012-05-21 22:01:07 +0200521 'data': {'transferred': 'int', 'remaining': 'int', 'total': 'int' ,
Peter Lievenf1c72792013-03-26 10:58:37 +0100522 'duplicate': 'int', 'skipped': 'int', 'normal': 'int',
Michael R. Hines7e114f82013-06-25 21:35:30 -0400523 'normal-bytes': 'int', 'dirty-pages-rate' : 'int',
524 'mbps' : 'number' } }
Luiz Capitulino791e7c82011-09-13 17:37:16 -0300525
526##
Orit Wassermanf36d55a2012-08-06 21:42:57 +0300527# @XBZRLECacheStats
528#
529# Detailed XBZRLE migration cache statistics
530#
531# @cache-size: XBZRLE cache size
532#
533# @bytes: amount of bytes already transferred to the target VM
534#
535# @pages: amount of pages transferred to the target VM
536#
537# @cache-miss: number of cache miss
538#
539# @overflow: number of overflows
540#
541# Since: 1.2
542##
543{ 'type': 'XBZRLECacheStats',
544 'data': {'cache-size': 'int', 'bytes': 'int', 'pages': 'int',
545 'cache-miss': 'int', 'overflow': 'int' } }
546
547##
Luiz Capitulino791e7c82011-09-13 17:37:16 -0300548# @MigrationInfo
549#
550# Information about current migration process.
551#
552# @status: #optional string describing the current migration status.
553# As of 0.14.0 this can be 'active', 'completed', 'failed' or
554# 'cancelled'. If this field is not returned, no migration process
555# has been initiated
556#
Juan Quintelad5f8a572012-05-21 22:01:07 +0200557# @ram: #optional @MigrationStats containing detailed migration
558# status, only returned if status is 'active' or
559# 'completed'. 'comppleted' (since 1.2)
Luiz Capitulino791e7c82011-09-13 17:37:16 -0300560#
561# @disk: #optional @MigrationStats containing detailed disk migration
562# status, only returned if status is 'active' and it is a block
563# migration
564#
Orit Wassermanf36d55a2012-08-06 21:42:57 +0300565# @xbzrle-cache: #optional @XBZRLECacheStats containing detailed XBZRLE
566# migration statistics, only returned if XBZRLE feature is on and
567# status is 'active' or 'completed' (since 1.2)
568#
Juan Quintela7aa939a2012-08-18 13:17:10 +0200569# @total-time: #optional total amount of milliseconds since migration started.
570# If migration has ended, it returns the total migration
571# time. (since 1.2)
572#
Juan Quintela9c5a9fc2012-08-13 09:35:16 +0200573# @downtime: #optional only present when migration finishes correctly
574# total downtime in milliseconds for the guest.
575# (since 1.3)
576#
Juan Quintela2c52ddf2012-08-13 09:53:12 +0200577# @expected-downtime: #optional only present while migration is active
578# expected downtime in milliseconds for the guest in last walk
579# of the dirty bitmap. (since 1.3)
580#
Luiz Capitulino791e7c82011-09-13 17:37:16 -0300581# Since: 0.14.0
582##
583{ 'type': 'MigrationInfo',
584 'data': {'*status': 'str', '*ram': 'MigrationStats',
Orit Wassermanf36d55a2012-08-06 21:42:57 +0300585 '*disk': 'MigrationStats',
Juan Quintela7aa939a2012-08-18 13:17:10 +0200586 '*xbzrle-cache': 'XBZRLECacheStats',
Juan Quintela9c5a9fc2012-08-13 09:35:16 +0200587 '*total-time': 'int',
Juan Quintela2c52ddf2012-08-13 09:53:12 +0200588 '*expected-downtime': 'int',
Juan Quintela9c5a9fc2012-08-13 09:35:16 +0200589 '*downtime': 'int'} }
Luiz Capitulino791e7c82011-09-13 17:37:16 -0300590
591##
592# @query-migrate
593#
594# Returns information about current migration process.
595#
596# Returns: @MigrationInfo
597#
598# Since: 0.14.0
599##
600{ 'command': 'query-migrate', 'returns': 'MigrationInfo' }
601
602##
Orit Wassermanbbf6da32012-08-06 21:42:47 +0300603# @MigrationCapability
604#
605# Migration capabilities enumeration
606#
607# @xbzrle: Migration supports xbzrle (Xor Based Zero Run Length Encoding).
608# This feature allows us to minimize migration traffic for certain work
609# loads, by sending compressed difference of the pages
610#
Michael R. Hines60d92222013-06-25 21:35:36 -0400611# @x-rdma-pin-all: Controls whether or not the entire VM memory footprint is
612# mlock()'d on demand or all at once. Refer to docs/rdma.txt for usage.
613# Disabled by default. Experimental: may (or may not) be renamed after
614# further testing is complete. (since 1.6)
615#
Orit Wassermanbbf6da32012-08-06 21:42:47 +0300616# Since: 1.2
617##
618{ 'enum': 'MigrationCapability',
Michael R. Hines60d92222013-06-25 21:35:36 -0400619 'data': ['xbzrle', 'x-rdma-pin-all'] }
Orit Wassermanbbf6da32012-08-06 21:42:47 +0300620
621##
622# @MigrationCapabilityStatus
623#
624# Migration capability information
625#
626# @capability: capability enum
627#
628# @state: capability state bool
629#
630# Since: 1.2
631##
632{ 'type': 'MigrationCapabilityStatus',
633 'data': { 'capability' : 'MigrationCapability', 'state' : 'bool' } }
634
635##
Orit Wasserman00458432012-08-06 21:42:48 +0300636# @migrate-set-capabilities
637#
638# Enable/Disable the following migration capabilities (like xbzrle)
639#
640# @capabilities: json array of capability modifications to make
641#
642# Since: 1.2
643##
644{ 'command': 'migrate-set-capabilities',
645 'data': { 'capabilities': ['MigrationCapabilityStatus'] } }
646
647##
Orit Wassermanbbf6da32012-08-06 21:42:47 +0300648# @query-migrate-capabilities
649#
650# Returns information about the current migration capabilities status
651#
652# Returns: @MigrationCapabilitiesStatus
653#
654# Since: 1.2
655##
656{ 'command': 'query-migrate-capabilities', 'returns': ['MigrationCapabilityStatus']}
657
658##
Luiz Capitulinoe235cec2011-09-21 15:29:55 -0300659# @MouseInfo:
660#
661# Information about a mouse device.
662#
663# @name: the name of the mouse device
664#
665# @index: the index of the mouse device
666#
667# @current: true if this device is currently receiving mouse events
668#
669# @absolute: true if this device supports absolute coordinates as input
670#
671# Since: 0.14.0
672##
673{ 'type': 'MouseInfo',
674 'data': {'name': 'str', 'index': 'int', 'current': 'bool',
675 'absolute': 'bool'} }
676
677##
678# @query-mice:
679#
680# Returns information about each active mouse device
681#
682# Returns: a list of @MouseInfo for each device
683#
684# Since: 0.14.0
685##
686{ 'command': 'query-mice', 'returns': ['MouseInfo'] }
687
688##
Luiz Capitulinode0b36b2011-09-21 16:38:35 -0300689# @CpuInfo:
690#
691# Information about a virtual CPU
692#
693# @CPU: the index of the virtual CPU
694#
695# @current: this only exists for backwards compatible and should be ignored
Laszlo Ersekb80e5602012-07-17 16:17:10 +0200696#
Luiz Capitulinode0b36b2011-09-21 16:38:35 -0300697# @halted: true if the virtual CPU is in the halt state. Halt usually refers
698# to a processor specific low power mode.
699#
700# @pc: #optional If the target is i386 or x86_64, this is the 64-bit instruction
701# pointer.
702# If the target is Sparc, this is the PC component of the
703# instruction pointer.
704#
705# @nip: #optional If the target is PPC, the instruction pointer
706#
707# @npc: #optional If the target is Sparc, the NPC component of the instruction
708# pointer
709#
710# @PC: #optional If the target is MIPS, the instruction pointer
711#
712# @thread_id: ID of the underlying host thread
713#
714# Since: 0.14.0
715#
716# Notes: @halted is a transient state that changes frequently. By the time the
717# data is sent to the client, the guest may no longer be halted.
718##
719{ 'type': 'CpuInfo',
720 'data': {'CPU': 'int', 'current': 'bool', 'halted': 'bool', '*pc': 'int',
721 '*nip': 'int', '*npc': 'int', '*PC': 'int', 'thread_id': 'int'} }
722
723##
724# @query-cpus:
725#
726# Returns a list of information about each virtual CPU.
727#
728# Returns: a list of @CpuInfo for each virtual CPU
729#
730# Since: 0.14.0
731##
732{ 'command': 'query-cpus', 'returns': ['CpuInfo'] }
733
734##
Luiz Capitulinob2023812011-09-21 17:16:47 -0300735# @BlockDeviceInfo:
736#
737# Information about the backing device for a block device.
738#
739# @file: the filename of the backing device
740#
741# @ro: true if the backing device was open read-only
742#
743# @drv: the name of the block format used to open the backing device. As of
744# 0.14.0 this can be: 'blkdebug', 'bochs', 'cloop', 'cow', 'dmg',
745# 'file', 'file', 'ftp', 'ftps', 'host_cdrom', 'host_device',
746# 'host_floppy', 'http', 'https', 'nbd', 'parallels', 'qcow',
747# 'qcow2', 'raw', 'tftp', 'vdi', 'vmdk', 'vpc', 'vvfat'
748#
749# @backing_file: #optional the name of the backing file (for copy-on-write)
750#
Benoît Canet2e3e3312012-08-02 10:22:48 +0200751# @backing_file_depth: number of files in the backing file chain (since: 1.2)
752#
Luiz Capitulinob2023812011-09-21 17:16:47 -0300753# @encrypted: true if the backing device is encrypted
754#
Luiz Capitulinoc75a1a82012-07-26 20:28:44 -0300755# @encryption_key_missing: true if the backing device is encrypted but an
756# valid encryption key is missing
757#
Zhi Yong Wu727f0052011-11-08 13:00:31 +0800758# @bps: total throughput limit in bytes per second is specified
759#
760# @bps_rd: read throughput limit in bytes per second is specified
761#
762# @bps_wr: write throughput limit in bytes per second is specified
763#
764# @iops: total I/O operations per second is specified
765#
766# @iops_rd: read I/O operations per second is specified
767#
768# @iops_wr: write I/O operations per second is specified
769#
Wenchao Xia553a7e82013-06-06 12:27:59 +0800770# @image: the info of image used (since: 1.6)
771#
Luiz Capitulinob2023812011-09-21 17:16:47 -0300772# Since: 0.14.0
773#
774# Notes: This interface is only found in @BlockInfo.
775##
776{ 'type': 'BlockDeviceInfo',
777 'data': { 'file': 'str', 'ro': 'bool', 'drv': 'str',
Benoît Canet2e3e3312012-08-02 10:22:48 +0200778 '*backing_file': 'str', 'backing_file_depth': 'int',
Luiz Capitulinoc75a1a82012-07-26 20:28:44 -0300779 'encrypted': 'bool', 'encryption_key_missing': 'bool',
780 'bps': 'int', 'bps_rd': 'int', 'bps_wr': 'int',
Wenchao Xia553a7e82013-06-06 12:27:59 +0800781 'iops': 'int', 'iops_rd': 'int', 'iops_wr': 'int',
782 'image': 'ImageInfo' } }
Luiz Capitulinob2023812011-09-21 17:16:47 -0300783
784##
785# @BlockDeviceIoStatus:
786#
787# An enumeration of block device I/O status.
788#
789# @ok: The last I/O operation has succeeded
790#
791# @failed: The last I/O operation has failed
792#
793# @nospace: The last I/O operation has failed due to a no-space condition
794#
795# Since: 1.0
796##
797{ 'enum': 'BlockDeviceIoStatus', 'data': [ 'ok', 'failed', 'nospace' ] }
798
799##
Paolo Bonzinib9a9b3a2012-08-01 15:23:44 +0200800# @BlockDirtyInfo:
801#
802# Block dirty bitmap information.
803#
804# @count: number of dirty bytes according to the dirty bitmap
805#
Paolo Bonzini50717e92013-01-21 17:09:45 +0100806# @granularity: granularity of the dirty bitmap in bytes (since 1.4)
807#
Paolo Bonzinib9a9b3a2012-08-01 15:23:44 +0200808# Since: 1.3
809##
810{ 'type': 'BlockDirtyInfo',
Paolo Bonzini50717e92013-01-21 17:09:45 +0100811 'data': {'count': 'int', 'granularity': 'int'} }
Paolo Bonzinib9a9b3a2012-08-01 15:23:44 +0200812
813##
Luiz Capitulinob2023812011-09-21 17:16:47 -0300814# @BlockInfo:
815#
816# Block device information. This structure describes a virtual device and
817# the backing device associated with it.
818#
819# @device: The device name associated with the virtual device.
820#
821# @type: This field is returned only for compatibility reasons, it should
822# not be used (always returns 'unknown')
823#
824# @removable: True if the device supports removable media.
825#
826# @locked: True if the guest has locked this device from having its media
827# removed
828#
829# @tray_open: #optional True if the device has a tray and it is open
830# (only present if removable is true)
831#
Paolo Bonzinib9a9b3a2012-08-01 15:23:44 +0200832# @dirty: #optional dirty bitmap information (only present if the dirty
833# bitmap is enabled)
834#
Luiz Capitulinob2023812011-09-21 17:16:47 -0300835# @io-status: #optional @BlockDeviceIoStatus. Only present if the device
836# supports it and the VM is configured to stop on errors
837#
838# @inserted: #optional @BlockDeviceInfo describing the device if media is
839# present
840#
841# Since: 0.14.0
842##
843{ 'type': 'BlockInfo',
844 'data': {'device': 'str', 'type': 'str', 'removable': 'bool',
845 'locked': 'bool', '*inserted': 'BlockDeviceInfo',
Paolo Bonzinib9a9b3a2012-08-01 15:23:44 +0200846 '*tray_open': 'bool', '*io-status': 'BlockDeviceIoStatus',
847 '*dirty': 'BlockDirtyInfo' } }
Luiz Capitulinob2023812011-09-21 17:16:47 -0300848
849##
850# @query-block:
851#
852# Get a list of BlockInfo for all virtual block devices.
853#
854# Returns: a list of @BlockInfo describing each virtual block device
855#
856# Since: 0.14.0
857##
858{ 'command': 'query-block', 'returns': ['BlockInfo'] }
859
860##
Luiz Capitulinof11f57e2011-09-22 15:56:36 -0300861# @BlockDeviceStats:
862#
863# Statistics of a virtual block device or a block backing device.
864#
865# @rd_bytes: The number of bytes read by the device.
866#
867# @wr_bytes: The number of bytes written by the device.
868#
869# @rd_operations: The number of read operations performed by the device.
870#
871# @wr_operations: The number of write operations performed by the device.
872#
873# @flush_operations: The number of cache flush operations performed by the
874# device (since 0.15.0)
875#
876# @flush_total_time_ns: Total time spend on cache flushes in nano-seconds
877# (since 0.15.0).
878#
879# @wr_total_time_ns: Total time spend on writes in nano-seconds (since 0.15.0).
880#
881# @rd_total_time_ns: Total_time_spend on reads in nano-seconds (since 0.15.0).
882#
883# @wr_highest_offset: The offset after the greatest byte written to the
884# device. The intended use of this information is for
885# growable sparse files (like qcow2) that are used on top
886# of a physical device.
887#
888# Since: 0.14.0
889##
890{ 'type': 'BlockDeviceStats',
891 'data': {'rd_bytes': 'int', 'wr_bytes': 'int', 'rd_operations': 'int',
892 'wr_operations': 'int', 'flush_operations': 'int',
893 'flush_total_time_ns': 'int', 'wr_total_time_ns': 'int',
894 'rd_total_time_ns': 'int', 'wr_highest_offset': 'int' } }
895
896##
897# @BlockStats:
898#
899# Statistics of a virtual block device or a block backing device.
900#
901# @device: #optional If the stats are for a virtual block device, the name
902# corresponding to the virtual block device.
903#
904# @stats: A @BlockDeviceStats for the device.
905#
906# @parent: #optional This may point to the backing block device if this is a
907# a virtual block device. If it's a backing block, this will point
908# to the backing file is one is present.
909#
910# Since: 0.14.0
911##
912{ 'type': 'BlockStats',
913 'data': {'*device': 'str', 'stats': 'BlockDeviceStats',
914 '*parent': 'BlockStats'} }
915
916##
917# @query-blockstats:
918#
919# Query the @BlockStats for all virtual block devices.
920#
921# Returns: A list of @BlockStats for each virtual block devices.
922#
923# Since: 0.14.0
924##
925{ 'command': 'query-blockstats', 'returns': ['BlockStats'] }
926
927##
Luiz Capitulino2b54aa82011-10-17 16:41:22 -0200928# @VncClientInfo:
929#
930# Information about a connected VNC client.
931#
932# @host: The host name of the client. QEMU tries to resolve this to a DNS name
933# when possible.
934#
935# @family: 'ipv6' if the client is connected via IPv6 and TCP
936# 'ipv4' if the client is connected via IPv4 and TCP
937# 'unix' if the client is connected via a unix domain socket
938# 'unknown' otherwise
939#
940# @service: The service name of the client's port. This may depends on the
941# host system's service database so symbolic names should not be
942# relied on.
943#
944# @x509_dname: #optional If x509 authentication is in use, the Distinguished
945# Name of the client.
946#
947# @sasl_username: #optional If SASL authentication is in use, the SASL username
948# used for authentication.
949#
950# Since: 0.14.0
951##
952{ 'type': 'VncClientInfo',
953 'data': {'host': 'str', 'family': 'str', 'service': 'str',
954 '*x509_dname': 'str', '*sasl_username': 'str'} }
955
956##
957# @VncInfo:
958#
959# Information about the VNC session.
960#
961# @enabled: true if the VNC server is enabled, false otherwise
962#
963# @host: #optional The hostname the VNC server is bound to. This depends on
964# the name resolution on the host and may be an IP address.
965#
966# @family: #optional 'ipv6' if the host is listening for IPv6 connections
967# 'ipv4' if the host is listening for IPv4 connections
968# 'unix' if the host is listening on a unix domain socket
969# 'unknown' otherwise
970#
971# @service: #optional The service name of the server's port. This may depends
972# on the host system's service database so symbolic names should not
973# be relied on.
974#
975# @auth: #optional the current authentication type used by the server
976# 'none' if no authentication is being used
977# 'vnc' if VNC authentication is being used
978# 'vencrypt+plain' if VEncrypt is used with plain text authentication
979# 'vencrypt+tls+none' if VEncrypt is used with TLS and no authentication
980# 'vencrypt+tls+vnc' if VEncrypt is used with TLS and VNC authentication
981# 'vencrypt+tls+plain' if VEncrypt is used with TLS and plain text auth
982# 'vencrypt+x509+none' if VEncrypt is used with x509 and no auth
983# 'vencrypt+x509+vnc' if VEncrypt is used with x509 and VNC auth
984# 'vencrypt+x509+plain' if VEncrypt is used with x509 and plain text auth
985# 'vencrypt+tls+sasl' if VEncrypt is used with TLS and SASL auth
986# 'vencrypt+x509+sasl' if VEncrypt is used with x509 and SASL auth
987#
988# @clients: a list of @VncClientInfo of all currently connected clients
989#
990# Since: 0.14.0
991##
992{ 'type': 'VncInfo',
993 'data': {'enabled': 'bool', '*host': 'str', '*family': 'str',
994 '*service': 'str', '*auth': 'str', '*clients': ['VncClientInfo']} }
995
996##
997# @query-vnc:
998#
999# Returns information about the current VNC server
1000#
1001# Returns: @VncInfo
Luiz Capitulino2b54aa82011-10-17 16:41:22 -02001002#
1003# Since: 0.14.0
1004##
1005{ 'command': 'query-vnc', 'returns': 'VncInfo' }
1006
1007##
Luiz Capitulinod1f29642011-10-20 17:01:33 -02001008# @SpiceChannel
1009#
1010# Information about a SPICE client channel.
1011#
1012# @host: The host name of the client. QEMU tries to resolve this to a DNS name
1013# when possible.
1014#
1015# @family: 'ipv6' if the client is connected via IPv6 and TCP
1016# 'ipv4' if the client is connected via IPv4 and TCP
1017# 'unix' if the client is connected via a unix domain socket
1018# 'unknown' otherwise
1019#
1020# @port: The client's port number.
1021#
1022# @connection-id: SPICE connection id number. All channels with the same id
1023# belong to the same SPICE session.
1024#
Alon Levy419e1bd2012-03-05 15:13:27 +02001025# @connection-type: SPICE channel type number. "1" is the main control
1026# channel, filter for this one if you want to track spice
1027# sessions only
Luiz Capitulinod1f29642011-10-20 17:01:33 -02001028#
Alon Levy419e1bd2012-03-05 15:13:27 +02001029# @channel-id: SPICE channel ID number. Usually "0", might be different when
1030# multiple channels of the same type exist, such as multiple
Luiz Capitulinod1f29642011-10-20 17:01:33 -02001031# display channels in a multihead setup
1032#
1033# @tls: true if the channel is encrypted, false otherwise.
1034#
1035# Since: 0.14.0
1036##
1037{ 'type': 'SpiceChannel',
1038 'data': {'host': 'str', 'family': 'str', 'port': 'str',
1039 'connection-id': 'int', 'channel-type': 'int', 'channel-id': 'int',
1040 'tls': 'bool'} }
1041
1042##
Alon Levy4efee022012-03-29 23:23:14 +02001043# @SpiceQueryMouseMode
1044#
Lei Li6932a692012-08-23 13:14:25 +08001045# An enumeration of Spice mouse states.
Alon Levy4efee022012-03-29 23:23:14 +02001046#
1047# @client: Mouse cursor position is determined by the client.
1048#
1049# @server: Mouse cursor position is determined by the server.
1050#
1051# @unknown: No information is available about mouse mode used by
1052# the spice server.
1053#
1054# Note: spice/enums.h has a SpiceMouseMode already, hence the name.
1055#
1056# Since: 1.1
1057##
1058{ 'enum': 'SpiceQueryMouseMode',
1059 'data': [ 'client', 'server', 'unknown' ] }
1060
1061##
Luiz Capitulinod1f29642011-10-20 17:01:33 -02001062# @SpiceInfo
1063#
1064# Information about the SPICE session.
Laszlo Ersekb80e5602012-07-17 16:17:10 +02001065#
Luiz Capitulinod1f29642011-10-20 17:01:33 -02001066# @enabled: true if the SPICE server is enabled, false otherwise
1067#
Yonit Halperin61c4efe2012-08-21 11:51:58 +03001068# @migrated: true if the last guest migration completed and spice
1069# migration had completed as well. false otherwise.
1070#
Luiz Capitulinod1f29642011-10-20 17:01:33 -02001071# @host: #optional The hostname the SPICE server is bound to. This depends on
1072# the name resolution on the host and may be an IP address.
1073#
1074# @port: #optional The SPICE server's port number.
1075#
1076# @compiled-version: #optional SPICE server version.
1077#
1078# @tls-port: #optional The SPICE server's TLS port number.
1079#
1080# @auth: #optional the current authentication type used by the server
Alon Levy419e1bd2012-03-05 15:13:27 +02001081# 'none' if no authentication is being used
1082# 'spice' uses SASL or direct TLS authentication, depending on command
1083# line options
Luiz Capitulinod1f29642011-10-20 17:01:33 -02001084#
Alon Levy4efee022012-03-29 23:23:14 +02001085# @mouse-mode: The mode in which the mouse cursor is displayed currently. Can
1086# be determined by the client or the server, or unknown if spice
1087# server doesn't provide this information.
1088#
1089# Since: 1.1
1090#
Luiz Capitulinod1f29642011-10-20 17:01:33 -02001091# @channels: a list of @SpiceChannel for each active spice channel
1092#
1093# Since: 0.14.0
1094##
1095{ 'type': 'SpiceInfo',
Yonit Halperin61c4efe2012-08-21 11:51:58 +03001096 'data': {'enabled': 'bool', 'migrated': 'bool', '*host': 'str', '*port': 'int',
Luiz Capitulinod1f29642011-10-20 17:01:33 -02001097 '*tls-port': 'int', '*auth': 'str', '*compiled-version': 'str',
Alon Levy4efee022012-03-29 23:23:14 +02001098 'mouse-mode': 'SpiceQueryMouseMode', '*channels': ['SpiceChannel']} }
Luiz Capitulinod1f29642011-10-20 17:01:33 -02001099
1100##
1101# @query-spice
1102#
1103# Returns information about the current SPICE server
1104#
1105# Returns: @SpiceInfo
1106#
1107# Since: 0.14.0
1108##
1109{ 'command': 'query-spice', 'returns': 'SpiceInfo' }
1110
1111##
Luiz Capitulino96637bc2011-10-21 11:41:37 -02001112# @BalloonInfo:
1113#
1114# Information about the guest balloon device.
1115#
1116# @actual: the number of bytes the balloon currently contains
1117#
Luiz Capitulino96637bc2011-10-21 11:41:37 -02001118# Since: 0.14.0
1119#
Luiz Capitulino96637bc2011-10-21 11:41:37 -02001120##
Luiz Capitulino01ceb972012-12-03 15:56:41 -02001121{ 'type': 'BalloonInfo', 'data': {'actual': 'int' } }
Luiz Capitulino96637bc2011-10-21 11:41:37 -02001122
1123##
1124# @query-balloon:
1125#
1126# Return information about the balloon device.
1127#
1128# Returns: @BalloonInfo on success
1129# If the balloon driver is enabled but not functional because the KVM
1130# kernel module cannot support it, KvmMissingCap
1131# If no balloon device is present, DeviceNotActive
1132#
1133# Since: 0.14.0
1134##
1135{ 'command': 'query-balloon', 'returns': 'BalloonInfo' }
1136
1137##
Luiz Capitulino79627472011-10-21 14:15:33 -02001138# @PciMemoryRange:
1139#
1140# A PCI device memory region
1141#
1142# @base: the starting address (guest physical)
1143#
1144# @limit: the ending address (guest physical)
1145#
1146# Since: 0.14.0
1147##
1148{ 'type': 'PciMemoryRange', 'data': {'base': 'int', 'limit': 'int'} }
1149
1150##
1151# @PciMemoryRegion
1152#
1153# Information about a PCI device I/O region.
1154#
1155# @bar: the index of the Base Address Register for this region
1156#
1157# @type: 'io' if the region is a PIO region
1158# 'memory' if the region is a MMIO region
1159#
1160# @prefetch: #optional if @type is 'memory', true if the memory is prefetchable
1161#
1162# @mem_type_64: #optional if @type is 'memory', true if the BAR is 64-bit
1163#
1164# Since: 0.14.0
1165##
1166{ 'type': 'PciMemoryRegion',
1167 'data': {'bar': 'int', 'type': 'str', 'address': 'int', 'size': 'int',
1168 '*prefetch': 'bool', '*mem_type_64': 'bool' } }
1169
1170##
1171# @PciBridgeInfo:
1172#
1173# Information about a PCI Bridge device
1174#
1175# @bus.number: primary bus interface number. This should be the number of the
1176# bus the device resides on.
1177#
1178# @bus.secondary: secondary bus interface number. This is the number of the
1179# main bus for the bridge
1180#
1181# @bus.subordinate: This is the highest number bus that resides below the
1182# bridge.
1183#
1184# @bus.io_range: The PIO range for all devices on this bridge
1185#
1186# @bus.memory_range: The MMIO range for all devices on this bridge
1187#
1188# @bus.prefetchable_range: The range of prefetchable MMIO for all devices on
1189# this bridge
1190#
1191# @devices: a list of @PciDeviceInfo for each device on this bridge
1192#
1193# Since: 0.14.0
1194##
1195{ 'type': 'PciBridgeInfo',
1196 'data': {'bus': { 'number': 'int', 'secondary': 'int', 'subordinate': 'int',
1197 'io_range': 'PciMemoryRange',
1198 'memory_range': 'PciMemoryRange',
1199 'prefetchable_range': 'PciMemoryRange' },
1200 '*devices': ['PciDeviceInfo']} }
1201
1202##
1203# @PciDeviceInfo:
1204#
1205# Information about a PCI device
1206#
1207# @bus: the bus number of the device
1208#
1209# @slot: the slot the device is located in
1210#
1211# @function: the function of the slot used by the device
1212#
1213# @class_info.desc: #optional a string description of the device's class
1214#
1215# @class_info.class: the class code of the device
1216#
1217# @id.device: the PCI device id
1218#
1219# @id.vendor: the PCI vendor id
1220#
1221# @irq: #optional if an IRQ is assigned to the device, the IRQ number
1222#
1223# @qdev_id: the device name of the PCI device
1224#
1225# @pci_bridge: if the device is a PCI bridge, the bridge information
1226#
1227# @regions: a list of the PCI I/O regions associated with the device
1228#
1229# Notes: the contents of @class_info.desc are not stable and should only be
1230# treated as informational.
1231#
1232# Since: 0.14.0
1233##
1234{ 'type': 'PciDeviceInfo',
1235 'data': {'bus': 'int', 'slot': 'int', 'function': 'int',
1236 'class_info': {'*desc': 'str', 'class': 'int'},
1237 'id': {'device': 'int', 'vendor': 'int'},
1238 '*irq': 'int', 'qdev_id': 'str', '*pci_bridge': 'PciBridgeInfo',
1239 'regions': ['PciMemoryRegion']} }
1240
1241##
1242# @PciInfo:
1243#
1244# Information about a PCI bus
1245#
1246# @bus: the bus index
1247#
1248# @devices: a list of devices on this bus
1249#
1250# Since: 0.14.0
1251##
1252{ 'type': 'PciInfo', 'data': {'bus': 'int', 'devices': ['PciDeviceInfo']} }
1253
1254##
1255# @query-pci:
1256#
1257# Return information about the PCI bus topology of the guest.
1258#
1259# Returns: a list of @PciInfo for each PCI bus
1260#
1261# Since: 0.14.0
1262##
1263{ 'command': 'query-pci', 'returns': ['PciInfo'] }
1264
1265##
Paolo Bonzini92aa5c62012-09-28 17:22:55 +02001266# @BlockdevOnError:
1267#
1268# An enumeration of possible behaviors for errors on I/O operations.
1269# The exact meaning depends on whether the I/O was initiated by a guest
1270# or by a block job
1271#
1272# @report: for guest operations, report the error to the guest;
1273# for jobs, cancel the job
1274#
1275# @ignore: ignore the error, only report a QMP event (BLOCK_IO_ERROR
1276# or BLOCK_JOB_ERROR)
1277#
1278# @enospc: same as @stop on ENOSPC, same as @report otherwise.
1279#
1280# @stop: for guest operations, stop the virtual machine;
1281# for jobs, pause the job
1282#
1283# Since: 1.3
1284##
1285{ 'enum': 'BlockdevOnError',
1286 'data': ['report', 'ignore', 'enospc', 'stop'] }
1287
1288##
Paolo Bonzini893f7eb2012-10-18 16:49:23 +02001289# @MirrorSyncMode:
1290#
1291# An enumeration of possible behaviors for the initial synchronization
1292# phase of storage mirroring.
1293#
1294# @top: copies data in the topmost image to the destination
1295#
1296# @full: copies data from all images to the destination
1297#
1298# @none: only copy data written from now on
1299#
1300# Since: 1.3
1301##
1302{ 'enum': 'MirrorSyncMode',
1303 'data': ['top', 'full', 'none'] }
1304
1305##
Stefan Hajnoczifb5458c2012-01-18 14:40:49 +00001306# @BlockJobInfo:
1307#
1308# Information about a long-running block device operation.
1309#
1310# @type: the job type ('stream' for image streaming)
1311#
1312# @device: the block device name
1313#
1314# @len: the maximum progress value
1315#
Paolo Bonzini8d658832012-09-28 17:22:49 +02001316# @busy: false if the job is known to be in a quiescent state, with
1317# no pending I/O. Since 1.3.
1318#
Paolo Bonzini8acc72a2012-09-28 17:22:50 +02001319# @paused: whether the job is paused or, if @busy is true, will
1320# pause itself as soon as possible. Since 1.3.
1321#
Stefan Hajnoczifb5458c2012-01-18 14:40:49 +00001322# @offset: the current progress value
1323#
1324# @speed: the rate limit, bytes per second
1325#
Paolo Bonzini32c81a42012-09-28 17:22:58 +02001326# @io-status: the status of the job (since 1.3)
1327#
Stefan Hajnoczifb5458c2012-01-18 14:40:49 +00001328# Since: 1.1
1329##
1330{ 'type': 'BlockJobInfo',
1331 'data': {'type': 'str', 'device': 'str', 'len': 'int',
Paolo Bonzini32c81a42012-09-28 17:22:58 +02001332 'offset': 'int', 'busy': 'bool', 'paused': 'bool', 'speed': 'int',
1333 'io-status': 'BlockDeviceIoStatus'} }
Stefan Hajnoczifb5458c2012-01-18 14:40:49 +00001334
1335##
1336# @query-block-jobs:
1337#
1338# Return information about long-running block device operations.
1339#
1340# Returns: a list of @BlockJobInfo for each active block job
1341#
1342# Since: 1.1
1343##
1344{ 'command': 'query-block-jobs', 'returns': ['BlockJobInfo'] }
1345
1346##
Luiz Capitulino7a7f3252011-09-15 14:20:28 -03001347# @quit:
1348#
1349# This command will cause the QEMU process to exit gracefully. While every
1350# attempt is made to send the QMP response before terminating, this is not
1351# guaranteed. When using this interface, a premature EOF would not be
1352# unexpected.
1353#
1354# Since: 0.14.0
1355##
1356{ 'command': 'quit' }
Luiz Capitulino5f158f22011-09-15 14:34:39 -03001357
1358##
1359# @stop:
1360#
1361# Stop all guest VCPU execution.
1362#
1363# Since: 0.14.0
1364#
1365# Notes: This function will succeed even if the guest is already in the stopped
Paolo Bonzini1e998142012-10-23 14:54:21 +02001366# state. In "inmigrate" state, it will ensure that the guest
1367# remains paused once migration finishes, as if the -S option was
1368# passed on the command line.
Luiz Capitulino5f158f22011-09-15 14:34:39 -03001369##
1370{ 'command': 'stop' }
Luiz Capitulino38d22652011-09-15 14:41:46 -03001371
1372##
1373# @system_reset:
1374#
1375# Performs a hard reset of a guest.
1376#
1377# Since: 0.14.0
1378##
1379{ 'command': 'system_reset' }
Luiz Capitulino5bc465e2011-09-28 11:06:15 -03001380
1381##
1382# @system_powerdown:
1383#
1384# Requests that a guest perform a powerdown operation.
1385#
1386# Since: 0.14.0
1387#
1388# Notes: A guest may or may not respond to this command. This command
1389# returning does not indicate that a guest has accepted the request or
1390# that it has shut down. Many guests will respond to this command by
1391# prompting the user in some way.
1392##
1393{ 'command': 'system_powerdown' }
Luiz Capitulino755f1962011-10-06 14:31:39 -03001394
1395##
1396# @cpu:
1397#
1398# This command is a nop that is only provided for the purposes of compatibility.
1399#
1400# Since: 0.14.0
1401#
1402# Notes: Do not use this command.
1403##
1404{ 'command': 'cpu', 'data': {'index': 'int'} }
Luiz Capitulino0cfd6a92011-11-22 16:32:37 -02001405
1406##
Igor Mammedov69ca3ea2013-04-30 15:41:25 +02001407# @cpu-add
1408#
1409# Adds CPU with specified ID
1410#
1411# @id: ID of CPU to be created, valid values [0..max_cpus)
1412#
1413# Returns: Nothing on success
1414#
1415# Since 1.5
1416##
1417{ 'command': 'cpu-add', 'data': {'id': 'int'} }
1418
1419##
Luiz Capitulino0cfd6a92011-11-22 16:32:37 -02001420# @memsave:
1421#
1422# Save a portion of guest memory to a file.
1423#
1424# @val: the virtual address of the guest to start from
1425#
1426# @size: the size of memory region to save
1427#
1428# @filename: the file to save the memory to as binary data
1429#
1430# @cpu-index: #optional the index of the virtual CPU to use for translating the
1431# virtual address (defaults to CPU 0)
1432#
1433# Returns: Nothing on success
Luiz Capitulino0cfd6a92011-11-22 16:32:37 -02001434#
1435# Since: 0.14.0
1436#
1437# Notes: Errors were not reliably returned until 1.1
1438##
1439{ 'command': 'memsave',
1440 'data': {'val': 'int', 'size': 'int', 'filename': 'str', '*cpu-index': 'int'} }
Luiz Capitulino6d3962b2011-11-22 17:26:46 -02001441
1442##
1443# @pmemsave:
1444#
1445# Save a portion of guest physical memory to a file.
1446#
1447# @val: the physical address of the guest to start from
1448#
1449# @size: the size of memory region to save
1450#
1451# @filename: the file to save the memory to as binary data
1452#
1453# Returns: Nothing on success
Luiz Capitulino6d3962b2011-11-22 17:26:46 -02001454#
1455# Since: 0.14.0
1456#
1457# Notes: Errors were not reliably returned until 1.1
1458##
1459{ 'command': 'pmemsave',
1460 'data': {'val': 'int', 'size': 'int', 'filename': 'str'} }
Luiz Capitulinoe42e8182011-11-22 17:58:31 -02001461
1462##
1463# @cont:
1464#
1465# Resume guest VCPU execution.
1466#
1467# Since: 0.14.0
1468#
1469# Returns: If successful, nothing
Luiz Capitulinoe42e8182011-11-22 17:58:31 -02001470# If QEMU was started with an encrypted block device and a key has
1471# not yet been set, DeviceEncrypted.
1472#
Paolo Bonzini1e998142012-10-23 14:54:21 +02001473# Notes: This command will succeed if the guest is currently running. It
1474# will also succeed if the guest is in the "inmigrate" state; in
1475# this case, the effect of the command is to make sure the guest
1476# starts once migration finishes, removing the effect of the -S
1477# command line option if it was passed.
Luiz Capitulinoe42e8182011-11-22 17:58:31 -02001478##
1479{ 'command': 'cont' }
1480
Luiz Capitulinoab49ab52011-11-23 12:55:53 -02001481##
Gerd Hoffmann9b9df252012-02-23 13:45:21 +01001482# @system_wakeup:
1483#
1484# Wakeup guest from suspend. Does nothing in case the guest isn't suspended.
1485#
1486# Since: 1.1
1487#
1488# Returns: nothing.
1489##
1490{ 'command': 'system_wakeup' }
1491
1492##
Luiz Capitulinoab49ab52011-11-23 12:55:53 -02001493# @inject-nmi:
1494#
1495# Injects an Non-Maskable Interrupt into all guest's VCPUs.
1496#
1497# Returns: If successful, nothing
Luiz Capitulinoab49ab52011-11-23 12:55:53 -02001498#
1499# Since: 0.14.0
1500#
1501# Notes: Only x86 Virtual Machines support this command.
1502##
1503{ 'command': 'inject-nmi' }
Luiz Capitulino4b371562011-11-23 13:11:55 -02001504
1505##
1506# @set_link:
1507#
1508# Sets the link status of a virtual network adapter.
1509#
1510# @name: the device name of the virtual network adapter
1511#
1512# @up: true to set the link status to be up
1513#
1514# Returns: Nothing on success
1515# If @name is not a valid network device, DeviceNotFound
1516#
1517# Since: 0.14.0
1518#
1519# Notes: Not all network adapters support setting link status. This command
1520# will succeed even if the network adapter does not support link status
1521# notification.
1522##
1523{ 'command': 'set_link', 'data': {'name': 'str', 'up': 'bool'} }
Luiz Capitulinoa4dea8a2011-11-23 13:28:21 -02001524
1525##
1526# @block_passwd:
1527#
1528# This command sets the password of a block device that has not been open
1529# with a password and requires one.
1530#
1531# The two cases where this can happen are a block device is created through
1532# QEMU's initial command line or a block device is changed through the legacy
1533# @change interface.
1534#
1535# In the event that the block device is created through the initial command
1536# line, the VM will start in the stopped state regardless of whether '-S' is
1537# used. The intention is for a management tool to query the block devices to
1538# determine which ones are encrypted, set the passwords with this command, and
1539# then start the guest with the @cont command.
1540#
1541# @device: the name of the device to set the password on
1542#
1543# @password: the password to use for the device
1544#
1545# Returns: nothing on success
1546# If @device is not a valid block device, DeviceNotFound
1547# If @device is not encrypted, DeviceNotEncrypted
Luiz Capitulinoa4dea8a2011-11-23 13:28:21 -02001548#
1549# Notes: Not all block formats support encryption and some that do are not
1550# able to validate that a password is correct. Disk corruption may
1551# occur if an invalid password is specified.
1552#
1553# Since: 0.14.0
1554##
1555{ 'command': 'block_passwd', 'data': {'device': 'str', 'password': 'str'} }
Luiz Capitulinod72f3262011-11-25 14:38:09 -02001556
1557##
1558# @balloon:
1559#
1560# Request the balloon driver to change its balloon size.
1561#
1562# @value: the target size of the balloon in bytes
1563#
1564# Returns: Nothing on success
1565# If the balloon driver is enabled but not functional because the KVM
1566# kernel module cannot support it, KvmMissingCap
1567# If no balloon device is present, DeviceNotActive
1568#
1569# Notes: This command just issues a request to the guest. When it returns,
1570# the balloon size may not have changed. A guest can change the balloon
1571# size independent of this command.
1572#
1573# Since: 0.14.0
1574##
1575{ 'command': 'balloon', 'data': {'value': 'int'} }
Luiz Capitulino5e7caac2011-11-25 14:57:10 -02001576
1577##
1578# @block_resize
1579#
1580# Resize a block image while a guest is running.
1581#
1582# @device: the name of the device to get the image resized
1583#
1584# @size: new image size in bytes
1585#
1586# Returns: nothing on success
1587# If @device is not a valid block device, DeviceNotFound
Luiz Capitulino5e7caac2011-11-25 14:57:10 -02001588#
1589# Since: 0.14.0
1590##
1591{ 'command': 'block_resize', 'data': { 'device': 'str', 'size': 'int' }}
Luiz Capitulino6106e242011-11-25 16:15:19 -02001592
1593##
Paolo Bonzinibc8b0942012-03-06 18:55:58 +01001594# @NewImageMode
1595#
1596# An enumeration that tells QEMU how to set the backing file path in
1597# a new image file.
1598#
1599# @existing: QEMU should look for an existing image file.
1600#
1601# @absolute-paths: QEMU should create a new image with absolute paths
1602# for the backing file.
1603#
1604# Since: 1.1
1605##
Amos Kongad0f1712013-06-19 17:23:27 +08001606{ 'enum': 'NewImageMode',
Paolo Bonzinibc8b0942012-03-06 18:55:58 +01001607 'data': [ 'existing', 'absolute-paths' ] }
1608
1609##
Paolo Bonzini52e7c242012-03-06 18:55:57 +01001610# @BlockdevSnapshot
Jeff Cody8802d1f2012-02-28 15:54:06 -05001611#
1612# @device: the name of the device to generate the snapshot from.
1613#
1614# @snapshot-file: the target of the new image. A new file will be created.
1615#
1616# @format: #optional the format of the snapshot image, default is 'qcow2'.
Paolo Bonzini6cc2a412012-03-06 18:55:59 +01001617#
1618# @mode: #optional whether and how QEMU should create a new image, default is
Paolo Bonzini8bde9b62012-09-26 16:34:29 +02001619# 'absolute-paths'.
Jeff Cody8802d1f2012-02-28 15:54:06 -05001620##
Paolo Bonzini52e7c242012-03-06 18:55:57 +01001621{ 'type': 'BlockdevSnapshot',
Paolo Bonzinibc8b0942012-03-06 18:55:58 +01001622 'data': { 'device': 'str', 'snapshot-file': 'str', '*format': 'str',
1623 '*mode': 'NewImageMode' } }
Jeff Cody8802d1f2012-02-28 15:54:06 -05001624
1625##
Stefan Hajnoczi3037f362013-06-24 17:13:17 +02001626# @DriveBackup
1627#
1628# @device: the name of the device which should be copied.
1629#
1630# @target: the target of the new image. If the file exists, or if it
1631# is a device, the existing file/device will be used as the new
1632# destination. If it does not exist, a new file will be created.
1633#
1634# @format: #optional the format of the new destination, default is to
1635# probe if @mode is 'existing', else the format of the source
1636#
1637# @mode: #optional whether and how QEMU should create a new image, default is
1638# 'absolute-paths'.
1639#
1640# @speed: #optional the maximum speed, in bytes per second
1641#
1642# @on-source-error: #optional the action to take on an error on the source,
1643# default 'report'. 'stop' and 'enospc' can only be used
1644# if the block device supports io-status (see BlockInfo).
1645#
1646# @on-target-error: #optional the action to take on an error on the target,
1647# default 'report' (no limitations, since this applies to
1648# a different block device than @device).
1649#
1650# Note that @on-source-error and @on-target-error only affect background I/O.
1651# If an error occurs during a guest write request, the device's rerror/werror
1652# actions will be used.
1653#
1654# Since: 1.6
1655##
1656{ 'type': 'DriveBackup',
1657 'data': { 'device': 'str', 'target': 'str', '*format': 'str',
1658 '*mode': 'NewImageMode', '*speed': 'int',
1659 '*on-source-error': 'BlockdevOnError',
1660 '*on-target-error': 'BlockdevOnError' } }
1661
1662##
Stefan Hajnoczi78b18b72013-06-24 17:13:18 +02001663# @Abort
1664#
1665# This action can be used to test transaction failure.
1666#
1667# Since: 1.6
1668###
1669{ 'type': 'Abort',
1670 'data': { } }
1671
1672##
Kevin Wolfc8a83e82013-05-13 10:43:43 +02001673# @TransactionAction
Jeff Cody8802d1f2012-02-28 15:54:06 -05001674#
Paolo Bonzini52e7c242012-03-06 18:55:57 +01001675# A discriminated record of operations that can be performed with
1676# @transaction.
1677##
Kevin Wolfc8a83e82013-05-13 10:43:43 +02001678{ 'union': 'TransactionAction',
Paolo Bonzini52e7c242012-03-06 18:55:57 +01001679 'data': {
Stefan Hajnoczi3037f362013-06-24 17:13:17 +02001680 'blockdev-snapshot-sync': 'BlockdevSnapshot',
Stefan Hajnoczi78b18b72013-06-24 17:13:18 +02001681 'drive-backup': 'DriveBackup',
1682 'abort': 'Abort'
Paolo Bonzini52e7c242012-03-06 18:55:57 +01001683 } }
1684
1685##
1686# @transaction
1687#
Kevin Wolfc8a83e82013-05-13 10:43:43 +02001688# Executes a number of transactionable QMP commands atomically. If any
1689# operation fails, then the entire set of actions will be abandoned and the
1690# appropriate error returned.
Jeff Cody8802d1f2012-02-28 15:54:06 -05001691#
1692# List of:
Kevin Wolfc8a83e82013-05-13 10:43:43 +02001693# @TransactionAction: information needed for the respective operation
Jeff Cody8802d1f2012-02-28 15:54:06 -05001694#
1695# Returns: nothing on success
Kevin Wolfc8a83e82013-05-13 10:43:43 +02001696# Errors depend on the operations of the transaction
Jeff Cody8802d1f2012-02-28 15:54:06 -05001697#
Kevin Wolfc8a83e82013-05-13 10:43:43 +02001698# Note: The transaction aborts on the first failure. Therefore, there will be
1699# information on only one failed operation returned in an error condition, and
Paolo Bonzini52e7c242012-03-06 18:55:57 +01001700# subsequent actions will not have been attempted.
1701#
1702# Since 1.1
Jeff Cody8802d1f2012-02-28 15:54:06 -05001703##
Paolo Bonzini52e7c242012-03-06 18:55:57 +01001704{ 'command': 'transaction',
Kevin Wolfc8a83e82013-05-13 10:43:43 +02001705 'data': { 'actions': [ 'TransactionAction' ] } }
Jeff Cody8802d1f2012-02-28 15:54:06 -05001706
1707##
Luiz Capitulino6106e242011-11-25 16:15:19 -02001708# @blockdev-snapshot-sync
1709#
1710# Generates a synchronous snapshot of a block device.
1711#
Kevin Wolf852ad1a2013-07-01 16:31:52 +02001712# For the arguments, see the documentation of BlockdevSnapshot.
Paolo Bonzini6cc2a412012-03-06 18:55:59 +01001713#
Luiz Capitulino6106e242011-11-25 16:15:19 -02001714# Returns: nothing on success
1715# If @device is not a valid block device, DeviceNotFound
Luiz Capitulino6106e242011-11-25 16:15:19 -02001716#
Luiz Capitulino6106e242011-11-25 16:15:19 -02001717# Since 0.14.0
1718##
1719{ 'command': 'blockdev-snapshot-sync',
Kevin Wolf852ad1a2013-07-01 16:31:52 +02001720 'data': 'BlockdevSnapshot' }
Luiz Capitulinod51a67b2011-11-25 17:52:45 -02001721
1722##
1723# @human-monitor-command:
1724#
1725# Execute a command on the human monitor and return the output.
1726#
1727# @command-line: the command to execute in the human monitor
1728#
1729# @cpu-index: #optional The CPU to use for commands that require an implicit CPU
1730#
1731# Returns: the output of the command as a string
1732#
1733# Since: 0.14.0
1734#
1735# Notes: This command only exists as a stop-gap. It's use is highly
1736# discouraged. The semantics of this command are not guaranteed.
1737#
1738# Known limitations:
1739#
1740# o This command is stateless, this means that commands that depend
1741# on state information (such as getfd) might not work
1742#
1743# o Commands that prompt the user for data (eg. 'cont' when the block
1744# device is encrypted) don't currently work
1745##
1746{ 'command': 'human-monitor-command',
1747 'data': {'command-line': 'str', '*cpu-index': 'int'},
Laszlo Ersekb80e5602012-07-17 16:17:10 +02001748 'returns': 'str' }
Luiz Capitulino6cdedb02011-11-27 22:54:09 -02001749
1750##
Jeff Codyed61fc12012-09-27 13:29:16 -04001751# @block-commit
1752#
1753# Live commit of data from overlay image nodes into backing nodes - i.e.,
1754# writes data between 'top' and 'base' into 'base'.
1755#
1756# @device: the name of the device
1757#
1758# @base: #optional The file name of the backing image to write data into.
1759# If not specified, this is the deepest backing image
1760#
1761# @top: The file name of the backing image within the image chain,
1762# which contains the topmost data to be committed down.
1763# Note, the active layer as 'top' is currently unsupported.
1764#
1765# If top == base, that is an error.
1766#
1767#
1768# @speed: #optional the maximum speed, in bytes per second
1769#
1770# Returns: Nothing on success
1771# If commit or stream is already active on this device, DeviceInUse
1772# If @device does not exist, DeviceNotFound
1773# If image commit is not supported by this device, NotSupported
1774# If @base or @top is invalid, a generic error is returned
1775# If @top is the active layer, or omitted, a generic error is returned
1776# If @speed is invalid, InvalidParameter
1777#
1778# Since: 1.3
1779#
1780##
1781{ 'command': 'block-commit',
1782 'data': { 'device': 'str', '*base': 'str', 'top': 'str',
1783 '*speed': 'int' } }
1784
Paolo Bonzinid9b902d2012-10-18 16:49:24 +02001785##
Stefan Hajnoczi99a9add2013-06-24 17:13:14 +02001786# @drive-backup
1787#
1788# Start a point-in-time copy of a block device to a new destination. The
1789# status of ongoing drive-backup operations can be checked with
1790# query-block-jobs where the BlockJobInfo.type field has the value 'backup'.
1791# The operation can be stopped before it has completed using the
1792# block-job-cancel command.
1793#
1794# @device: the name of the device which should be copied.
1795#
1796# @target: the target of the new image. If the file exists, or if it
1797# is a device, the existing file/device will be used as the new
1798# destination. If it does not exist, a new file will be created.
1799#
1800# @format: #optional the format of the new destination, default is to
1801# probe if @mode is 'existing', else the format of the source
1802#
1803# @mode: #optional whether and how QEMU should create a new image, default is
1804# 'absolute-paths'.
1805#
1806# @speed: #optional the maximum speed, in bytes per second
1807#
1808# @on-source-error: #optional the action to take on an error on the source,
1809# default 'report'. 'stop' and 'enospc' can only be used
1810# if the block device supports io-status (see BlockInfo).
1811#
1812# @on-target-error: #optional the action to take on an error on the target,
1813# default 'report' (no limitations, since this applies to
1814# a different block device than @device).
1815#
1816# Note that @on-source-error and @on-target-error only affect background I/O.
1817# If an error occurs during a guest write request, the device's rerror/werror
1818# actions will be used.
1819#
1820# Returns: nothing on success
1821# If @device is not a valid block device, DeviceNotFound
1822#
1823# Since 1.6
1824##
1825{ 'command': 'drive-backup',
1826 'data': { 'device': 'str', 'target': 'str', '*format': 'str',
1827 '*mode': 'NewImageMode', '*speed': 'int',
1828 '*on-source-error': 'BlockdevOnError',
1829 '*on-target-error': 'BlockdevOnError' } }
1830
1831##
Paolo Bonzinid9b902d2012-10-18 16:49:24 +02001832# @drive-mirror
1833#
1834# Start mirroring a block device's writes to a new destination.
1835#
1836# @device: the name of the device whose writes should be mirrored.
1837#
1838# @target: the target of the new image. If the file exists, or if it
1839# is a device, the existing file/device will be used as the new
1840# destination. If it does not exist, a new file will be created.
1841#
1842# @format: #optional the format of the new destination, default is to
1843# probe if @mode is 'existing', else the format of the source
1844#
1845# @mode: #optional whether and how QEMU should create a new image, default is
1846# 'absolute-paths'.
1847#
1848# @speed: #optional the maximum speed, in bytes per second
1849#
1850# @sync: what parts of the disk image should be copied to the destination
1851# (all the disk, only the sectors allocated in the topmost image, or
1852# only new I/O).
1853#
Paolo Bonzinieee13df2013-01-21 17:09:46 +01001854# @granularity: #optional granularity of the dirty bitmap, default is 64K
1855# if the image format doesn't have clusters, 4K if the clusters
1856# are smaller than that, else the cluster size. Must be a
1857# power of 2 between 512 and 64M (since 1.4).
1858#
Paolo Bonzini08e4ed62013-01-22 09:03:13 +01001859# @buf-size: #optional maximum amount of data in flight from source to
1860# target (since 1.4).
1861#
Paolo Bonzinib952b552012-10-18 16:49:28 +02001862# @on-source-error: #optional the action to take on an error on the source,
1863# default 'report'. 'stop' and 'enospc' can only be used
1864# if the block device supports io-status (see BlockInfo).
1865#
1866# @on-target-error: #optional the action to take on an error on the target,
1867# default 'report' (no limitations, since this applies to
1868# a different block device than @device).
1869#
Paolo Bonzinid9b902d2012-10-18 16:49:24 +02001870# Returns: nothing on success
1871# If @device is not a valid block device, DeviceNotFound
1872#
1873# Since 1.3
1874##
1875{ 'command': 'drive-mirror',
1876 'data': { 'device': 'str', 'target': 'str', '*format': 'str',
1877 'sync': 'MirrorSyncMode', '*mode': 'NewImageMode',
Paolo Bonzinieee13df2013-01-21 17:09:46 +01001878 '*speed': 'int', '*granularity': 'uint32',
Paolo Bonzini08e4ed62013-01-22 09:03:13 +01001879 '*buf-size': 'int', '*on-source-error': 'BlockdevOnError',
Paolo Bonzinib952b552012-10-18 16:49:28 +02001880 '*on-target-error': 'BlockdevOnError' } }
Paolo Bonzinid9b902d2012-10-18 16:49:24 +02001881
1882##
Luiz Capitulino6cdedb02011-11-27 22:54:09 -02001883# @migrate_cancel
1884#
1885# Cancel the current executing migration process.
1886#
1887# Returns: nothing on success
1888#
1889# Notes: This command succeeds even if there is no migration process running.
1890#
1891# Since: 0.14.0
1892##
1893{ 'command': 'migrate_cancel' }
Luiz Capitulino4f0a9932011-11-27 23:18:01 -02001894
1895##
1896# @migrate_set_downtime
1897#
1898# Set maximum tolerated downtime for migration.
1899#
1900# @value: maximum downtime in seconds
1901#
1902# Returns: nothing on success
1903#
1904# Since: 0.14.0
1905##
1906{ 'command': 'migrate_set_downtime', 'data': {'value': 'number'} }
Luiz Capitulino3dc85382011-11-28 11:59:37 -02001907
1908##
1909# @migrate_set_speed
1910#
1911# Set maximum speed for migration.
1912#
1913# @value: maximum speed in bytes.
1914#
1915# Returns: nothing on success
1916#
1917# Notes: A value lesser than zero will be automatically round up to zero.
1918#
1919# Since: 0.14.0
1920##
1921{ 'command': 'migrate_set_speed', 'data': {'value': 'int'} }
Anthony Liguorib4b12c62011-12-12 14:29:34 -06001922
1923##
Orit Wasserman9e1ba4c2012-08-06 21:42:54 +03001924# @migrate-set-cache-size
1925#
1926# Set XBZRLE cache size
1927#
1928# @value: cache size in bytes
1929#
1930# The size will be rounded down to the nearest power of 2.
1931# The cache size can be modified before and during ongoing migration
1932#
1933# Returns: nothing on success
1934#
1935# Since: 1.2
1936##
1937{ 'command': 'migrate-set-cache-size', 'data': {'value': 'int'} }
1938
1939##
1940# @query-migrate-cache-size
1941#
1942# query XBZRLE cache size
1943#
1944# Returns: XBZRLE cache size in bytes
1945#
1946# Since: 1.2
1947##
1948{ 'command': 'query-migrate-cache-size', 'returns': 'int' }
1949
1950##
Alon Levyd03ee402012-03-05 15:13:28 +02001951# @ObjectPropertyInfo:
Anthony Liguorib4b12c62011-12-12 14:29:34 -06001952#
1953# @name: the name of the property
1954#
1955# @type: the type of the property. This will typically come in one of four
1956# forms:
1957#
1958# 1) A primitive type such as 'u8', 'u16', 'bool', 'str', or 'double'.
1959# These types are mapped to the appropriate JSON type.
1960#
1961# 2) A legacy type in the form 'legacy<subtype>' where subtype is the
1962# legacy qdev typename. These types are always treated as strings.
1963#
1964# 3) A child type in the form 'child<subtype>' where subtype is a qdev
1965# device type name. Child properties create the composition tree.
1966#
1967# 4) A link type in the form 'link<subtype>' where subtype is a qdev
1968# device type name. Link properties form the device model graph.
1969#
Anthony Liguori51920822012-08-10 11:04:10 -05001970# Since: 1.2
Anthony Liguorib4b12c62011-12-12 14:29:34 -06001971##
Anthony Liguori57c9faf2012-01-30 08:55:55 -06001972{ 'type': 'ObjectPropertyInfo',
Anthony Liguorib4b12c62011-12-12 14:29:34 -06001973 'data': { 'name': 'str', 'type': 'str' } }
1974
1975##
1976# @qom-list:
1977#
Anthony Liguori57c9faf2012-01-30 08:55:55 -06001978# This command will list any properties of a object given a path in the object
Anthony Liguorib4b12c62011-12-12 14:29:34 -06001979# model.
1980#
Anthony Liguori57c9faf2012-01-30 08:55:55 -06001981# @path: the path within the object model. See @qom-get for a description of
Anthony Liguorib4b12c62011-12-12 14:29:34 -06001982# this parameter.
1983#
Anthony Liguori57c9faf2012-01-30 08:55:55 -06001984# Returns: a list of @ObjectPropertyInfo that describe the properties of the
1985# object.
Anthony Liguorib4b12c62011-12-12 14:29:34 -06001986#
Anthony Liguori51920822012-08-10 11:04:10 -05001987# Since: 1.2
Anthony Liguorib4b12c62011-12-12 14:29:34 -06001988##
1989{ 'command': 'qom-list',
1990 'data': { 'path': 'str' },
Anthony Liguori57c9faf2012-01-30 08:55:55 -06001991 'returns': [ 'ObjectPropertyInfo' ] }
Anthony Liguorieb6e8ea2011-12-12 14:29:35 -06001992
1993##
1994# @qom-get:
1995#
Anthony Liguori57c9faf2012-01-30 08:55:55 -06001996# This command will get a property from a object model path and return the
Anthony Liguorieb6e8ea2011-12-12 14:29:35 -06001997# value.
1998#
Anthony Liguori57c9faf2012-01-30 08:55:55 -06001999# @path: The path within the object model. There are two forms of supported
Anthony Liguorieb6e8ea2011-12-12 14:29:35 -06002000# paths--absolute and partial paths.
2001#
Anthony Liguori57c9faf2012-01-30 08:55:55 -06002002# Absolute paths are derived from the root object and can follow child<>
Anthony Liguorieb6e8ea2011-12-12 14:29:35 -06002003# or link<> properties. Since they can follow link<> properties, they
2004# can be arbitrarily long. Absolute paths look like absolute filenames
2005# and are prefixed with a leading slash.
2006#
2007# Partial paths look like relative filenames. They do not begin
2008# with a prefix. The matching rules for partial paths are subtle but
Anthony Liguori57c9faf2012-01-30 08:55:55 -06002009# designed to make specifying objects easy. At each level of the
Anthony Liguorieb6e8ea2011-12-12 14:29:35 -06002010# composition tree, the partial path is matched as an absolute path.
2011# The first match is not returned. At least two matches are searched
2012# for. A successful result is only returned if only one match is
2013# found. If more than one match is found, a flag is return to
2014# indicate that the match was ambiguous.
2015#
2016# @property: The property name to read
2017#
2018# Returns: The property value. The type depends on the property type. legacy<>
2019# properties are returned as #str. child<> and link<> properties are
2020# returns as #str pathnames. All integer property types (u8, u16, etc)
2021# are returned as #int.
2022#
Anthony Liguori51920822012-08-10 11:04:10 -05002023# Since: 1.2
Anthony Liguorieb6e8ea2011-12-12 14:29:35 -06002024##
2025{ 'command': 'qom-get',
2026 'data': { 'path': 'str', 'property': 'str' },
2027 'returns': 'visitor',
2028 'gen': 'no' }
2029
2030##
2031# @qom-set:
2032#
Anthony Liguori57c9faf2012-01-30 08:55:55 -06002033# This command will set a property from a object model path.
Anthony Liguorieb6e8ea2011-12-12 14:29:35 -06002034#
2035# @path: see @qom-get for a description of this parameter
2036#
2037# @property: the property name to set
2038#
2039# @value: a value who's type is appropriate for the property type. See @qom-get
2040# for a description of type mapping.
2041#
Anthony Liguori51920822012-08-10 11:04:10 -05002042# Since: 1.2
Anthony Liguorieb6e8ea2011-12-12 14:29:35 -06002043##
2044{ 'command': 'qom-set',
2045 'data': { 'path': 'str', 'property': 'str', 'value': 'visitor' },
2046 'gen': 'no' }
Luiz Capitulinofbf796f2011-12-07 11:17:51 -02002047
2048##
2049# @set_password:
2050#
2051# Sets the password of a remote display session.
2052#
2053# @protocol: `vnc' to modify the VNC server password
2054# `spice' to modify the Spice server password
2055#
2056# @password: the new password
2057#
2058# @connected: #optional how to handle existing clients when changing the
Laszlo Ersekb80e5602012-07-17 16:17:10 +02002059# password. If nothing is specified, defaults to `keep'
Luiz Capitulinofbf796f2011-12-07 11:17:51 -02002060# `fail' to fail the command if clients are connected
2061# `disconnect' to disconnect existing clients
2062# `keep' to maintain existing clients
2063#
2064# Returns: Nothing on success
2065# If Spice is not enabled, DeviceNotFound
Luiz Capitulinofbf796f2011-12-07 11:17:51 -02002066#
2067# Since: 0.14.0
2068##
2069{ 'command': 'set_password',
2070 'data': {'protocol': 'str', 'password': 'str', '*connected': 'str'} }
Luiz Capitulino9ad53722011-12-07 11:47:57 -02002071
2072##
2073# @expire_password:
2074#
2075# Expire the password of a remote display server.
2076#
2077# @protocol: the name of the remote display protocol `vnc' or `spice'
2078#
2079# @time: when to expire the password.
2080# `now' to expire the password immediately
2081# `never' to cancel password expiration
2082# `+INT' where INT is the number of seconds from now (integer)
2083# `INT' where INT is the absolute time in seconds
2084#
2085# Returns: Nothing on success
2086# If @protocol is `spice' and Spice is not active, DeviceNotFound
Luiz Capitulino9ad53722011-12-07 11:47:57 -02002087#
2088# Since: 0.14.0
2089#
2090# Notes: Time is relative to the server and currently there is no way to
2091# coordinate server time with client time. It is not recommended to
2092# use the absolute time version of the @time parameter unless you're
2093# sure you are on the same machine as the QEMU instance.
2094##
2095{ 'command': 'expire_password', 'data': {'protocol': 'str', 'time': 'str'} }
Luiz Capitulinoc245b6a2011-12-07 16:02:36 -02002096
2097##
2098# @eject:
2099#
2100# Ejects a device from a removable drive.
2101#
2102# @device: The name of the device
2103#
2104# @force: @optional If true, eject regardless of whether the drive is locked.
2105# If not specified, the default value is false.
2106#
2107# Returns: Nothing on success
2108# If @device is not a valid block device, DeviceNotFound
Luiz Capitulinoc245b6a2011-12-07 16:02:36 -02002109#
2110# Notes: Ejecting a device will no media results in success
2111#
2112# Since: 0.14.0
2113##
2114{ 'command': 'eject', 'data': {'device': 'str', '*force': 'bool'} }
Luiz Capitulino270b2432011-12-08 11:45:55 -02002115
2116##
2117# @change-vnc-password:
2118#
2119# Change the VNC server password.
2120#
2121# @target: the new password to use with VNC authentication
2122#
2123# Since: 1.1
2124#
2125# Notes: An empty password in this command will set the password to the empty
2126# string. Existing clients are unaffected by executing this command.
2127##
2128{ 'command': 'change-vnc-password', 'data': {'password': 'str'} }
Luiz Capitulino333a96e2011-12-08 11:13:50 -02002129
2130##
2131# @change:
2132#
2133# This command is multiple commands multiplexed together.
2134#
2135# @device: This is normally the name of a block device but it may also be 'vnc'.
2136# when it's 'vnc', then sub command depends on @target
2137#
2138# @target: If @device is a block device, then this is the new filename.
2139# If @device is 'vnc', then if the value 'password' selects the vnc
2140# change password command. Otherwise, this specifies a new server URI
2141# address to listen to for VNC connections.
2142#
2143# @arg: If @device is a block device, then this is an optional format to open
2144# the device with.
2145# If @device is 'vnc' and @target is 'password', this is the new VNC
2146# password to set. If this argument is an empty string, then no future
2147# logins will be allowed.
2148#
2149# Returns: Nothing on success.
2150# If @device is not a valid block device, DeviceNotFound
Luiz Capitulino333a96e2011-12-08 11:13:50 -02002151# If the new block device is encrypted, DeviceEncrypted. Note that
2152# if this error is returned, the device has been opened successfully
2153# and an additional call to @block_passwd is required to set the
2154# device's password. The behavior of reads and writes to the block
2155# device between when these calls are executed is undefined.
2156#
2157# Notes: It is strongly recommended that this interface is not used especially
2158# for changing block devices.
2159#
2160# Since: 0.14.0
2161##
2162{ 'command': 'change',
2163 'data': {'device': 'str', 'target': 'str', '*arg': 'str'} }
Luiz Capitulino80047da2011-12-14 16:49:14 -02002164
2165##
2166# @block_set_io_throttle:
2167#
2168# Change I/O throttle limits for a block drive.
2169#
2170# @device: The name of the device
2171#
2172# @bps: total throughput limit in bytes per second
2173#
2174# @bps_rd: read throughput limit in bytes per second
2175#
2176# @bps_wr: write throughput limit in bytes per second
2177#
2178# @iops: total I/O operations per second
2179#
2180# @ops_rd: read I/O operations per second
2181#
2182# @iops_wr: write I/O operations per second
2183#
2184# Returns: Nothing on success
2185# If @device is not a valid block device, DeviceNotFound
Luiz Capitulino80047da2011-12-14 16:49:14 -02002186#
2187# Since: 1.1
Laszlo Ersekb80e5602012-07-17 16:17:10 +02002188##
Luiz Capitulino80047da2011-12-14 16:49:14 -02002189{ 'command': 'block_set_io_throttle',
2190 'data': { 'device': 'str', 'bps': 'int', 'bps_rd': 'int', 'bps_wr': 'int',
2191 'iops': 'int', 'iops_rd': 'int', 'iops_wr': 'int' } }
Stefan Hajnoczi12bd4512012-01-18 14:40:46 +00002192
Stefan Hajnoczidb58f9c2012-04-11 16:27:10 +01002193##
2194# @block-stream:
Stefan Hajnoczi12bd4512012-01-18 14:40:46 +00002195#
2196# Copy data from a backing file into a block device.
2197#
2198# The block streaming operation is performed in the background until the entire
2199# backing file has been copied. This command returns immediately once streaming
2200# has started. The status of ongoing block streaming operations can be checked
2201# with query-block-jobs. The operation can be stopped before it has completed
Stefan Hajnoczidb58f9c2012-04-11 16:27:10 +01002202# using the block-job-cancel command.
Stefan Hajnoczi12bd4512012-01-18 14:40:46 +00002203#
2204# If a base file is specified then sectors are not copied from that base file and
2205# its backing chain. When streaming completes the image file will have the base
2206# file as its backing file. This can be used to stream a subset of the backing
2207# file chain instead of flattening the entire image.
2208#
2209# On successful completion the image file is updated to drop the backing file
2210# and the BLOCK_JOB_COMPLETED event is emitted.
2211#
2212# @device: the device name
2213#
2214# @base: #optional the common backing file name
2215#
Stefan Hajnoczic83c66c2012-04-25 16:51:03 +01002216# @speed: #optional the maximum speed, in bytes per second
2217#
Paolo Bonzini1d809092012-09-28 17:22:59 +02002218# @on-error: #optional the action to take on an error (default report).
2219# 'stop' and 'enospc' can only be used if the block device
2220# supports io-status (see BlockInfo). Since 1.3.
2221#
Stefan Hajnoczi12bd4512012-01-18 14:40:46 +00002222# Returns: Nothing on success
Stefan Hajnoczi12bd4512012-01-18 14:40:46 +00002223# If @device does not exist, DeviceNotFound
Stefan Hajnoczi12bd4512012-01-18 14:40:46 +00002224#
2225# Since: 1.1
2226##
Paolo Bonzini1d809092012-09-28 17:22:59 +02002227{ 'command': 'block-stream',
2228 'data': { 'device': 'str', '*base': 'str', '*speed': 'int',
2229 '*on-error': 'BlockdevOnError' } }
Stefan Hajnoczi2d47c6e2012-01-18 14:40:47 +00002230
2231##
Stefan Hajnoczidb58f9c2012-04-11 16:27:10 +01002232# @block-job-set-speed:
Stefan Hajnoczi2d47c6e2012-01-18 14:40:47 +00002233#
2234# Set maximum speed for a background block operation.
2235#
2236# This command can only be issued when there is an active block job.
2237#
2238# Throttling can be disabled by setting the speed to 0.
2239#
2240# @device: the device name
2241#
Stefan Hajnoczic83c66c2012-04-25 16:51:03 +01002242# @speed: the maximum speed, in bytes per second, or 0 for unlimited.
2243# Defaults to 0.
Stefan Hajnoczi2d47c6e2012-01-18 14:40:47 +00002244#
2245# Returns: Nothing on success
Paolo Bonzini05290d82012-07-24 13:03:39 +02002246# If no background operation is active on this device, DeviceNotActive
Stefan Hajnoczi2d47c6e2012-01-18 14:40:47 +00002247#
2248# Since: 1.1
2249##
Stefan Hajnoczidb58f9c2012-04-11 16:27:10 +01002250{ 'command': 'block-job-set-speed',
Stefan Hajnoczi882ec7c2012-04-25 16:51:02 +01002251 'data': { 'device': 'str', 'speed': 'int' } }
Stefan Hajnoczi370521a2012-01-18 14:40:48 +00002252
2253##
Stefan Hajnoczidb58f9c2012-04-11 16:27:10 +01002254# @block-job-cancel:
Stefan Hajnoczi370521a2012-01-18 14:40:48 +00002255#
Paolo Bonzini05290d82012-07-24 13:03:39 +02002256# Stop an active background block operation.
Stefan Hajnoczi370521a2012-01-18 14:40:48 +00002257#
Paolo Bonzini05290d82012-07-24 13:03:39 +02002258# This command returns immediately after marking the active background block
Stefan Hajnoczi370521a2012-01-18 14:40:48 +00002259# operation for cancellation. It is an error to call this command if no
2260# operation is in progress.
2261#
2262# The operation will cancel as soon as possible and then emit the
2263# BLOCK_JOB_CANCELLED event. Before that happens the job is still visible when
2264# enumerated using query-block-jobs.
2265#
Paolo Bonzini05290d82012-07-24 13:03:39 +02002266# For streaming, the image file retains its backing file unless the streaming
2267# operation happens to complete just as it is being cancelled. A new streaming
2268# operation can be started at a later time to finish copying all data from the
2269# backing file.
Stefan Hajnoczi370521a2012-01-18 14:40:48 +00002270#
2271# @device: the device name
2272#
Paolo Bonzini6e37fb82012-09-28 17:22:51 +02002273# @force: #optional whether to allow cancellation of a paused job (default
2274# false). Since 1.3.
2275#
Stefan Hajnoczi370521a2012-01-18 14:40:48 +00002276# Returns: Nothing on success
Paolo Bonzini05290d82012-07-24 13:03:39 +02002277# If no background operation is active on this device, DeviceNotActive
Stefan Hajnoczi370521a2012-01-18 14:40:48 +00002278#
2279# Since: 1.1
2280##
Paolo Bonzini6e37fb82012-09-28 17:22:51 +02002281{ 'command': 'block-job-cancel', 'data': { 'device': 'str', '*force': 'bool' } }
2282
2283##
2284# @block-job-pause:
2285#
2286# Pause an active background block operation.
2287#
2288# This command returns immediately after marking the active background block
2289# operation for pausing. It is an error to call this command if no
2290# operation is in progress. Pausing an already paused job has no cumulative
2291# effect; a single block-job-resume command will resume the job.
2292#
2293# The operation will pause as soon as possible. No event is emitted when
2294# the operation is actually paused. Cancelling a paused job automatically
2295# resumes it.
2296#
2297# @device: the device name
2298#
2299# Returns: Nothing on success
2300# If no background operation is active on this device, DeviceNotActive
2301#
2302# Since: 1.3
2303##
2304{ 'command': 'block-job-pause', 'data': { 'device': 'str' } }
2305
2306##
2307# @block-job-resume:
2308#
2309# Resume an active background block operation.
2310#
2311# This command returns immediately after resuming a paused background block
2312# operation. It is an error to call this command if no operation is in
2313# progress. Resuming an already running job is not an error.
2314#
Paolo Bonzini32c81a42012-09-28 17:22:58 +02002315# This command also clears the error status of the job.
2316#
Paolo Bonzini6e37fb82012-09-28 17:22:51 +02002317# @device: the device name
2318#
2319# Returns: Nothing on success
2320# If no background operation is active on this device, DeviceNotActive
2321#
2322# Since: 1.3
2323##
2324{ 'command': 'block-job-resume', 'data': { 'device': 'str' } }
Anthony Liguori5eeee3f2011-12-22 14:40:54 -06002325
2326##
Paolo Bonziniaeae8832012-10-18 16:49:21 +02002327# @block-job-complete:
2328#
2329# Manually trigger completion of an active background block operation. This
2330# is supported for drive mirroring, where it also switches the device to
Paolo Bonzinia66a2a32012-07-23 15:15:47 +02002331# write to the target path only. The ability to complete is signaled with
2332# a BLOCK_JOB_READY event.
Paolo Bonziniaeae8832012-10-18 16:49:21 +02002333#
2334# This command completes an active background block operation synchronously.
2335# The ordering of this command's return with the BLOCK_JOB_COMPLETED event
2336# is not defined. Note that if an I/O error occurs during the processing of
2337# this command: 1) the command itself will fail; 2) the error will be processed
2338# according to the rerror/werror arguments that were specified when starting
2339# the operation.
2340#
2341# A cancelled or paused job cannot be completed.
2342#
2343# @device: the device name
2344#
2345# Returns: Nothing on success
2346# If no background operation is active on this device, DeviceNotActive
2347#
2348# Since: 1.3
2349##
2350{ 'command': 'block-job-complete', 'data': { 'device': 'str' } }
2351
2352##
Anthony Liguori5eeee3f2011-12-22 14:40:54 -06002353# @ObjectTypeInfo:
2354#
2355# This structure describes a search result from @qom-list-types
2356#
2357# @name: the type name found in the search
2358#
2359# Since: 1.1
2360#
2361# Notes: This command is experimental and may change syntax in future releases.
2362##
2363{ 'type': 'ObjectTypeInfo',
2364 'data': { 'name': 'str' } }
2365
2366##
2367# @qom-list-types:
2368#
2369# This command will return a list of types given search parameters
2370#
2371# @implements: if specified, only return types that implement this type name
2372#
2373# @abstract: if true, include abstract types in the results
2374#
2375# Returns: a list of @ObjectTypeInfo or an empty list if no results are found
2376#
2377# Since: 1.1
Anthony Liguori5eeee3f2011-12-22 14:40:54 -06002378##
2379{ 'command': 'qom-list-types',
2380 'data': { '*implements': 'str', '*abstract': 'bool' },
2381 'returns': [ 'ObjectTypeInfo' ] }
Luiz Capitulinoe1c37d02011-12-05 14:48:01 -02002382
2383##
Anthony Liguori1daa31b2012-08-10 11:04:09 -05002384# @DevicePropertyInfo:
2385#
2386# Information about device properties.
2387#
2388# @name: the name of the property
2389# @type: the typename of the property
2390#
2391# Since: 1.2
2392##
2393{ 'type': 'DevicePropertyInfo',
2394 'data': { 'name': 'str', 'type': 'str' } }
2395
2396##
2397# @device-list-properties:
2398#
2399# List properties associated with a device.
2400#
2401# @typename: the type name of a device
2402#
2403# Returns: a list of DevicePropertyInfo describing a devices properties
2404#
2405# Since: 1.2
2406##
2407{ 'command': 'device-list-properties',
2408 'data': { 'typename': 'str'},
2409 'returns': [ 'DevicePropertyInfo' ] }
2410
2411##
Luiz Capitulinoe1c37d02011-12-05 14:48:01 -02002412# @migrate
2413#
2414# Migrates the current running guest to another Virtual Machine.
2415#
2416# @uri: the Uniform Resource Identifier of the destination VM
2417#
2418# @blk: #optional do block migration (full disk copy)
2419#
2420# @inc: #optional incremental disk copy migration
2421#
2422# @detach: this argument exists only for compatibility reasons and
2423# is ignored by QEMU
2424#
2425# Returns: nothing on success
2426#
2427# Since: 0.14.0
2428##
2429{ 'command': 'migrate',
2430 'data': {'uri': 'str', '*blk': 'bool', '*inc': 'bool', '*detach': 'bool' } }
Anthony Liguori33cf6292012-03-19 13:39:42 -05002431
Stefano Stabellinia7ae8352012-01-25 12:24:51 +00002432# @xen-save-devices-state:
2433#
2434# Save the state of all devices to file. The RAM and the block devices
2435# of the VM are not saved by this command.
2436#
2437# @filename: the file to save the state of the devices to as binary
2438# data. See xen-save-devices-state.txt for a description of the binary
2439# format.
2440#
2441# Returns: Nothing on success
Stefano Stabellinia7ae8352012-01-25 12:24:51 +00002442#
2443# Since: 1.1
2444##
2445{ 'command': 'xen-save-devices-state', 'data': {'filename': 'str'} }
Luiz Capitulinoa15fef22012-03-29 12:38:50 -03002446
2447##
Anthony PERARD39f42432012-10-03 13:48:19 +00002448# @xen-set-global-dirty-log
2449#
2450# Enable or disable the global dirty log mode.
2451#
2452# @enable: true to enable, false to disable.
2453#
2454# Returns: nothing
2455#
2456# Since: 1.3
2457##
2458{ 'command': 'xen-set-global-dirty-log', 'data': { 'enable': 'bool' } }
2459
2460##
Luiz Capitulinoa15fef22012-03-29 12:38:50 -03002461# @device_del:
2462#
2463# Remove a device from a guest
2464#
2465# @id: the name of the device
2466#
2467# Returns: Nothing on success
2468# If @id is not a valid device, DeviceNotFound
Luiz Capitulinoa15fef22012-03-29 12:38:50 -03002469#
2470# Notes: When this command completes, the device may not be removed from the
2471# guest. Hot removal is an operation that requires guest cooperation.
2472# This command merely requests that the guest begin the hot removal
Michael S. Tsirkin0402a5d2013-03-06 14:58:59 +02002473# process. Completion of the device removal process is signaled with a
2474# DEVICE_DELETED event. Guest reset will automatically complete removal
2475# for all devices.
Luiz Capitulinoa15fef22012-03-29 12:38:50 -03002476#
2477# Since: 0.14.0
2478##
2479{ 'command': 'device_del', 'data': {'id': 'str'} }
Wen Congyang783e9b42012-05-07 12:10:47 +08002480
2481##
2482# @dump-guest-memory
2483#
2484# Dump guest's memory to vmcore. It is a synchronous operation that can take
2485# very long depending on the amount of guest memory. This command is only
Luiz Capitulinof5b0d932012-06-28 11:59:15 -03002486# supported on i386 and x86_64.
Wen Congyang783e9b42012-05-07 12:10:47 +08002487#
Luiz Capitulinof5b0d932012-06-28 11:59:15 -03002488# @paging: if true, do paging to get guest's memory mapping. This allows
Luiz Capitulinod6911802012-09-21 13:10:58 -03002489# using gdb to process the core file.
Luiz Capitulinof5b0d932012-06-28 11:59:15 -03002490#
Luiz Capitulinod6911802012-09-21 13:10:58 -03002491# IMPORTANT: this option can make QEMU allocate several gigabytes
2492# of RAM. This can happen for a large guest, or a
2493# malicious guest pretending to be large.
2494#
2495# Also, paging=true has the following limitations:
2496#
2497# 1. The guest may be in a catastrophic state or can have corrupted
2498# memory, which cannot be trusted
2499# 2. The guest can be in real-mode even if paging is enabled. For
2500# example, the guest uses ACPI to sleep, and ACPI sleep state
2501# goes in real-mode
Luiz Capitulinof5b0d932012-06-28 11:59:15 -03002502#
Wen Congyang783e9b42012-05-07 12:10:47 +08002503# @protocol: the filename or file descriptor of the vmcore. The supported
Luiz Capitulinod6911802012-09-21 13:10:58 -03002504# protocols are:
Luiz Capitulinof5b0d932012-06-28 11:59:15 -03002505#
Luiz Capitulinod6911802012-09-21 13:10:58 -03002506# 1. file: the protocol starts with "file:", and the following
2507# string is the file's path.
2508# 2. fd: the protocol starts with "fd:", and the following string
2509# is the fd's name.
Luiz Capitulinof5b0d932012-06-28 11:59:15 -03002510#
Wen Congyang783e9b42012-05-07 12:10:47 +08002511# @begin: #optional if specified, the starting physical address.
Luiz Capitulinof5b0d932012-06-28 11:59:15 -03002512#
Wen Congyang783e9b42012-05-07 12:10:47 +08002513# @length: #optional if specified, the memory size, in bytes. If you don't
Luiz Capitulinod6911802012-09-21 13:10:58 -03002514# want to dump all guest's memory, please specify the start @begin
2515# and @length
Wen Congyang783e9b42012-05-07 12:10:47 +08002516#
2517# Returns: nothing on success
Wen Congyang783e9b42012-05-07 12:10:47 +08002518#
2519# Since: 1.2
2520##
2521{ 'command': 'dump-guest-memory',
2522 'data': { 'paging': 'bool', 'protocol': 'str', '*begin': 'int',
2523 '*length': 'int' } }
Luiz Capitulinod6911802012-09-21 13:10:58 -03002524
Luiz Capitulino928059a2012-04-18 17:34:15 -03002525##
2526# @netdev_add:
2527#
2528# Add a network backend.
2529#
2530# @type: the type of network backend. Current valid values are 'user', 'tap',
2531# 'vde', 'socket', 'dump' and 'bridge'
2532#
2533# @id: the name of the new network backend
2534#
2535# @props: #optional a list of properties to be passed to the backend in
2536# the format 'name=value', like 'ifname=tap0,script=no'
2537#
2538# Notes: The semantics of @props is not well defined. Future commands will be
2539# introduced that provide stronger typing for backend creation.
2540#
2541# Since: 0.14.0
2542#
2543# Returns: Nothing on success
2544# If @type is not a valid network backend, DeviceNotFound
Luiz Capitulino928059a2012-04-18 17:34:15 -03002545##
2546{ 'command': 'netdev_add',
2547 'data': {'type': 'str', 'id': 'str', '*props': '**'},
2548 'gen': 'no' }
Luiz Capitulino5f964152012-04-16 14:36:32 -03002549
2550##
2551# @netdev_del:
2552#
2553# Remove a network backend.
2554#
2555# @id: the name of the network backend to remove
2556#
2557# Returns: Nothing on success
2558# If @id is not a valid network backend, DeviceNotFound
2559#
2560# Since: 0.14.0
2561##
2562{ 'command': 'netdev_del', 'data': {'id': 'str'} }
Corey Bryant208c9d12012-06-22 14:36:09 -04002563
2564##
Laszlo Ersek14aa0c22012-07-17 16:17:11 +02002565# @NetdevNoneOptions
2566#
2567# Use it alone to have zero network devices.
2568#
2569# Since 1.2
2570##
2571{ 'type': 'NetdevNoneOptions',
2572 'data': { } }
2573
2574##
2575# @NetLegacyNicOptions
2576#
2577# Create a new Network Interface Card.
2578#
2579# @netdev: #optional id of -netdev to connect to
2580#
2581# @macaddr: #optional MAC address
2582#
2583# @model: #optional device model (e1000, rtl8139, virtio etc.)
2584#
2585# @addr: #optional PCI device address
2586#
2587# @vectors: #optional number of MSI-x vectors, 0 to disable MSI-X
2588#
2589# Since 1.2
2590##
2591{ 'type': 'NetLegacyNicOptions',
2592 'data': {
2593 '*netdev': 'str',
2594 '*macaddr': 'str',
2595 '*model': 'str',
2596 '*addr': 'str',
2597 '*vectors': 'uint32' } }
2598
2599##
2600# @String
2601#
2602# A fat type wrapping 'str', to be embedded in lists.
2603#
2604# Since 1.2
2605##
2606{ 'type': 'String',
2607 'data': {
2608 'str': 'str' } }
2609
2610##
2611# @NetdevUserOptions
2612#
2613# Use the user mode network stack which requires no administrator privilege to
2614# run.
2615#
2616# @hostname: #optional client hostname reported by the builtin DHCP server
2617#
2618# @restrict: #optional isolate the guest from the host
2619#
2620# @ip: #optional legacy parameter, use net= instead
2621#
2622# @net: #optional IP address and optional netmask
2623#
2624# @host: #optional guest-visible address of the host
2625#
2626# @tftp: #optional root directory of the built-in TFTP server
2627#
2628# @bootfile: #optional BOOTP filename, for use with tftp=
2629#
2630# @dhcpstart: #optional the first of the 16 IPs the built-in DHCP server can
2631# assign
2632#
2633# @dns: #optional guest-visible address of the virtual nameserver
2634#
Klaus Stengel63d29602012-10-27 19:53:39 +02002635# @dnssearch: #optional list of DNS suffixes to search, passed as DHCP option
2636# to the guest
2637#
Laszlo Ersek14aa0c22012-07-17 16:17:11 +02002638# @smb: #optional root directory of the built-in SMB server
2639#
2640# @smbserver: #optional IP address of the built-in SMB server
2641#
2642# @hostfwd: #optional redirect incoming TCP or UDP host connections to guest
2643# endpoints
2644#
2645# @guestfwd: #optional forward guest TCP connections
2646#
2647# Since 1.2
2648##
2649{ 'type': 'NetdevUserOptions',
2650 'data': {
2651 '*hostname': 'str',
2652 '*restrict': 'bool',
2653 '*ip': 'str',
2654 '*net': 'str',
2655 '*host': 'str',
2656 '*tftp': 'str',
2657 '*bootfile': 'str',
2658 '*dhcpstart': 'str',
2659 '*dns': 'str',
Klaus Stengel63d29602012-10-27 19:53:39 +02002660 '*dnssearch': ['String'],
Laszlo Ersek14aa0c22012-07-17 16:17:11 +02002661 '*smb': 'str',
2662 '*smbserver': 'str',
2663 '*hostfwd': ['String'],
2664 '*guestfwd': ['String'] } }
2665
2666##
2667# @NetdevTapOptions
2668#
2669# Connect the host TAP network interface name to the VLAN.
2670#
2671# @ifname: #optional interface name
2672#
2673# @fd: #optional file descriptor of an already opened tap
2674#
Jason Wang2ca81ba2013-02-20 18:04:01 +08002675# @fds: #optional multiple file descriptors of already opened multiqueue capable
2676# tap
2677#
Laszlo Ersek14aa0c22012-07-17 16:17:11 +02002678# @script: #optional script to initialize the interface
2679#
2680# @downscript: #optional script to shut down the interface
2681#
2682# @helper: #optional command to execute to configure bridge
2683#
2684# @sndbuf: #optional send buffer limit. Understands [TGMKkb] suffixes.
2685#
2686# @vnet_hdr: #optional enable the IFF_VNET_HDR flag on the tap interface
2687#
2688# @vhost: #optional enable vhost-net network accelerator
2689#
2690# @vhostfd: #optional file descriptor of an already opened vhost net device
2691#
Jason Wang2ca81ba2013-02-20 18:04:01 +08002692# @vhostfds: #optional file descriptors of multiple already opened vhost net
2693# devices
2694#
Laszlo Ersek14aa0c22012-07-17 16:17:11 +02002695# @vhostforce: #optional vhost on for non-MSIX virtio guests
2696#
Jason Wangec396012013-02-22 22:57:52 +08002697# @queues: #optional number of queues to be created for multiqueue capable tap
2698#
Laszlo Ersek14aa0c22012-07-17 16:17:11 +02002699# Since 1.2
2700##
2701{ 'type': 'NetdevTapOptions',
2702 'data': {
2703 '*ifname': 'str',
2704 '*fd': 'str',
Jason Wang264986e2013-01-30 19:12:34 +08002705 '*fds': 'str',
Laszlo Ersek14aa0c22012-07-17 16:17:11 +02002706 '*script': 'str',
2707 '*downscript': 'str',
2708 '*helper': 'str',
2709 '*sndbuf': 'size',
2710 '*vnet_hdr': 'bool',
2711 '*vhost': 'bool',
2712 '*vhostfd': 'str',
Jason Wang264986e2013-01-30 19:12:34 +08002713 '*vhostfds': 'str',
2714 '*vhostforce': 'bool',
2715 '*queues': 'uint32'} }
Laszlo Ersek14aa0c22012-07-17 16:17:11 +02002716
2717##
2718# @NetdevSocketOptions
2719#
2720# Connect the VLAN to a remote VLAN in another QEMU virtual machine using a TCP
2721# socket connection.
2722#
2723# @fd: #optional file descriptor of an already opened socket
2724#
2725# @listen: #optional port number, and optional hostname, to listen on
2726#
2727# @connect: #optional port number, and optional hostname, to connect to
2728#
2729# @mcast: #optional UDP multicast address and port number
2730#
2731# @localaddr: #optional source address and port for multicast and udp packets
2732#
2733# @udp: #optional UDP unicast address and port number
2734#
2735# Since 1.2
2736##
2737{ 'type': 'NetdevSocketOptions',
2738 'data': {
2739 '*fd': 'str',
2740 '*listen': 'str',
2741 '*connect': 'str',
2742 '*mcast': 'str',
2743 '*localaddr': 'str',
2744 '*udp': 'str' } }
2745
2746##
2747# @NetdevVdeOptions
2748#
2749# Connect the VLAN to a vde switch running on the host.
2750#
2751# @sock: #optional socket path
2752#
2753# @port: #optional port number
2754#
2755# @group: #optional group owner of socket
2756#
2757# @mode: #optional permissions for socket
2758#
2759# Since 1.2
2760##
2761{ 'type': 'NetdevVdeOptions',
2762 'data': {
2763 '*sock': 'str',
2764 '*port': 'uint16',
2765 '*group': 'str',
2766 '*mode': 'uint16' } }
2767
2768##
2769# @NetdevDumpOptions
2770#
2771# Dump VLAN network traffic to a file.
2772#
2773# @len: #optional per-packet size limit (64k default). Understands [TGMKkb]
2774# suffixes.
2775#
2776# @file: #optional dump file path (default is qemu-vlan0.pcap)
2777#
2778# Since 1.2
2779##
2780{ 'type': 'NetdevDumpOptions',
2781 'data': {
2782 '*len': 'size',
2783 '*file': 'str' } }
2784
2785##
2786# @NetdevBridgeOptions
2787#
2788# Connect a host TAP network interface to a host bridge device.
2789#
2790# @br: #optional bridge name
2791#
2792# @helper: #optional command to execute to configure bridge
2793#
2794# Since 1.2
2795##
2796{ 'type': 'NetdevBridgeOptions',
2797 'data': {
2798 '*br': 'str',
2799 '*helper': 'str' } }
2800
2801##
Stefan Hajnoczif6c874e2012-07-24 16:35:04 +01002802# @NetdevHubPortOptions
2803#
2804# Connect two or more net clients through a software hub.
2805#
2806# @hubid: hub identifier number
2807#
2808# Since 1.2
2809##
2810{ 'type': 'NetdevHubPortOptions',
2811 'data': {
2812 'hubid': 'int32' } }
2813
2814##
Laszlo Ersek14aa0c22012-07-17 16:17:11 +02002815# @NetClientOptions
2816#
2817# A discriminated record of network device traits.
2818#
2819# Since 1.2
2820##
2821{ 'union': 'NetClientOptions',
2822 'data': {
Stefan Hajnoczif6c874e2012-07-24 16:35:04 +01002823 'none': 'NetdevNoneOptions',
2824 'nic': 'NetLegacyNicOptions',
2825 'user': 'NetdevUserOptions',
2826 'tap': 'NetdevTapOptions',
2827 'socket': 'NetdevSocketOptions',
2828 'vde': 'NetdevVdeOptions',
2829 'dump': 'NetdevDumpOptions',
2830 'bridge': 'NetdevBridgeOptions',
2831 'hubport': 'NetdevHubPortOptions' } }
Laszlo Ersek14aa0c22012-07-17 16:17:11 +02002832
2833##
2834# @NetLegacy
2835#
2836# Captures the configuration of a network device; legacy.
2837#
2838# @vlan: #optional vlan number
2839#
2840# @id: #optional identifier for monitor commands
2841#
2842# @name: #optional identifier for monitor commands, ignored if @id is present
2843#
2844# @opts: device type specific properties (legacy)
2845#
2846# Since 1.2
2847##
2848{ 'type': 'NetLegacy',
2849 'data': {
2850 '*vlan': 'int32',
2851 '*id': 'str',
2852 '*name': 'str',
2853 'opts': 'NetClientOptions' } }
2854
2855##
2856# @Netdev
2857#
2858# Captures the configuration of a network device.
2859#
2860# @id: identifier for monitor commands.
2861#
2862# @opts: device type specific properties
2863#
2864# Since 1.2
2865##
2866{ 'type': 'Netdev',
2867 'data': {
2868 'id': 'str',
2869 'opts': 'NetClientOptions' } }
2870
2871##
Paolo Bonzini5be8c752012-09-19 14:03:35 +02002872# @InetSocketAddress
2873#
2874# Captures a socket address or address range in the Internet namespace.
2875#
2876# @host: host part of the address
2877#
2878# @port: port part of the address, or lowest port if @to is present
2879#
2880# @to: highest port to try
2881#
2882# @ipv4: whether to accept IPv4 addresses, default try both IPv4 and IPv6
2883# #optional
2884#
2885# @ipv6: whether to accept IPv6 addresses, default try both IPv4 and IPv6
2886# #optional
2887#
2888# Since 1.3
2889##
2890{ 'type': 'InetSocketAddress',
2891 'data': {
2892 'host': 'str',
2893 'port': 'str',
2894 '*to': 'uint16',
2895 '*ipv4': 'bool',
2896 '*ipv6': 'bool' } }
2897
2898##
2899# @UnixSocketAddress
2900#
2901# Captures a socket address in the local ("Unix socket") namespace.
2902#
2903# @path: filesystem path to use
2904#
2905# Since 1.3
2906##
2907{ 'type': 'UnixSocketAddress',
2908 'data': {
2909 'path': 'str' } }
2910
2911##
2912# @SocketAddress
2913#
2914# Captures the address of a socket, which could also be a named file descriptor
2915#
2916# Since 1.3
2917##
2918{ 'union': 'SocketAddress',
2919 'data': {
2920 'inet': 'InetSocketAddress',
2921 'unix': 'UnixSocketAddress',
2922 'fd': 'String' } }
2923
2924##
Corey Bryant208c9d12012-06-22 14:36:09 -04002925# @getfd:
2926#
2927# Receive a file descriptor via SCM rights and assign it a name
2928#
2929# @fdname: file descriptor name
2930#
2931# Returns: Nothing on success
Corey Bryant208c9d12012-06-22 14:36:09 -04002932#
2933# Since: 0.14.0
2934#
2935# Notes: If @fdname already exists, the file descriptor assigned to
2936# it will be closed and replaced by the received file
2937# descriptor.
2938# The 'closefd' command can be used to explicitly close the
2939# file descriptor when it is no longer needed.
2940##
2941{ 'command': 'getfd', 'data': {'fdname': 'str'} }
2942
2943##
2944# @closefd:
2945#
2946# Close a file descriptor previously passed via SCM rights
2947#
2948# @fdname: file descriptor name
2949#
2950# Returns: Nothing on success
Corey Bryant208c9d12012-06-22 14:36:09 -04002951#
2952# Since: 0.14.0
2953##
2954{ 'command': 'closefd', 'data': {'fdname': 'str'} }
Anthony Liguori01d3c802012-08-10 11:04:11 -05002955
2956##
2957# @MachineInfo:
2958#
2959# Information describing a machine.
2960#
2961# @name: the name of the machine
2962#
2963# @alias: #optional an alias for the machine name
2964#
2965# @default: #optional whether the machine is default
2966#
Michal Novotnyc72e7682013-04-08 18:21:02 +02002967# @cpu-max: maximum number of CPUs supported by the machine type
2968# (since 1.5.0)
2969#
Anthony Liguori01d3c802012-08-10 11:04:11 -05002970# Since: 1.2.0
2971##
2972{ 'type': 'MachineInfo',
2973 'data': { 'name': 'str', '*alias': 'str',
Michal Novotnyc72e7682013-04-08 18:21:02 +02002974 '*is-default': 'bool', 'cpu-max': 'int' } }
Anthony Liguori01d3c802012-08-10 11:04:11 -05002975
2976##
2977# @query-machines:
2978#
2979# Return a list of supported machines
2980#
2981# Returns: a list of MachineInfo
2982#
2983# Since: 1.2.0
2984##
2985{ 'command': 'query-machines', 'returns': ['MachineInfo'] }
Anthony Liguorie4e31c62012-08-10 11:04:13 -05002986
2987##
2988# @CpuDefinitionInfo:
2989#
2990# Virtual CPU definition.
2991#
2992# @name: the name of the CPU definition
2993#
2994# Since: 1.2.0
2995##
2996{ 'type': 'CpuDefinitionInfo',
2997 'data': { 'name': 'str' } }
2998
2999##
3000# @query-cpu-definitions:
3001#
3002# Return a list of supported virtual CPU definitions
3003#
3004# Returns: a list of CpuDefInfo
3005#
3006# Since: 1.2.0
3007##
3008{ 'command': 'query-cpu-definitions', 'returns': ['CpuDefinitionInfo'] }
Corey Bryantba1c0482012-08-14 16:43:43 -04003009
3010# @AddfdInfo:
3011#
3012# Information about a file descriptor that was added to an fd set.
3013#
3014# @fdset-id: The ID of the fd set that @fd was added to.
3015#
3016# @fd: The file descriptor that was received via SCM rights and
3017# added to the fd set.
3018#
3019# Since: 1.2.0
3020##
3021{ 'type': 'AddfdInfo', 'data': {'fdset-id': 'int', 'fd': 'int'} }
3022
3023##
3024# @add-fd:
3025#
3026# Add a file descriptor, that was passed via SCM rights, to an fd set.
3027#
3028# @fdset-id: #optional The ID of the fd set to add the file descriptor to.
3029#
3030# @opaque: #optional A free-form string that can be used to describe the fd.
3031#
3032# Returns: @AddfdInfo on success
3033# If file descriptor was not received, FdNotSupplied
Corey Bryant9ac54af2012-10-18 15:19:31 -04003034# If @fdset-id is a negative value, InvalidParameterValue
Corey Bryantba1c0482012-08-14 16:43:43 -04003035#
3036# Notes: The list of fd sets is shared by all monitor connections.
3037#
3038# If @fdset-id is not specified, a new fd set will be created.
3039#
3040# Since: 1.2.0
3041##
3042{ 'command': 'add-fd', 'data': {'*fdset-id': 'int', '*opaque': 'str'},
3043 'returns': 'AddfdInfo' }
3044
3045##
3046# @remove-fd:
3047#
3048# Remove a file descriptor from an fd set.
3049#
3050# @fdset-id: The ID of the fd set that the file descriptor belongs to.
3051#
3052# @fd: #optional The file descriptor that is to be removed.
3053#
3054# Returns: Nothing on success
3055# If @fdset-id or @fd is not found, FdNotFound
3056#
3057# Since: 1.2.0
3058#
3059# Notes: The list of fd sets is shared by all monitor connections.
3060#
3061# If @fd is not specified, all file descriptors in @fdset-id
3062# will be removed.
3063##
3064{ 'command': 'remove-fd', 'data': {'fdset-id': 'int', '*fd': 'int'} }
3065
3066##
3067# @FdsetFdInfo:
3068#
3069# Information about a file descriptor that belongs to an fd set.
3070#
3071# @fd: The file descriptor value.
3072#
3073# @opaque: #optional A free-form string that can be used to describe the fd.
3074#
3075# Since: 1.2.0
3076##
3077{ 'type': 'FdsetFdInfo',
3078 'data': {'fd': 'int', '*opaque': 'str'} }
3079
3080##
3081# @FdsetInfo:
3082#
3083# Information about an fd set.
3084#
3085# @fdset-id: The ID of the fd set.
3086#
3087# @fds: A list of file descriptors that belong to this fd set.
3088#
3089# Since: 1.2.0
3090##
3091{ 'type': 'FdsetInfo',
3092 'data': {'fdset-id': 'int', 'fds': ['FdsetFdInfo']} }
3093
3094##
3095# @query-fdsets:
3096#
3097# Return information describing all fd sets.
3098#
3099# Returns: A list of @FdsetInfo
3100#
3101# Since: 1.2.0
3102#
3103# Note: The list of fd sets is shared by all monitor connections.
3104#
3105##
3106{ 'command': 'query-fdsets', 'returns': ['FdsetInfo'] }
Daniel P. Berrange99afc912012-08-20 15:31:38 +01003107
3108##
Daniel P. Berrange99afc912012-08-20 15:31:38 +01003109# @TargetInfo:
3110#
3111# Information describing the QEMU target.
3112#
3113# @arch: the target architecture (eg "x86_64", "i386", etc)
3114#
3115# Since: 1.2.0
3116##
3117{ 'type': 'TargetInfo',
Paolo Bonzinic02a9552013-06-04 14:45:28 +02003118 'data': { 'arch': 'str' } }
Daniel P. Berrange99afc912012-08-20 15:31:38 +01003119
3120##
3121# @query-target:
3122#
3123# Return information about the target for this QEMU
3124#
3125# Returns: TargetInfo
3126#
3127# Since: 1.2.0
3128##
3129{ 'command': 'query-target', 'returns': 'TargetInfo' }
Amos Kong411656f2012-08-31 10:56:24 +08003130
3131##
3132# @QKeyCode:
3133#
3134# An enumeration of key name.
3135#
3136# This is used by the send-key command.
3137#
3138# Since: 1.3.0
3139##
3140{ 'enum': 'QKeyCode',
3141 'data': [ 'shift', 'shift_r', 'alt', 'alt_r', 'altgr', 'altgr_r', 'ctrl',
3142 'ctrl_r', 'menu', 'esc', '1', '2', '3', '4', '5', '6', '7', '8',
3143 '9', '0', 'minus', 'equal', 'backspace', 'tab', 'q', 'w', 'e',
3144 'r', 't', 'y', 'u', 'i', 'o', 'p', 'bracket_left', 'bracket_right',
3145 'ret', 'a', 's', 'd', 'f', 'g', 'h', 'j', 'k', 'l', 'semicolon',
3146 'apostrophe', 'grave_accent', 'backslash', 'z', 'x', 'c', 'v', 'b',
3147 'n', 'm', 'comma', 'dot', 'slash', 'asterisk', 'spc', 'caps_lock',
3148 'f1', 'f2', 'f3', 'f4', 'f5', 'f6', 'f7', 'f8', 'f9', 'f10',
3149 'num_lock', 'scroll_lock', 'kp_divide', 'kp_multiply',
3150 'kp_subtract', 'kp_add', 'kp_enter', 'kp_decimal', 'sysrq', 'kp_0',
3151 'kp_1', 'kp_2', 'kp_3', 'kp_4', 'kp_5', 'kp_6', 'kp_7', 'kp_8',
3152 'kp_9', 'less', 'f11', 'f12', 'print', 'home', 'pgup', 'pgdn', 'end',
3153 'left', 'up', 'down', 'right', 'insert', 'delete', 'stop', 'again',
3154 'props', 'undo', 'front', 'copy', 'open', 'paste', 'find', 'cut',
3155 'lf', 'help', 'meta_l', 'meta_r', 'compose' ] }
Amos Konge4c8f002012-08-31 10:56:26 +08003156
3157##
Luiz Capitulino9f328972012-09-20 14:19:47 -03003158# @KeyValue
3159#
3160# Represents a keyboard key.
3161#
3162# Since: 1.3.0
3163##
3164{ 'union': 'KeyValue',
3165 'data': {
3166 'number': 'int',
3167 'qcode': 'QKeyCode' } }
3168
3169##
Amos Konge4c8f002012-08-31 10:56:26 +08003170# @send-key:
3171#
3172# Send keys to guest.
3173#
Luiz Capitulino9f328972012-09-20 14:19:47 -03003174# @keys: An array of @KeyValue elements. All @KeyValues in this array are
3175# simultaneously sent to the guest. A @KeyValue.number value is sent
3176# directly to the guest, while @KeyValue.qcode must be a valid
3177# @QKeyCode value
Amos Konge4c8f002012-08-31 10:56:26 +08003178#
3179# @hold-time: #optional time to delay key up events, milliseconds. Defaults
3180# to 100
3181#
3182# Returns: Nothing on success
3183# If key is unknown or redundant, InvalidParameter
3184#
3185# Since: 1.3.0
3186#
3187##
3188{ 'command': 'send-key',
Luiz Capitulino9f328972012-09-20 14:19:47 -03003189 'data': { 'keys': ['KeyValue'], '*hold-time': 'int' } }
Luiz Capitulinoad39cf62012-05-24 13:48:23 -03003190
3191##
3192# @screendump:
3193#
3194# Write a PPM of the VGA screen to a file.
3195#
3196# @filename: the path of a new PPM file to store the image
3197#
3198# Returns: Nothing on success
3199#
3200# Since: 0.14.0
3201##
3202{ 'command': 'screendump', 'data': {'filename': 'str'} }
Paolo Bonzini6dd844d2012-08-22 16:43:07 +02003203
3204##
3205# @nbd-server-start:
3206#
3207# Start an NBD server listening on the given host and port. Block
3208# devices can then be exported using @nbd-server-add. The NBD
3209# server will present them as named exports; for example, another
3210# QEMU instance could refer to them as "nbd:HOST:PORT:exportname=NAME".
3211#
3212# @addr: Address on which to listen.
3213#
3214# Returns: error if the server is already running.
3215#
3216# Since: 1.3.0
3217##
3218{ 'command': 'nbd-server-start',
3219 'data': { 'addr': 'SocketAddress' } }
3220
3221##
3222# @nbd-server-add:
3223#
3224# Export a device to QEMU's embedded NBD server.
3225#
3226# @device: Block device to be exported
3227#
3228# @writable: Whether clients should be able to write to the device via the
3229# NBD connection (default false). #optional
3230#
3231# Returns: error if the device is already marked for export.
3232#
3233# Since: 1.3.0
3234##
3235{ 'command': 'nbd-server-add', 'data': {'device': 'str', '*writable': 'bool'} }
3236
3237##
3238# @nbd-server-stop:
3239#
3240# Stop QEMU's embedded NBD server, and unregister all devices previously
3241# added via @nbd-server-add.
3242#
3243# Since: 1.3.0
3244##
3245{ 'command': 'nbd-server-stop' }
Gerd Hoffmannf1a1a352012-12-19 10:33:56 +01003246
3247##
Gerd Hoffmannffbdbe52012-12-19 13:13:57 +01003248# @ChardevFile:
3249#
3250# Configuration info for file chardevs.
3251#
3252# @in: #optional The name of the input file
3253# @out: The name of the output file
3254#
3255# Since: 1.4
3256##
3257{ 'type': 'ChardevFile', 'data': { '*in' : 'str',
3258 'out' : 'str' } }
3259
3260##
Markus Armbrusterd36b2b92013-02-13 15:54:16 +01003261# @ChardevHostdev:
Gerd Hoffmannd59044e2012-12-19 13:50:29 +01003262#
Gerd Hoffmann548cbb32013-02-25 11:50:55 +01003263# Configuration info for device and pipe chardevs.
Gerd Hoffmannd59044e2012-12-19 13:50:29 +01003264#
3265# @device: The name of the special file for the device,
3266# i.e. /dev/ttyS0 on Unix or COM1: on Windows
3267# @type: What kind of device this is.
3268#
3269# Since: 1.4
3270##
Markus Armbrusterd36b2b92013-02-13 15:54:16 +01003271{ 'type': 'ChardevHostdev', 'data': { 'device' : 'str' } }
Gerd Hoffmannd59044e2012-12-19 13:50:29 +01003272
3273##
Gerd Hoffmannf6bd5d62012-12-20 13:53:12 +01003274# @ChardevSocket:
3275#
Gerd Hoffmann3ecc0592013-02-27 14:10:47 +01003276# Configuration info for (stream) socket chardevs.
Gerd Hoffmannf6bd5d62012-12-20 13:53:12 +01003277#
3278# @addr: socket address to listen on (server=true)
3279# or connect to (server=false)
3280# @server: #optional create server socket (default: true)
Gerd Hoffmannef993ba2013-06-24 08:39:50 +02003281# @wait: #optional wait for incoming connection on server
3282# sockets (default: false).
Gerd Hoffmannf6bd5d62012-12-20 13:53:12 +01003283# @nodelay: #optional set TCP_NODELAY socket option (default: false)
Gerd Hoffmannef993ba2013-06-24 08:39:50 +02003284# @telnet: #optional enable telnet protocol on server
3285# sockets (default: false)
Gerd Hoffmannf6bd5d62012-12-20 13:53:12 +01003286#
3287# Since: 1.4
3288##
3289{ 'type': 'ChardevSocket', 'data': { 'addr' : 'SocketAddress',
3290 '*server' : 'bool',
3291 '*wait' : 'bool',
3292 '*nodelay' : 'bool',
3293 '*telnet' : 'bool' } }
3294
3295##
Lei Li08d0ab32013-05-20 14:51:03 +08003296# @ChardevUdp:
Gerd Hoffmann3ecc0592013-02-27 14:10:47 +01003297#
3298# Configuration info for datagram socket chardevs.
3299#
3300# @remote: remote address
3301# @local: #optional local address
3302#
3303# Since: 1.5
3304##
Lei Li08d0ab32013-05-20 14:51:03 +08003305{ 'type': 'ChardevUdp', 'data': { 'remote' : 'SocketAddress',
3306 '*local' : 'SocketAddress' } }
Gerd Hoffmann3ecc0592013-02-27 14:10:47 +01003307
3308##
Gerd Hoffmannedb2fb32013-02-21 16:16:42 +01003309# @ChardevMux:
3310#
3311# Configuration info for mux chardevs.
3312#
3313# @chardev: name of the base chardev.
3314#
3315# Since: 1.5
3316##
3317{ 'type': 'ChardevMux', 'data': { 'chardev' : 'str' } }
3318
3319##
Gerd Hoffmann7c358032013-02-21 12:34:58 +01003320# @ChardevStdio:
3321#
3322# Configuration info for stdio chardevs.
3323#
3324# @signal: #optional Allow signals (such as SIGINT triggered by ^C)
3325# be delivered to qemu. Default: true in -nographic mode,
3326# false otherwise.
3327#
3328# Since: 1.5
3329##
3330{ 'type': 'ChardevStdio', 'data': { '*signal' : 'bool' } }
3331
3332##
Gerd Hoffmanncd153e22013-02-25 12:39:06 +01003333# @ChardevSpiceChannel:
3334#
3335# Configuration info for spice vm channel chardevs.
3336#
3337# @type: kind of channel (for example vdagent).
3338#
3339# Since: 1.5
3340##
3341{ 'type': 'ChardevSpiceChannel', 'data': { 'type' : 'str' } }
3342
3343##
3344# @ChardevSpicePort:
3345#
3346# Configuration info for spice port chardevs.
3347#
3348# @fqdn: name of the channel (see docs/spice-port-fqdn.txt)
3349#
3350# Since: 1.5
3351##
3352{ 'type': 'ChardevSpicePort', 'data': { 'fqdn' : 'str' } }
3353
3354##
Gerd Hoffmann702ec692013-02-25 15:52:32 +01003355# @ChardevVC:
3356#
3357# Configuration info for virtual console chardevs.
3358#
3359# @width: console width, in pixels
3360# @height: console height, in pixels
3361# @cols: console width, in chars
3362# @rows: console height, in chars
3363#
3364# Since: 1.5
3365##
3366{ 'type': 'ChardevVC', 'data': { '*width' : 'int',
3367 '*height' : 'int',
3368 '*cols' : 'int',
3369 '*rows' : 'int' } }
3370
3371##
Lei Li6a85e602013-05-21 18:27:58 +08003372# @ChardevMemory:
Gerd Hoffmann1da48c62013-02-26 16:21:11 +01003373#
3374# Configuration info for memory chardevs
3375#
3376# @size: #optional Ringbuffer size, must be power of two, default is 65536
3377#
3378# Since: 1.5
3379##
Lei Li6a85e602013-05-21 18:27:58 +08003380{ 'type': 'ChardevMemory', 'data': { '*size' : 'int' } }
Gerd Hoffmann1da48c62013-02-26 16:21:11 +01003381
3382##
Gerd Hoffmannf1a1a352012-12-19 10:33:56 +01003383# @ChardevBackend:
3384#
3385# Configuration info for the new chardev backend.
3386#
3387# Since: 1.4
3388##
3389{ 'type': 'ChardevDummy', 'data': { } }
3390
Gerd Hoffmannf6bd5d62012-12-20 13:53:12 +01003391{ 'union': 'ChardevBackend', 'data': { 'file' : 'ChardevFile',
Markus Armbrusterd36b2b92013-02-13 15:54:16 +01003392 'serial' : 'ChardevHostdev',
3393 'parallel': 'ChardevHostdev',
Gerd Hoffmann548cbb32013-02-25 11:50:55 +01003394 'pipe' : 'ChardevHostdev',
Gerd Hoffmannf6bd5d62012-12-20 13:53:12 +01003395 'socket' : 'ChardevSocket',
Lei Li08d0ab32013-05-20 14:51:03 +08003396 'udp' : 'ChardevUdp',
Gerd Hoffmann0a1a7fa2012-12-20 14:39:13 +01003397 'pty' : 'ChardevDummy',
Gerd Hoffmannedb2fb32013-02-21 16:16:42 +01003398 'null' : 'ChardevDummy',
Gerd Hoffmannf5a51ca2013-02-21 11:58:44 +01003399 'mux' : 'ChardevMux',
Gerd Hoffmann2d572862013-02-21 12:56:10 +01003400 'msmouse': 'ChardevDummy',
Gerd Hoffmann7c358032013-02-21 12:34:58 +01003401 'braille': 'ChardevDummy',
Gerd Hoffmannd9ac3742013-02-25 11:48:06 +01003402 'stdio' : 'ChardevStdio',
Gerd Hoffmanncd153e22013-02-25 12:39:06 +01003403 'console': 'ChardevDummy',
3404 'spicevmc' : 'ChardevSpiceChannel',
Gerd Hoffmann702ec692013-02-25 15:52:32 +01003405 'spiceport' : 'ChardevSpicePort',
Gerd Hoffmann1da48c62013-02-26 16:21:11 +01003406 'vc' : 'ChardevVC',
Lei Li6a85e602013-05-21 18:27:58 +08003407 'memory' : 'ChardevMemory' } }
Gerd Hoffmannf1a1a352012-12-19 10:33:56 +01003408
3409##
3410# @ChardevReturn:
3411#
3412# Return info about the chardev backend just created.
3413#
Markus Armbruster58fa4322013-02-11 18:05:48 +01003414# @pty: #optional name of the slave pseudoterminal device, present if
3415# and only if a chardev of type 'pty' was created
3416#
Gerd Hoffmannf1a1a352012-12-19 10:33:56 +01003417# Since: 1.4
3418##
Gerd Hoffmann0a1a7fa2012-12-20 14:39:13 +01003419{ 'type' : 'ChardevReturn', 'data': { '*pty' : 'str' } }
Gerd Hoffmannf1a1a352012-12-19 10:33:56 +01003420
3421##
3422# @chardev-add:
3423#
Markus Armbruster58fa4322013-02-11 18:05:48 +01003424# Add a character device backend
Gerd Hoffmannf1a1a352012-12-19 10:33:56 +01003425#
3426# @id: the chardev's ID, must be unique
3427# @backend: backend type and parameters
3428#
Markus Armbruster58fa4322013-02-11 18:05:48 +01003429# Returns: ChardevReturn.
Gerd Hoffmannf1a1a352012-12-19 10:33:56 +01003430#
3431# Since: 1.4
3432##
3433{ 'command': 'chardev-add', 'data': {'id' : 'str',
3434 'backend' : 'ChardevBackend' },
3435 'returns': 'ChardevReturn' }
3436
3437##
3438# @chardev-remove:
3439#
Markus Armbruster58fa4322013-02-11 18:05:48 +01003440# Remove a character device backend
Gerd Hoffmannf1a1a352012-12-19 10:33:56 +01003441#
3442# @id: the chardev's ID, must exist and not be in use
3443#
3444# Returns: Nothing on success
3445#
3446# Since: 1.4
3447##
3448{ 'command': 'chardev-remove', 'data': {'id': 'str'} }
Stefan Bergerd1a0cf72013-02-27 12:47:49 -05003449
3450##
3451# @TpmModel:
3452#
3453# An enumeration of TPM models
3454#
3455# @tpm-tis: TPM TIS model
3456#
3457# Since: 1.5
3458##
3459{ 'enum': 'TpmModel', 'data': [ 'tpm-tis' ] }
3460
3461##
3462# @query-tpm-models:
3463#
3464# Return a list of supported TPM models
3465#
3466# Returns: a list of TpmModel
3467#
3468# Since: 1.5
3469##
3470{ 'command': 'query-tpm-models', 'returns': ['TpmModel'] }
3471
3472##
3473# @TpmType:
3474#
3475# An enumeration of TPM types
3476#
3477# @passthrough: TPM passthrough type
3478#
3479# Since: 1.5
3480##
3481{ 'enum': 'TpmType', 'data': [ 'passthrough' ] }
3482
3483##
3484# @query-tpm-types:
3485#
3486# Return a list of supported TPM types
3487#
3488# Returns: a list of TpmType
3489#
3490# Since: 1.5
3491##
3492{ 'command': 'query-tpm-types', 'returns': ['TpmType'] }
3493
3494##
3495# @TPMPassthroughOptions:
3496#
3497# Information about the TPM passthrough type
3498#
3499# @path: #optional string describing the path used for accessing the TPM device
3500#
3501# @cancel-path: #optional string showing the TPM's sysfs cancel file
3502# for cancellation of TPM commands while they are executing
3503#
3504# Since: 1.5
3505##
3506{ 'type': 'TPMPassthroughOptions', 'data': { '*path' : 'str',
3507 '*cancel-path' : 'str'} }
3508
3509##
3510# @TpmTypeOptions:
3511#
3512# A union referencing different TPM backend types' configuration options
3513#
Corey Bryant88ca7bc2013-03-20 12:34:48 -04003514# @passthrough: The configuration options for the TPM passthrough type
Stefan Bergerd1a0cf72013-02-27 12:47:49 -05003515#
3516# Since: 1.5
3517##
3518{ 'union': 'TpmTypeOptions',
Corey Bryant88ca7bc2013-03-20 12:34:48 -04003519 'data': { 'passthrough' : 'TPMPassthroughOptions' } }
Stefan Bergerd1a0cf72013-02-27 12:47:49 -05003520
3521##
3522# @TpmInfo:
3523#
3524# Information about the TPM
3525#
3526# @id: The Id of the TPM
3527#
3528# @model: The TPM frontend model
3529#
Corey Bryant88ca7bc2013-03-20 12:34:48 -04003530# @options: The TPM (backend) type configuration options
Stefan Bergerd1a0cf72013-02-27 12:47:49 -05003531#
3532# Since: 1.5
3533##
3534{ 'type': 'TPMInfo',
3535 'data': {'id': 'str',
3536 'model': 'TpmModel',
Corey Bryant88ca7bc2013-03-20 12:34:48 -04003537 'options': 'TpmTypeOptions' } }
Stefan Bergerd1a0cf72013-02-27 12:47:49 -05003538
3539##
3540# @query-tpm:
3541#
3542# Return information about the TPM device
3543#
3544# Returns: @TPMInfo on success
3545#
3546# Since: 1.5
3547##
3548{ 'command': 'query-tpm', 'returns': ['TPMInfo'] }
Laszlo Ersek8ccbad52013-03-21 00:23:16 +01003549
3550##
3551# @AcpiTableOptions
3552#
3553# Specify an ACPI table on the command line to load.
3554#
3555# At most one of @file and @data can be specified. The list of files specified
3556# by any one of them is loaded and concatenated in order. If both are omitted,
3557# @data is implied.
3558#
3559# Other fields / optargs can be used to override fields of the generic ACPI
3560# table header; refer to the ACPI specification 5.0, section 5.2.6 System
3561# Description Table Header. If a header field is not overridden, then the
3562# corresponding value from the concatenated blob is used (in case of @file), or
3563# it is filled in with a hard-coded value (in case of @data).
3564#
3565# String fields are copied into the matching ACPI member from lowest address
3566# upwards, and silently truncated / NUL-padded to length.
3567#
3568# @sig: #optional table signature / identifier (4 bytes)
3569#
3570# @rev: #optional table revision number (dependent on signature, 1 byte)
3571#
3572# @oem_id: #optional OEM identifier (6 bytes)
3573#
3574# @oem_table_id: #optional OEM table identifier (8 bytes)
3575#
3576# @oem_rev: #optional OEM-supplied revision number (4 bytes)
3577#
3578# @asl_compiler_id: #optional identifier of the utility that created the table
3579# (4 bytes)
3580#
3581# @asl_compiler_rev: #optional revision number of the utility that created the
3582# table (4 bytes)
3583#
3584# @file: #optional colon (:) separated list of pathnames to load and
3585# concatenate as table data. The resultant binary blob is expected to
3586# have an ACPI table header. At least one file is required. This field
3587# excludes @data.
3588#
3589# @data: #optional colon (:) separated list of pathnames to load and
3590# concatenate as table data. The resultant binary blob must not have an
3591# ACPI table header. At least one file is required. This field excludes
3592# @file.
3593#
3594# Since 1.5
3595##
3596{ 'type': 'AcpiTableOptions',
3597 'data': {
3598 '*sig': 'str',
3599 '*rev': 'uint8',
3600 '*oem_id': 'str',
3601 '*oem_table_id': 'str',
3602 '*oem_rev': 'uint32',
3603 '*asl_compiler_id': 'str',
3604 '*asl_compiler_rev': 'uint32',
3605 '*file': 'str',
3606 '*data': 'str' }}
Amos Kong1f8f9872013-04-25 17:50:35 +08003607
3608##
3609# @CommandLineParameterType:
3610#
3611# Possible types for an option parameter.
3612#
3613# @string: accepts a character string
3614#
3615# @boolean: accepts "on" or "off"
3616#
3617# @number: accepts a number
3618#
3619# @size: accepts a number followed by an optional suffix (K)ilo,
3620# (M)ega, (G)iga, (T)era
3621#
3622# Since 1.5
3623##
3624{ 'enum': 'CommandLineParameterType',
3625 'data': ['string', 'boolean', 'number', 'size'] }
3626
3627##
3628# @CommandLineParameterInfo:
3629#
3630# Details about a single parameter of a command line option.
3631#
3632# @name: parameter name
3633#
3634# @type: parameter @CommandLineParameterType
3635#
3636# @help: #optional human readable text string, not suitable for parsing.
3637#
3638# Since 1.5
3639##
3640{ 'type': 'CommandLineParameterInfo',
3641 'data': { 'name': 'str',
3642 'type': 'CommandLineParameterType',
3643 '*help': 'str' } }
3644
3645##
3646# @CommandLineOptionInfo:
3647#
3648# Details about a command line option, including its list of parameter details
3649#
3650# @option: option name
3651#
3652# @parameters: an array of @CommandLineParameterInfo
3653#
3654# Since 1.5
3655##
3656{ 'type': 'CommandLineOptionInfo',
3657 'data': { 'option': 'str', 'parameters': ['CommandLineParameterInfo'] } }
3658
3659##
3660# @query-command-line-options:
3661#
3662# Query command line option schema.
3663#
3664# @option: #optional option name
3665#
3666# Returns: list of @CommandLineOptionInfo for all options (or for the given
3667# @option). Returns an error if the given @option doesn't exist.
3668#
3669# Since 1.5
3670##
3671{'command': 'query-command-line-options', 'data': { '*option': 'str' },
3672 'returns': ['CommandLineOptionInfo'] }
Eduardo Habkost8e8aba52013-05-06 13:20:07 -03003673
3674##
3675# @X86CPURegister32
3676#
3677# A X86 32-bit register
3678#
3679# Since: 1.5
3680##
3681{ 'enum': 'X86CPURegister32',
3682 'data': [ 'EAX', 'EBX', 'ECX', 'EDX', 'ESP', 'EBP', 'ESI', 'EDI' ] }
3683
3684##
3685# @X86CPUFeatureWordInfo
3686#
3687# Information about a X86 CPU feature word
3688#
3689# @cpuid-input-eax: Input EAX value for CPUID instruction for that feature word
3690#
3691# @cpuid-input-ecx: #optional Input ECX value for CPUID instruction for that
3692# feature word
3693#
3694# @cpuid-register: Output register containing the feature bits
3695#
3696# @features: value of output register, containing the feature bits
3697#
3698# Since: 1.5
3699##
3700{ 'type': 'X86CPUFeatureWordInfo',
3701 'data': { 'cpuid-input-eax': 'int',
3702 '*cpuid-input-ecx': 'int',
3703 'cpuid-register': 'X86CPURegister32',
3704 'features': 'int' } }