]> git.proxmox.com Git - qemu.git/blob - qapi-schema.json
rdma: account for the time spent in MIG_STATE_SETUP through QMP
[qemu.git] / qapi-schema.json
1 # -*- Mode: Python -*-
2 #
3 # QAPI Schema
4
5 ##
6 # @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 #
25 # Since: 1.2
26 ##
27 { 'enum': 'ErrorClass',
28 'data': [ 'GenericError', 'CommandNotFound', 'DeviceEncrypted',
29 'DeviceNotActive', 'DeviceNotFound', 'KVMMissingCap' ] }
30
31 ##
32 # @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 ##
57 # @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' }
77
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' }
114
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
139 ##
140 # @RunState
141 #
142 # An enumeration of VM run states.
143 #
144 # @debug: QEMU is running on a debugger
145 #
146 # @finish-migrate: guest is paused to finish the migration process
147 #
148 # @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.
153 #
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 #
166 # @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 #
174 # @suspended: guest is suspended (ACPI S3)
175 #
176 # @watchdog: the watchdog action is configured to pause and has been triggered
177 #
178 # @guest-panicked: guest has been panicked as a result of guest OS panic
179 ##
180 { 'enum': 'RunState',
181 'data': [ 'debug', 'inmigrate', 'internal-error', 'io-error', 'paused',
182 'postmigrate', 'prelaunch', 'finish-migrate', 'restore-vm',
183 'running', 'save-vm', 'shutdown', 'suspended', 'watchdog',
184 'guest-panicked' ] }
185
186 ##
187 # @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 #
239 # @backing-image: #optional info of the backing image (since 1.6)
240 #
241 # 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',
250 '*backing-filename-format': 'str', '*snapshots': ['SnapshotInfo'],
251 '*backing-image': 'ImageInfo' } }
252
253 ##
254 # @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 #
288 # @compressed-clusters: #optional total number of compressed clusters, this
289 # field is present if the driver for the image format
290 # supports it
291 #
292 # 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',
301 '*fragmented-clusters': 'int', '*compressed-clusters': 'int' } }
302
303 ##
304 # @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
332 ##
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
356 ##
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'] }
382
383 ##
384 # @DataFormat:
385 #
386 # An enumeration of data format.
387 #
388 # @utf8: Data is a UTF-8 string (RFC 3629)
389 #
390 # @base64: Data is Base64 encoded binary (RFC 3548)
391 #
392 # Since: 1.4
393 ##
394 { 'enum': 'DataFormat',
395 'data': [ 'utf8', 'base64' ] }
396
397 ##
398 # @ringbuf-write:
399 #
400 # Write to a ring buffer character device.
401 #
402 # @device: the ring buffer character device name
403 #
404 # @data: data to write
405 #
406 # @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.
414 #
415 # Returns: Nothing on success
416 #
417 # Since: 1.4
418 ##
419 { 'command': 'ringbuf-write',
420 'data': {'device': 'str', 'data': 'str',
421 '*format': 'DataFormat'} }
422
423 ##
424 # @ringbuf-read:
425 #
426 # Read from a ring buffer character device.
427 #
428 # @device: the ring buffer character device name
429 #
430 # @size: how many bytes to read at most
431 #
432 # @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.
441 #
442 # Returns: data read from the device
443 #
444 # Since: 1.4
445 ##
446 { 'command': 'ringbuf-read',
447 'data': {'device': 'str', 'size': 'int', '*format': 'DataFormat'},
448 'returns': 'str' }
449
450 ##
451 # @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
472 ##
473 # @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 ##
495 # @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 #
505 # @duplicate: number of duplicate (zero) pages (since 1.2)
506 #
507 # @skipped: number of skipped zero pages (since 1.5)
508 #
509 # @normal : number of normal pages (since 1.2)
510 #
511 # @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)
515 #
516 # @mbps: throughput in megabits/sec. (since 1.6)
517 #
518 # Since: 0.14.0
519 ##
520 { 'type': 'MigrationStats',
521 'data': {'transferred': 'int', 'remaining': 'int', 'total': 'int' ,
522 'duplicate': 'int', 'skipped': 'int', 'normal': 'int',
523 'normal-bytes': 'int', 'dirty-pages-rate' : 'int',
524 'mbps' : 'number' } }
525
526 ##
527 # @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 ##
548 # @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 #
557 # @ram: #optional @MigrationStats containing detailed migration
558 # status, only returned if status is 'active' or
559 # 'completed'. 'comppleted' (since 1.2)
560 #
561 # @disk: #optional @MigrationStats containing detailed disk migration
562 # status, only returned if status is 'active' and it is a block
563 # migration
564 #
565 # @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 #
569 # @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 #
573 # @downtime: #optional only present when migration finishes correctly
574 # total downtime in milliseconds for the guest.
575 # (since 1.3)
576 #
577 # @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 #
581 # @setup-time: #optional amount of setup time in milliseconds _before_ the
582 # iterations begin but _after_ the QMP command is issued. This is designed
583 # to provide an accounting of any activities (such as RDMA pinning) which
584 # may be expensive, but do not actually occur during the iterative
585 # migration rounds themselves. (since 1.6)
586 #
587 # Since: 0.14.0
588 ##
589 { 'type': 'MigrationInfo',
590 'data': {'*status': 'str', '*ram': 'MigrationStats',
591 '*disk': 'MigrationStats',
592 '*xbzrle-cache': 'XBZRLECacheStats',
593 '*total-time': 'int',
594 '*expected-downtime': 'int',
595 '*downtime': 'int',
596 '*setup-time': 'int'} }
597
598 ##
599 # @query-migrate
600 #
601 # Returns information about current migration process.
602 #
603 # Returns: @MigrationInfo
604 #
605 # Since: 0.14.0
606 ##
607 { 'command': 'query-migrate', 'returns': 'MigrationInfo' }
608
609 ##
610 # @MigrationCapability
611 #
612 # Migration capabilities enumeration
613 #
614 # @xbzrle: Migration supports xbzrle (Xor Based Zero Run Length Encoding).
615 # This feature allows us to minimize migration traffic for certain work
616 # loads, by sending compressed difference of the pages
617 #
618 # @x-rdma-pin-all: Controls whether or not the entire VM memory footprint is
619 # mlock()'d on demand or all at once. Refer to docs/rdma.txt for usage.
620 # Disabled by default. Experimental: may (or may not) be renamed after
621 # further testing is complete. (since 1.6)
622 #
623 # @zero-blocks: During storage migration encode blocks of zeroes efficiently. This
624 # essentially saves 1MB of zeroes per block on the wire. Enabling requires
625 # source and target VM to support this feature. To enable it is sufficient
626 # to enable the capability on the source VM. The feature is disabled by
627 # default. (since 1.6)
628 #
629 # Since: 1.2
630 ##
631 { 'enum': 'MigrationCapability',
632 'data': ['xbzrle', 'x-rdma-pin-all', 'auto-converge', 'zero-blocks'] }
633
634 ##
635 # @MigrationCapabilityStatus
636 #
637 # Migration capability information
638 #
639 # @capability: capability enum
640 #
641 # @state: capability state bool
642 #
643 # Since: 1.2
644 ##
645 { 'type': 'MigrationCapabilityStatus',
646 'data': { 'capability' : 'MigrationCapability', 'state' : 'bool' } }
647
648 ##
649 # @migrate-set-capabilities
650 #
651 # Enable/Disable the following migration capabilities (like xbzrle)
652 #
653 # @capabilities: json array of capability modifications to make
654 #
655 # Since: 1.2
656 ##
657 { 'command': 'migrate-set-capabilities',
658 'data': { 'capabilities': ['MigrationCapabilityStatus'] } }
659
660 ##
661 # @query-migrate-capabilities
662 #
663 # Returns information about the current migration capabilities status
664 #
665 # Returns: @MigrationCapabilitiesStatus
666 #
667 # Since: 1.2
668 ##
669 { 'command': 'query-migrate-capabilities', 'returns': ['MigrationCapabilityStatus']}
670
671 ##
672 # @MouseInfo:
673 #
674 # Information about a mouse device.
675 #
676 # @name: the name of the mouse device
677 #
678 # @index: the index of the mouse device
679 #
680 # @current: true if this device is currently receiving mouse events
681 #
682 # @absolute: true if this device supports absolute coordinates as input
683 #
684 # Since: 0.14.0
685 ##
686 { 'type': 'MouseInfo',
687 'data': {'name': 'str', 'index': 'int', 'current': 'bool',
688 'absolute': 'bool'} }
689
690 ##
691 # @query-mice:
692 #
693 # Returns information about each active mouse device
694 #
695 # Returns: a list of @MouseInfo for each device
696 #
697 # Since: 0.14.0
698 ##
699 { 'command': 'query-mice', 'returns': ['MouseInfo'] }
700
701 ##
702 # @CpuInfo:
703 #
704 # Information about a virtual CPU
705 #
706 # @CPU: the index of the virtual CPU
707 #
708 # @current: this only exists for backwards compatible and should be ignored
709 #
710 # @halted: true if the virtual CPU is in the halt state. Halt usually refers
711 # to a processor specific low power mode.
712 #
713 # @pc: #optional If the target is i386 or x86_64, this is the 64-bit instruction
714 # pointer.
715 # If the target is Sparc, this is the PC component of the
716 # instruction pointer.
717 #
718 # @nip: #optional If the target is PPC, the instruction pointer
719 #
720 # @npc: #optional If the target is Sparc, the NPC component of the instruction
721 # pointer
722 #
723 # @PC: #optional If the target is MIPS, the instruction pointer
724 #
725 # @thread_id: ID of the underlying host thread
726 #
727 # Since: 0.14.0
728 #
729 # Notes: @halted is a transient state that changes frequently. By the time the
730 # data is sent to the client, the guest may no longer be halted.
731 ##
732 { 'type': 'CpuInfo',
733 'data': {'CPU': 'int', 'current': 'bool', 'halted': 'bool', '*pc': 'int',
734 '*nip': 'int', '*npc': 'int', '*PC': 'int', 'thread_id': 'int'} }
735
736 ##
737 # @query-cpus:
738 #
739 # Returns a list of information about each virtual CPU.
740 #
741 # Returns: a list of @CpuInfo for each virtual CPU
742 #
743 # Since: 0.14.0
744 ##
745 { 'command': 'query-cpus', 'returns': ['CpuInfo'] }
746
747 ##
748 # @BlockDeviceInfo:
749 #
750 # Information about the backing device for a block device.
751 #
752 # @file: the filename of the backing device
753 #
754 # @ro: true if the backing device was open read-only
755 #
756 # @drv: the name of the block format used to open the backing device. As of
757 # 0.14.0 this can be: 'blkdebug', 'bochs', 'cloop', 'cow', 'dmg',
758 # 'file', 'file', 'ftp', 'ftps', 'host_cdrom', 'host_device',
759 # 'host_floppy', 'http', 'https', 'nbd', 'parallels', 'qcow',
760 # 'qcow2', 'raw', 'tftp', 'vdi', 'vmdk', 'vpc', 'vvfat'
761 #
762 # @backing_file: #optional the name of the backing file (for copy-on-write)
763 #
764 # @backing_file_depth: number of files in the backing file chain (since: 1.2)
765 #
766 # @encrypted: true if the backing device is encrypted
767 #
768 # @encryption_key_missing: true if the backing device is encrypted but an
769 # valid encryption key is missing
770 #
771 # @bps: total throughput limit in bytes per second is specified
772 #
773 # @bps_rd: read throughput limit in bytes per second is specified
774 #
775 # @bps_wr: write throughput limit in bytes per second is specified
776 #
777 # @iops: total I/O operations per second is specified
778 #
779 # @iops_rd: read I/O operations per second is specified
780 #
781 # @iops_wr: write I/O operations per second is specified
782 #
783 # @image: the info of image used (since: 1.6)
784 #
785 # Since: 0.14.0
786 #
787 # Notes: This interface is only found in @BlockInfo.
788 ##
789 { 'type': 'BlockDeviceInfo',
790 'data': { 'file': 'str', 'ro': 'bool', 'drv': 'str',
791 '*backing_file': 'str', 'backing_file_depth': 'int',
792 'encrypted': 'bool', 'encryption_key_missing': 'bool',
793 'bps': 'int', 'bps_rd': 'int', 'bps_wr': 'int',
794 'iops': 'int', 'iops_rd': 'int', 'iops_wr': 'int',
795 'image': 'ImageInfo' } }
796
797 ##
798 # @BlockDeviceIoStatus:
799 #
800 # An enumeration of block device I/O status.
801 #
802 # @ok: The last I/O operation has succeeded
803 #
804 # @failed: The last I/O operation has failed
805 #
806 # @nospace: The last I/O operation has failed due to a no-space condition
807 #
808 # Since: 1.0
809 ##
810 { 'enum': 'BlockDeviceIoStatus', 'data': [ 'ok', 'failed', 'nospace' ] }
811
812 ##
813 # @BlockDirtyInfo:
814 #
815 # Block dirty bitmap information.
816 #
817 # @count: number of dirty bytes according to the dirty bitmap
818 #
819 # @granularity: granularity of the dirty bitmap in bytes (since 1.4)
820 #
821 # Since: 1.3
822 ##
823 { 'type': 'BlockDirtyInfo',
824 'data': {'count': 'int', 'granularity': 'int'} }
825
826 ##
827 # @BlockInfo:
828 #
829 # Block device information. This structure describes a virtual device and
830 # the backing device associated with it.
831 #
832 # @device: The device name associated with the virtual device.
833 #
834 # @type: This field is returned only for compatibility reasons, it should
835 # not be used (always returns 'unknown')
836 #
837 # @removable: True if the device supports removable media.
838 #
839 # @locked: True if the guest has locked this device from having its media
840 # removed
841 #
842 # @tray_open: #optional True if the device has a tray and it is open
843 # (only present if removable is true)
844 #
845 # @dirty: #optional dirty bitmap information (only present if the dirty
846 # bitmap is enabled)
847 #
848 # @io-status: #optional @BlockDeviceIoStatus. Only present if the device
849 # supports it and the VM is configured to stop on errors
850 #
851 # @inserted: #optional @BlockDeviceInfo describing the device if media is
852 # present
853 #
854 # Since: 0.14.0
855 ##
856 { 'type': 'BlockInfo',
857 'data': {'device': 'str', 'type': 'str', 'removable': 'bool',
858 'locked': 'bool', '*inserted': 'BlockDeviceInfo',
859 '*tray_open': 'bool', '*io-status': 'BlockDeviceIoStatus',
860 '*dirty': 'BlockDirtyInfo' } }
861
862 ##
863 # @query-block:
864 #
865 # Get a list of BlockInfo for all virtual block devices.
866 #
867 # Returns: a list of @BlockInfo describing each virtual block device
868 #
869 # Since: 0.14.0
870 ##
871 { 'command': 'query-block', 'returns': ['BlockInfo'] }
872
873 ##
874 # @BlockDeviceStats:
875 #
876 # Statistics of a virtual block device or a block backing device.
877 #
878 # @rd_bytes: The number of bytes read by the device.
879 #
880 # @wr_bytes: The number of bytes written by the device.
881 #
882 # @rd_operations: The number of read operations performed by the device.
883 #
884 # @wr_operations: The number of write operations performed by the device.
885 #
886 # @flush_operations: The number of cache flush operations performed by the
887 # device (since 0.15.0)
888 #
889 # @flush_total_time_ns: Total time spend on cache flushes in nano-seconds
890 # (since 0.15.0).
891 #
892 # @wr_total_time_ns: Total time spend on writes in nano-seconds (since 0.15.0).
893 #
894 # @rd_total_time_ns: Total_time_spend on reads in nano-seconds (since 0.15.0).
895 #
896 # @wr_highest_offset: The offset after the greatest byte written to the
897 # device. The intended use of this information is for
898 # growable sparse files (like qcow2) that are used on top
899 # of a physical device.
900 #
901 # Since: 0.14.0
902 ##
903 { 'type': 'BlockDeviceStats',
904 'data': {'rd_bytes': 'int', 'wr_bytes': 'int', 'rd_operations': 'int',
905 'wr_operations': 'int', 'flush_operations': 'int',
906 'flush_total_time_ns': 'int', 'wr_total_time_ns': 'int',
907 'rd_total_time_ns': 'int', 'wr_highest_offset': 'int' } }
908
909 ##
910 # @BlockStats:
911 #
912 # Statistics of a virtual block device or a block backing device.
913 #
914 # @device: #optional If the stats are for a virtual block device, the name
915 # corresponding to the virtual block device.
916 #
917 # @stats: A @BlockDeviceStats for the device.
918 #
919 # @parent: #optional This may point to the backing block device if this is a
920 # a virtual block device. If it's a backing block, this will point
921 # to the backing file is one is present.
922 #
923 # Since: 0.14.0
924 ##
925 { 'type': 'BlockStats',
926 'data': {'*device': 'str', 'stats': 'BlockDeviceStats',
927 '*parent': 'BlockStats'} }
928
929 ##
930 # @query-blockstats:
931 #
932 # Query the @BlockStats for all virtual block devices.
933 #
934 # Returns: A list of @BlockStats for each virtual block devices.
935 #
936 # Since: 0.14.0
937 ##
938 { 'command': 'query-blockstats', 'returns': ['BlockStats'] }
939
940 ##
941 # @VncClientInfo:
942 #
943 # Information about a connected VNC client.
944 #
945 # @host: The host name of the client. QEMU tries to resolve this to a DNS name
946 # when possible.
947 #
948 # @family: 'ipv6' if the client is connected via IPv6 and TCP
949 # 'ipv4' if the client is connected via IPv4 and TCP
950 # 'unix' if the client is connected via a unix domain socket
951 # 'unknown' otherwise
952 #
953 # @service: The service name of the client's port. This may depends on the
954 # host system's service database so symbolic names should not be
955 # relied on.
956 #
957 # @x509_dname: #optional If x509 authentication is in use, the Distinguished
958 # Name of the client.
959 #
960 # @sasl_username: #optional If SASL authentication is in use, the SASL username
961 # used for authentication.
962 #
963 # Since: 0.14.0
964 ##
965 { 'type': 'VncClientInfo',
966 'data': {'host': 'str', 'family': 'str', 'service': 'str',
967 '*x509_dname': 'str', '*sasl_username': 'str'} }
968
969 ##
970 # @VncInfo:
971 #
972 # Information about the VNC session.
973 #
974 # @enabled: true if the VNC server is enabled, false otherwise
975 #
976 # @host: #optional The hostname the VNC server is bound to. This depends on
977 # the name resolution on the host and may be an IP address.
978 #
979 # @family: #optional 'ipv6' if the host is listening for IPv6 connections
980 # 'ipv4' if the host is listening for IPv4 connections
981 # 'unix' if the host is listening on a unix domain socket
982 # 'unknown' otherwise
983 #
984 # @service: #optional The service name of the server's port. This may depends
985 # on the host system's service database so symbolic names should not
986 # be relied on.
987 #
988 # @auth: #optional the current authentication type used by the server
989 # 'none' if no authentication is being used
990 # 'vnc' if VNC authentication is being used
991 # 'vencrypt+plain' if VEncrypt is used with plain text authentication
992 # 'vencrypt+tls+none' if VEncrypt is used with TLS and no authentication
993 # 'vencrypt+tls+vnc' if VEncrypt is used with TLS and VNC authentication
994 # 'vencrypt+tls+plain' if VEncrypt is used with TLS and plain text auth
995 # 'vencrypt+x509+none' if VEncrypt is used with x509 and no auth
996 # 'vencrypt+x509+vnc' if VEncrypt is used with x509 and VNC auth
997 # 'vencrypt+x509+plain' if VEncrypt is used with x509 and plain text auth
998 # 'vencrypt+tls+sasl' if VEncrypt is used with TLS and SASL auth
999 # 'vencrypt+x509+sasl' if VEncrypt is used with x509 and SASL auth
1000 #
1001 # @clients: a list of @VncClientInfo of all currently connected clients
1002 #
1003 # Since: 0.14.0
1004 ##
1005 { 'type': 'VncInfo',
1006 'data': {'enabled': 'bool', '*host': 'str', '*family': 'str',
1007 '*service': 'str', '*auth': 'str', '*clients': ['VncClientInfo']} }
1008
1009 ##
1010 # @query-vnc:
1011 #
1012 # Returns information about the current VNC server
1013 #
1014 # Returns: @VncInfo
1015 #
1016 # Since: 0.14.0
1017 ##
1018 { 'command': 'query-vnc', 'returns': 'VncInfo' }
1019
1020 ##
1021 # @SpiceChannel
1022 #
1023 # Information about a SPICE client channel.
1024 #
1025 # @host: The host name of the client. QEMU tries to resolve this to a DNS name
1026 # when possible.
1027 #
1028 # @family: 'ipv6' if the client is connected via IPv6 and TCP
1029 # 'ipv4' if the client is connected via IPv4 and TCP
1030 # 'unix' if the client is connected via a unix domain socket
1031 # 'unknown' otherwise
1032 #
1033 # @port: The client's port number.
1034 #
1035 # @connection-id: SPICE connection id number. All channels with the same id
1036 # belong to the same SPICE session.
1037 #
1038 # @connection-type: SPICE channel type number. "1" is the main control
1039 # channel, filter for this one if you want to track spice
1040 # sessions only
1041 #
1042 # @channel-id: SPICE channel ID number. Usually "0", might be different when
1043 # multiple channels of the same type exist, such as multiple
1044 # display channels in a multihead setup
1045 #
1046 # @tls: true if the channel is encrypted, false otherwise.
1047 #
1048 # Since: 0.14.0
1049 ##
1050 { 'type': 'SpiceChannel',
1051 'data': {'host': 'str', 'family': 'str', 'port': 'str',
1052 'connection-id': 'int', 'channel-type': 'int', 'channel-id': 'int',
1053 'tls': 'bool'} }
1054
1055 ##
1056 # @SpiceQueryMouseMode
1057 #
1058 # An enumeration of Spice mouse states.
1059 #
1060 # @client: Mouse cursor position is determined by the client.
1061 #
1062 # @server: Mouse cursor position is determined by the server.
1063 #
1064 # @unknown: No information is available about mouse mode used by
1065 # the spice server.
1066 #
1067 # Note: spice/enums.h has a SpiceMouseMode already, hence the name.
1068 #
1069 # Since: 1.1
1070 ##
1071 { 'enum': 'SpiceQueryMouseMode',
1072 'data': [ 'client', 'server', 'unknown' ] }
1073
1074 ##
1075 # @SpiceInfo
1076 #
1077 # Information about the SPICE session.
1078 #
1079 # @enabled: true if the SPICE server is enabled, false otherwise
1080 #
1081 # @migrated: true if the last guest migration completed and spice
1082 # migration had completed as well. false otherwise.
1083 #
1084 # @host: #optional The hostname the SPICE server is bound to. This depends on
1085 # the name resolution on the host and may be an IP address.
1086 #
1087 # @port: #optional The SPICE server's port number.
1088 #
1089 # @compiled-version: #optional SPICE server version.
1090 #
1091 # @tls-port: #optional The SPICE server's TLS port number.
1092 #
1093 # @auth: #optional the current authentication type used by the server
1094 # 'none' if no authentication is being used
1095 # 'spice' uses SASL or direct TLS authentication, depending on command
1096 # line options
1097 #
1098 # @mouse-mode: The mode in which the mouse cursor is displayed currently. Can
1099 # be determined by the client or the server, or unknown if spice
1100 # server doesn't provide this information.
1101 #
1102 # Since: 1.1
1103 #
1104 # @channels: a list of @SpiceChannel for each active spice channel
1105 #
1106 # Since: 0.14.0
1107 ##
1108 { 'type': 'SpiceInfo',
1109 'data': {'enabled': 'bool', 'migrated': 'bool', '*host': 'str', '*port': 'int',
1110 '*tls-port': 'int', '*auth': 'str', '*compiled-version': 'str',
1111 'mouse-mode': 'SpiceQueryMouseMode', '*channels': ['SpiceChannel']} }
1112
1113 ##
1114 # @query-spice
1115 #
1116 # Returns information about the current SPICE server
1117 #
1118 # Returns: @SpiceInfo
1119 #
1120 # Since: 0.14.0
1121 ##
1122 { 'command': 'query-spice', 'returns': 'SpiceInfo' }
1123
1124 ##
1125 # @BalloonInfo:
1126 #
1127 # Information about the guest balloon device.
1128 #
1129 # @actual: the number of bytes the balloon currently contains
1130 #
1131 # Since: 0.14.0
1132 #
1133 ##
1134 { 'type': 'BalloonInfo', 'data': {'actual': 'int' } }
1135
1136 ##
1137 # @query-balloon:
1138 #
1139 # Return information about the balloon device.
1140 #
1141 # Returns: @BalloonInfo on success
1142 # If the balloon driver is enabled but not functional because the KVM
1143 # kernel module cannot support it, KvmMissingCap
1144 # If no balloon device is present, DeviceNotActive
1145 #
1146 # Since: 0.14.0
1147 ##
1148 { 'command': 'query-balloon', 'returns': 'BalloonInfo' }
1149
1150 ##
1151 # @PciMemoryRange:
1152 #
1153 # A PCI device memory region
1154 #
1155 # @base: the starting address (guest physical)
1156 #
1157 # @limit: the ending address (guest physical)
1158 #
1159 # Since: 0.14.0
1160 ##
1161 { 'type': 'PciMemoryRange', 'data': {'base': 'int', 'limit': 'int'} }
1162
1163 ##
1164 # @PciMemoryRegion
1165 #
1166 # Information about a PCI device I/O region.
1167 #
1168 # @bar: the index of the Base Address Register for this region
1169 #
1170 # @type: 'io' if the region is a PIO region
1171 # 'memory' if the region is a MMIO region
1172 #
1173 # @prefetch: #optional if @type is 'memory', true if the memory is prefetchable
1174 #
1175 # @mem_type_64: #optional if @type is 'memory', true if the BAR is 64-bit
1176 #
1177 # Since: 0.14.0
1178 ##
1179 { 'type': 'PciMemoryRegion',
1180 'data': {'bar': 'int', 'type': 'str', 'address': 'int', 'size': 'int',
1181 '*prefetch': 'bool', '*mem_type_64': 'bool' } }
1182
1183 ##
1184 # @PciBridgeInfo:
1185 #
1186 # Information about a PCI Bridge device
1187 #
1188 # @bus.number: primary bus interface number. This should be the number of the
1189 # bus the device resides on.
1190 #
1191 # @bus.secondary: secondary bus interface number. This is the number of the
1192 # main bus for the bridge
1193 #
1194 # @bus.subordinate: This is the highest number bus that resides below the
1195 # bridge.
1196 #
1197 # @bus.io_range: The PIO range for all devices on this bridge
1198 #
1199 # @bus.memory_range: The MMIO range for all devices on this bridge
1200 #
1201 # @bus.prefetchable_range: The range of prefetchable MMIO for all devices on
1202 # this bridge
1203 #
1204 # @devices: a list of @PciDeviceInfo for each device on this bridge
1205 #
1206 # Since: 0.14.0
1207 ##
1208 { 'type': 'PciBridgeInfo',
1209 'data': {'bus': { 'number': 'int', 'secondary': 'int', 'subordinate': 'int',
1210 'io_range': 'PciMemoryRange',
1211 'memory_range': 'PciMemoryRange',
1212 'prefetchable_range': 'PciMemoryRange' },
1213 '*devices': ['PciDeviceInfo']} }
1214
1215 ##
1216 # @PciDeviceInfo:
1217 #
1218 # Information about a PCI device
1219 #
1220 # @bus: the bus number of the device
1221 #
1222 # @slot: the slot the device is located in
1223 #
1224 # @function: the function of the slot used by the device
1225 #
1226 # @class_info.desc: #optional a string description of the device's class
1227 #
1228 # @class_info.class: the class code of the device
1229 #
1230 # @id.device: the PCI device id
1231 #
1232 # @id.vendor: the PCI vendor id
1233 #
1234 # @irq: #optional if an IRQ is assigned to the device, the IRQ number
1235 #
1236 # @qdev_id: the device name of the PCI device
1237 #
1238 # @pci_bridge: if the device is a PCI bridge, the bridge information
1239 #
1240 # @regions: a list of the PCI I/O regions associated with the device
1241 #
1242 # Notes: the contents of @class_info.desc are not stable and should only be
1243 # treated as informational.
1244 #
1245 # Since: 0.14.0
1246 ##
1247 { 'type': 'PciDeviceInfo',
1248 'data': {'bus': 'int', 'slot': 'int', 'function': 'int',
1249 'class_info': {'*desc': 'str', 'class': 'int'},
1250 'id': {'device': 'int', 'vendor': 'int'},
1251 '*irq': 'int', 'qdev_id': 'str', '*pci_bridge': 'PciBridgeInfo',
1252 'regions': ['PciMemoryRegion']} }
1253
1254 ##
1255 # @PciInfo:
1256 #
1257 # Information about a PCI bus
1258 #
1259 # @bus: the bus index
1260 #
1261 # @devices: a list of devices on this bus
1262 #
1263 # Since: 0.14.0
1264 ##
1265 { 'type': 'PciInfo', 'data': {'bus': 'int', 'devices': ['PciDeviceInfo']} }
1266
1267 ##
1268 # @query-pci:
1269 #
1270 # Return information about the PCI bus topology of the guest.
1271 #
1272 # Returns: a list of @PciInfo for each PCI bus
1273 #
1274 # Since: 0.14.0
1275 ##
1276 { 'command': 'query-pci', 'returns': ['PciInfo'] }
1277
1278 ##
1279 # @BlockdevOnError:
1280 #
1281 # An enumeration of possible behaviors for errors on I/O operations.
1282 # The exact meaning depends on whether the I/O was initiated by a guest
1283 # or by a block job
1284 #
1285 # @report: for guest operations, report the error to the guest;
1286 # for jobs, cancel the job
1287 #
1288 # @ignore: ignore the error, only report a QMP event (BLOCK_IO_ERROR
1289 # or BLOCK_JOB_ERROR)
1290 #
1291 # @enospc: same as @stop on ENOSPC, same as @report otherwise.
1292 #
1293 # @stop: for guest operations, stop the virtual machine;
1294 # for jobs, pause the job
1295 #
1296 # Since: 1.3
1297 ##
1298 { 'enum': 'BlockdevOnError',
1299 'data': ['report', 'ignore', 'enospc', 'stop'] }
1300
1301 ##
1302 # @MirrorSyncMode:
1303 #
1304 # An enumeration of possible behaviors for the initial synchronization
1305 # phase of storage mirroring.
1306 #
1307 # @top: copies data in the topmost image to the destination
1308 #
1309 # @full: copies data from all images to the destination
1310 #
1311 # @none: only copy data written from now on
1312 #
1313 # Since: 1.3
1314 ##
1315 { 'enum': 'MirrorSyncMode',
1316 'data': ['top', 'full', 'none'] }
1317
1318 ##
1319 # @BlockJobInfo:
1320 #
1321 # Information about a long-running block device operation.
1322 #
1323 # @type: the job type ('stream' for image streaming)
1324 #
1325 # @device: the block device name
1326 #
1327 # @len: the maximum progress value
1328 #
1329 # @busy: false if the job is known to be in a quiescent state, with
1330 # no pending I/O. Since 1.3.
1331 #
1332 # @paused: whether the job is paused or, if @busy is true, will
1333 # pause itself as soon as possible. Since 1.3.
1334 #
1335 # @offset: the current progress value
1336 #
1337 # @speed: the rate limit, bytes per second
1338 #
1339 # @io-status: the status of the job (since 1.3)
1340 #
1341 # Since: 1.1
1342 ##
1343 { 'type': 'BlockJobInfo',
1344 'data': {'type': 'str', 'device': 'str', 'len': 'int',
1345 'offset': 'int', 'busy': 'bool', 'paused': 'bool', 'speed': 'int',
1346 'io-status': 'BlockDeviceIoStatus'} }
1347
1348 ##
1349 # @query-block-jobs:
1350 #
1351 # Return information about long-running block device operations.
1352 #
1353 # Returns: a list of @BlockJobInfo for each active block job
1354 #
1355 # Since: 1.1
1356 ##
1357 { 'command': 'query-block-jobs', 'returns': ['BlockJobInfo'] }
1358
1359 ##
1360 # @quit:
1361 #
1362 # This command will cause the QEMU process to exit gracefully. While every
1363 # attempt is made to send the QMP response before terminating, this is not
1364 # guaranteed. When using this interface, a premature EOF would not be
1365 # unexpected.
1366 #
1367 # Since: 0.14.0
1368 ##
1369 { 'command': 'quit' }
1370
1371 ##
1372 # @stop:
1373 #
1374 # Stop all guest VCPU execution.
1375 #
1376 # Since: 0.14.0
1377 #
1378 # Notes: This function will succeed even if the guest is already in the stopped
1379 # state. In "inmigrate" state, it will ensure that the guest
1380 # remains paused once migration finishes, as if the -S option was
1381 # passed on the command line.
1382 ##
1383 { 'command': 'stop' }
1384
1385 ##
1386 # @system_reset:
1387 #
1388 # Performs a hard reset of a guest.
1389 #
1390 # Since: 0.14.0
1391 ##
1392 { 'command': 'system_reset' }
1393
1394 ##
1395 # @system_powerdown:
1396 #
1397 # Requests that a guest perform a powerdown operation.
1398 #
1399 # Since: 0.14.0
1400 #
1401 # Notes: A guest may or may not respond to this command. This command
1402 # returning does not indicate that a guest has accepted the request or
1403 # that it has shut down. Many guests will respond to this command by
1404 # prompting the user in some way.
1405 ##
1406 { 'command': 'system_powerdown' }
1407
1408 ##
1409 # @cpu:
1410 #
1411 # This command is a nop that is only provided for the purposes of compatibility.
1412 #
1413 # Since: 0.14.0
1414 #
1415 # Notes: Do not use this command.
1416 ##
1417 { 'command': 'cpu', 'data': {'index': 'int'} }
1418
1419 ##
1420 # @cpu-add
1421 #
1422 # Adds CPU with specified ID
1423 #
1424 # @id: ID of CPU to be created, valid values [0..max_cpus)
1425 #
1426 # Returns: Nothing on success
1427 #
1428 # Since 1.5
1429 ##
1430 { 'command': 'cpu-add', 'data': {'id': 'int'} }
1431
1432 ##
1433 # @memsave:
1434 #
1435 # Save a portion of guest memory to a file.
1436 #
1437 # @val: the virtual address of the guest to start from
1438 #
1439 # @size: the size of memory region to save
1440 #
1441 # @filename: the file to save the memory to as binary data
1442 #
1443 # @cpu-index: #optional the index of the virtual CPU to use for translating the
1444 # virtual address (defaults to CPU 0)
1445 #
1446 # Returns: Nothing on success
1447 #
1448 # Since: 0.14.0
1449 #
1450 # Notes: Errors were not reliably returned until 1.1
1451 ##
1452 { 'command': 'memsave',
1453 'data': {'val': 'int', 'size': 'int', 'filename': 'str', '*cpu-index': 'int'} }
1454
1455 ##
1456 # @pmemsave:
1457 #
1458 # Save a portion of guest physical memory to a file.
1459 #
1460 # @val: the physical address of the guest to start from
1461 #
1462 # @size: the size of memory region to save
1463 #
1464 # @filename: the file to save the memory to as binary data
1465 #
1466 # Returns: Nothing on success
1467 #
1468 # Since: 0.14.0
1469 #
1470 # Notes: Errors were not reliably returned until 1.1
1471 ##
1472 { 'command': 'pmemsave',
1473 'data': {'val': 'int', 'size': 'int', 'filename': 'str'} }
1474
1475 ##
1476 # @cont:
1477 #
1478 # Resume guest VCPU execution.
1479 #
1480 # Since: 0.14.0
1481 #
1482 # Returns: If successful, nothing
1483 # If QEMU was started with an encrypted block device and a key has
1484 # not yet been set, DeviceEncrypted.
1485 #
1486 # Notes: This command will succeed if the guest is currently running. It
1487 # will also succeed if the guest is in the "inmigrate" state; in
1488 # this case, the effect of the command is to make sure the guest
1489 # starts once migration finishes, removing the effect of the -S
1490 # command line option if it was passed.
1491 ##
1492 { 'command': 'cont' }
1493
1494 ##
1495 # @system_wakeup:
1496 #
1497 # Wakeup guest from suspend. Does nothing in case the guest isn't suspended.
1498 #
1499 # Since: 1.1
1500 #
1501 # Returns: nothing.
1502 ##
1503 { 'command': 'system_wakeup' }
1504
1505 ##
1506 # @inject-nmi:
1507 #
1508 # Injects an Non-Maskable Interrupt into all guest's VCPUs.
1509 #
1510 # Returns: If successful, nothing
1511 #
1512 # Since: 0.14.0
1513 #
1514 # Notes: Only x86 Virtual Machines support this command.
1515 ##
1516 { 'command': 'inject-nmi' }
1517
1518 ##
1519 # @set_link:
1520 #
1521 # Sets the link status of a virtual network adapter.
1522 #
1523 # @name: the device name of the virtual network adapter
1524 #
1525 # @up: true to set the link status to be up
1526 #
1527 # Returns: Nothing on success
1528 # If @name is not a valid network device, DeviceNotFound
1529 #
1530 # Since: 0.14.0
1531 #
1532 # Notes: Not all network adapters support setting link status. This command
1533 # will succeed even if the network adapter does not support link status
1534 # notification.
1535 ##
1536 { 'command': 'set_link', 'data': {'name': 'str', 'up': 'bool'} }
1537
1538 ##
1539 # @block_passwd:
1540 #
1541 # This command sets the password of a block device that has not been open
1542 # with a password and requires one.
1543 #
1544 # The two cases where this can happen are a block device is created through
1545 # QEMU's initial command line or a block device is changed through the legacy
1546 # @change interface.
1547 #
1548 # In the event that the block device is created through the initial command
1549 # line, the VM will start in the stopped state regardless of whether '-S' is
1550 # used. The intention is for a management tool to query the block devices to
1551 # determine which ones are encrypted, set the passwords with this command, and
1552 # then start the guest with the @cont command.
1553 #
1554 # @device: the name of the device to set the password on
1555 #
1556 # @password: the password to use for the device
1557 #
1558 # Returns: nothing on success
1559 # If @device is not a valid block device, DeviceNotFound
1560 # If @device is not encrypted, DeviceNotEncrypted
1561 #
1562 # Notes: Not all block formats support encryption and some that do are not
1563 # able to validate that a password is correct. Disk corruption may
1564 # occur if an invalid password is specified.
1565 #
1566 # Since: 0.14.0
1567 ##
1568 { 'command': 'block_passwd', 'data': {'device': 'str', 'password': 'str'} }
1569
1570 ##
1571 # @balloon:
1572 #
1573 # Request the balloon driver to change its balloon size.
1574 #
1575 # @value: the target size of the balloon in bytes
1576 #
1577 # Returns: Nothing on success
1578 # If the balloon driver is enabled but not functional because the KVM
1579 # kernel module cannot support it, KvmMissingCap
1580 # If no balloon device is present, DeviceNotActive
1581 #
1582 # Notes: This command just issues a request to the guest. When it returns,
1583 # the balloon size may not have changed. A guest can change the balloon
1584 # size independent of this command.
1585 #
1586 # Since: 0.14.0
1587 ##
1588 { 'command': 'balloon', 'data': {'value': 'int'} }
1589
1590 ##
1591 # @block_resize
1592 #
1593 # Resize a block image while a guest is running.
1594 #
1595 # @device: the name of the device to get the image resized
1596 #
1597 # @size: new image size in bytes
1598 #
1599 # Returns: nothing on success
1600 # If @device is not a valid block device, DeviceNotFound
1601 #
1602 # Since: 0.14.0
1603 ##
1604 { 'command': 'block_resize', 'data': { 'device': 'str', 'size': 'int' }}
1605
1606 ##
1607 # @NewImageMode
1608 #
1609 # An enumeration that tells QEMU how to set the backing file path in
1610 # a new image file.
1611 #
1612 # @existing: QEMU should look for an existing image file.
1613 #
1614 # @absolute-paths: QEMU should create a new image with absolute paths
1615 # for the backing file.
1616 #
1617 # Since: 1.1
1618 ##
1619 { 'enum': 'NewImageMode',
1620 'data': [ 'existing', 'absolute-paths' ] }
1621
1622 ##
1623 # @BlockdevSnapshot
1624 #
1625 # @device: the name of the device to generate the snapshot from.
1626 #
1627 # @snapshot-file: the target of the new image. A new file will be created.
1628 #
1629 # @format: #optional the format of the snapshot image, default is 'qcow2'.
1630 #
1631 # @mode: #optional whether and how QEMU should create a new image, default is
1632 # 'absolute-paths'.
1633 ##
1634 { 'type': 'BlockdevSnapshot',
1635 'data': { 'device': 'str', 'snapshot-file': 'str', '*format': 'str',
1636 '*mode': 'NewImageMode' } }
1637
1638 ##
1639 # @DriveBackup
1640 #
1641 # @device: the name of the device which should be copied.
1642 #
1643 # @target: the target of the new image. If the file exists, or if it
1644 # is a device, the existing file/device will be used as the new
1645 # destination. If it does not exist, a new file will be created.
1646 #
1647 # @format: #optional the format of the new destination, default is to
1648 # probe if @mode is 'existing', else the format of the source
1649 #
1650 # @sync: what parts of the disk image should be copied to the destination
1651 # (all the disk, only the sectors allocated in the topmost image, or
1652 # only new I/O).
1653 #
1654 # @mode: #optional whether and how QEMU should create a new image, default is
1655 # 'absolute-paths'.
1656 #
1657 # @speed: #optional the maximum speed, in bytes per second
1658 #
1659 # @on-source-error: #optional the action to take on an error on the source,
1660 # default 'report'. 'stop' and 'enospc' can only be used
1661 # if the block device supports io-status (see BlockInfo).
1662 #
1663 # @on-target-error: #optional the action to take on an error on the target,
1664 # default 'report' (no limitations, since this applies to
1665 # a different block device than @device).
1666 #
1667 # Note that @on-source-error and @on-target-error only affect background I/O.
1668 # If an error occurs during a guest write request, the device's rerror/werror
1669 # actions will be used.
1670 #
1671 # Since: 1.6
1672 ##
1673 { 'type': 'DriveBackup',
1674 'data': { 'device': 'str', 'target': 'str', '*format': 'str',
1675 'sync': 'MirrorSyncMode', '*mode': 'NewImageMode',
1676 '*speed': 'int',
1677 '*on-source-error': 'BlockdevOnError',
1678 '*on-target-error': 'BlockdevOnError' } }
1679
1680 ##
1681 # @Abort
1682 #
1683 # This action can be used to test transaction failure.
1684 #
1685 # Since: 1.6
1686 ###
1687 { 'type': 'Abort',
1688 'data': { } }
1689
1690 ##
1691 # @TransactionAction
1692 #
1693 # A discriminated record of operations that can be performed with
1694 # @transaction.
1695 ##
1696 { 'union': 'TransactionAction',
1697 'data': {
1698 'blockdev-snapshot-sync': 'BlockdevSnapshot',
1699 'drive-backup': 'DriveBackup',
1700 'abort': 'Abort'
1701 } }
1702
1703 ##
1704 # @transaction
1705 #
1706 # Executes a number of transactionable QMP commands atomically. If any
1707 # operation fails, then the entire set of actions will be abandoned and the
1708 # appropriate error returned.
1709 #
1710 # List of:
1711 # @TransactionAction: information needed for the respective operation
1712 #
1713 # Returns: nothing on success
1714 # Errors depend on the operations of the transaction
1715 #
1716 # Note: The transaction aborts on the first failure. Therefore, there will be
1717 # information on only one failed operation returned in an error condition, and
1718 # subsequent actions will not have been attempted.
1719 #
1720 # Since 1.1
1721 ##
1722 { 'command': 'transaction',
1723 'data': { 'actions': [ 'TransactionAction' ] } }
1724
1725 ##
1726 # @blockdev-snapshot-sync
1727 #
1728 # Generates a synchronous snapshot of a block device.
1729 #
1730 # For the arguments, see the documentation of BlockdevSnapshot.
1731 #
1732 # Returns: nothing on success
1733 # If @device is not a valid block device, DeviceNotFound
1734 #
1735 # Since 0.14.0
1736 ##
1737 { 'command': 'blockdev-snapshot-sync',
1738 'data': 'BlockdevSnapshot' }
1739
1740 ##
1741 # @human-monitor-command:
1742 #
1743 # Execute a command on the human monitor and return the output.
1744 #
1745 # @command-line: the command to execute in the human monitor
1746 #
1747 # @cpu-index: #optional The CPU to use for commands that require an implicit CPU
1748 #
1749 # Returns: the output of the command as a string
1750 #
1751 # Since: 0.14.0
1752 #
1753 # Notes: This command only exists as a stop-gap. It's use is highly
1754 # discouraged. The semantics of this command are not guaranteed.
1755 #
1756 # Known limitations:
1757 #
1758 # o This command is stateless, this means that commands that depend
1759 # on state information (such as getfd) might not work
1760 #
1761 # o Commands that prompt the user for data (eg. 'cont' when the block
1762 # device is encrypted) don't currently work
1763 ##
1764 { 'command': 'human-monitor-command',
1765 'data': {'command-line': 'str', '*cpu-index': 'int'},
1766 'returns': 'str' }
1767
1768 ##
1769 # @block-commit
1770 #
1771 # Live commit of data from overlay image nodes into backing nodes - i.e.,
1772 # writes data between 'top' and 'base' into 'base'.
1773 #
1774 # @device: the name of the device
1775 #
1776 # @base: #optional The file name of the backing image to write data into.
1777 # If not specified, this is the deepest backing image
1778 #
1779 # @top: The file name of the backing image within the image chain,
1780 # which contains the topmost data to be committed down.
1781 # Note, the active layer as 'top' is currently unsupported.
1782 #
1783 # If top == base, that is an error.
1784 #
1785 #
1786 # @speed: #optional the maximum speed, in bytes per second
1787 #
1788 # Returns: Nothing on success
1789 # If commit or stream is already active on this device, DeviceInUse
1790 # If @device does not exist, DeviceNotFound
1791 # If image commit is not supported by this device, NotSupported
1792 # If @base or @top is invalid, a generic error is returned
1793 # If @top is the active layer, or omitted, a generic error is returned
1794 # If @speed is invalid, InvalidParameter
1795 #
1796 # Since: 1.3
1797 #
1798 ##
1799 { 'command': 'block-commit',
1800 'data': { 'device': 'str', '*base': 'str', 'top': 'str',
1801 '*speed': 'int' } }
1802
1803 ##
1804 # @drive-backup
1805 #
1806 # Start a point-in-time copy of a block device to a new destination. The
1807 # status of ongoing drive-backup operations can be checked with
1808 # query-block-jobs where the BlockJobInfo.type field has the value 'backup'.
1809 # The operation can be stopped before it has completed using the
1810 # block-job-cancel command.
1811 #
1812 # For the arguments, see the documentation of DriveBackup.
1813 #
1814 # Returns: nothing on success
1815 # If @device is not a valid block device, DeviceNotFound
1816 #
1817 # Since 1.6
1818 ##
1819 { 'command': 'drive-backup', 'data': 'DriveBackup' }
1820
1821 ##
1822 # @drive-mirror
1823 #
1824 # Start mirroring a block device's writes to a new destination.
1825 #
1826 # @device: the name of the device whose writes should be mirrored.
1827 #
1828 # @target: the target of the new image. If the file exists, or if it
1829 # is a device, the existing file/device will be used as the new
1830 # destination. If it does not exist, a new file will be created.
1831 #
1832 # @format: #optional the format of the new destination, default is to
1833 # probe if @mode is 'existing', else the format of the source
1834 #
1835 # @mode: #optional whether and how QEMU should create a new image, default is
1836 # 'absolute-paths'.
1837 #
1838 # @speed: #optional the maximum speed, in bytes per second
1839 #
1840 # @sync: what parts of the disk image should be copied to the destination
1841 # (all the disk, only the sectors allocated in the topmost image, or
1842 # only new I/O).
1843 #
1844 # @granularity: #optional granularity of the dirty bitmap, default is 64K
1845 # if the image format doesn't have clusters, 4K if the clusters
1846 # are smaller than that, else the cluster size. Must be a
1847 # power of 2 between 512 and 64M (since 1.4).
1848 #
1849 # @buf-size: #optional maximum amount of data in flight from source to
1850 # target (since 1.4).
1851 #
1852 # @on-source-error: #optional the action to take on an error on the source,
1853 # default 'report'. 'stop' and 'enospc' can only be used
1854 # if the block device supports io-status (see BlockInfo).
1855 #
1856 # @on-target-error: #optional the action to take on an error on the target,
1857 # default 'report' (no limitations, since this applies to
1858 # a different block device than @device).
1859 #
1860 # Returns: nothing on success
1861 # If @device is not a valid block device, DeviceNotFound
1862 #
1863 # Since 1.3
1864 ##
1865 { 'command': 'drive-mirror',
1866 'data': { 'device': 'str', 'target': 'str', '*format': 'str',
1867 'sync': 'MirrorSyncMode', '*mode': 'NewImageMode',
1868 '*speed': 'int', '*granularity': 'uint32',
1869 '*buf-size': 'int', '*on-source-error': 'BlockdevOnError',
1870 '*on-target-error': 'BlockdevOnError' } }
1871
1872 ##
1873 # @migrate_cancel
1874 #
1875 # Cancel the current executing migration process.
1876 #
1877 # Returns: nothing on success
1878 #
1879 # Notes: This command succeeds even if there is no migration process running.
1880 #
1881 # Since: 0.14.0
1882 ##
1883 { 'command': 'migrate_cancel' }
1884
1885 ##
1886 # @migrate_set_downtime
1887 #
1888 # Set maximum tolerated downtime for migration.
1889 #
1890 # @value: maximum downtime in seconds
1891 #
1892 # Returns: nothing on success
1893 #
1894 # Since: 0.14.0
1895 ##
1896 { 'command': 'migrate_set_downtime', 'data': {'value': 'number'} }
1897
1898 ##
1899 # @migrate_set_speed
1900 #
1901 # Set maximum speed for migration.
1902 #
1903 # @value: maximum speed in bytes.
1904 #
1905 # Returns: nothing on success
1906 #
1907 # Notes: A value lesser than zero will be automatically round up to zero.
1908 #
1909 # Since: 0.14.0
1910 ##
1911 { 'command': 'migrate_set_speed', 'data': {'value': 'int'} }
1912
1913 ##
1914 # @migrate-set-cache-size
1915 #
1916 # Set XBZRLE cache size
1917 #
1918 # @value: cache size in bytes
1919 #
1920 # The size will be rounded down to the nearest power of 2.
1921 # The cache size can be modified before and during ongoing migration
1922 #
1923 # Returns: nothing on success
1924 #
1925 # Since: 1.2
1926 ##
1927 { 'command': 'migrate-set-cache-size', 'data': {'value': 'int'} }
1928
1929 ##
1930 # @query-migrate-cache-size
1931 #
1932 # query XBZRLE cache size
1933 #
1934 # Returns: XBZRLE cache size in bytes
1935 #
1936 # Since: 1.2
1937 ##
1938 { 'command': 'query-migrate-cache-size', 'returns': 'int' }
1939
1940 ##
1941 # @ObjectPropertyInfo:
1942 #
1943 # @name: the name of the property
1944 #
1945 # @type: the type of the property. This will typically come in one of four
1946 # forms:
1947 #
1948 # 1) A primitive type such as 'u8', 'u16', 'bool', 'str', or 'double'.
1949 # These types are mapped to the appropriate JSON type.
1950 #
1951 # 2) A legacy type in the form 'legacy<subtype>' where subtype is the
1952 # legacy qdev typename. These types are always treated as strings.
1953 #
1954 # 3) A child type in the form 'child<subtype>' where subtype is a qdev
1955 # device type name. Child properties create the composition tree.
1956 #
1957 # 4) A link type in the form 'link<subtype>' where subtype is a qdev
1958 # device type name. Link properties form the device model graph.
1959 #
1960 # Since: 1.2
1961 ##
1962 { 'type': 'ObjectPropertyInfo',
1963 'data': { 'name': 'str', 'type': 'str' } }
1964
1965 ##
1966 # @qom-list:
1967 #
1968 # This command will list any properties of a object given a path in the object
1969 # model.
1970 #
1971 # @path: the path within the object model. See @qom-get for a description of
1972 # this parameter.
1973 #
1974 # Returns: a list of @ObjectPropertyInfo that describe the properties of the
1975 # object.
1976 #
1977 # Since: 1.2
1978 ##
1979 { 'command': 'qom-list',
1980 'data': { 'path': 'str' },
1981 'returns': [ 'ObjectPropertyInfo' ] }
1982
1983 ##
1984 # @qom-get:
1985 #
1986 # This command will get a property from a object model path and return the
1987 # value.
1988 #
1989 # @path: The path within the object model. There are two forms of supported
1990 # paths--absolute and partial paths.
1991 #
1992 # Absolute paths are derived from the root object and can follow child<>
1993 # or link<> properties. Since they can follow link<> properties, they
1994 # can be arbitrarily long. Absolute paths look like absolute filenames
1995 # and are prefixed with a leading slash.
1996 #
1997 # Partial paths look like relative filenames. They do not begin
1998 # with a prefix. The matching rules for partial paths are subtle but
1999 # designed to make specifying objects easy. At each level of the
2000 # composition tree, the partial path is matched as an absolute path.
2001 # The first match is not returned. At least two matches are searched
2002 # for. A successful result is only returned if only one match is
2003 # found. If more than one match is found, a flag is return to
2004 # indicate that the match was ambiguous.
2005 #
2006 # @property: The property name to read
2007 #
2008 # Returns: The property value. The type depends on the property type. legacy<>
2009 # properties are returned as #str. child<> and link<> properties are
2010 # returns as #str pathnames. All integer property types (u8, u16, etc)
2011 # are returned as #int.
2012 #
2013 # Since: 1.2
2014 ##
2015 { 'command': 'qom-get',
2016 'data': { 'path': 'str', 'property': 'str' },
2017 'returns': 'visitor',
2018 'gen': 'no' }
2019
2020 ##
2021 # @qom-set:
2022 #
2023 # This command will set a property from a object model path.
2024 #
2025 # @path: see @qom-get for a description of this parameter
2026 #
2027 # @property: the property name to set
2028 #
2029 # @value: a value who's type is appropriate for the property type. See @qom-get
2030 # for a description of type mapping.
2031 #
2032 # Since: 1.2
2033 ##
2034 { 'command': 'qom-set',
2035 'data': { 'path': 'str', 'property': 'str', 'value': 'visitor' },
2036 'gen': 'no' }
2037
2038 ##
2039 # @set_password:
2040 #
2041 # Sets the password of a remote display session.
2042 #
2043 # @protocol: `vnc' to modify the VNC server password
2044 # `spice' to modify the Spice server password
2045 #
2046 # @password: the new password
2047 #
2048 # @connected: #optional how to handle existing clients when changing the
2049 # password. If nothing is specified, defaults to `keep'
2050 # `fail' to fail the command if clients are connected
2051 # `disconnect' to disconnect existing clients
2052 # `keep' to maintain existing clients
2053 #
2054 # Returns: Nothing on success
2055 # If Spice is not enabled, DeviceNotFound
2056 #
2057 # Since: 0.14.0
2058 ##
2059 { 'command': 'set_password',
2060 'data': {'protocol': 'str', 'password': 'str', '*connected': 'str'} }
2061
2062 ##
2063 # @expire_password:
2064 #
2065 # Expire the password of a remote display server.
2066 #
2067 # @protocol: the name of the remote display protocol `vnc' or `spice'
2068 #
2069 # @time: when to expire the password.
2070 # `now' to expire the password immediately
2071 # `never' to cancel password expiration
2072 # `+INT' where INT is the number of seconds from now (integer)
2073 # `INT' where INT is the absolute time in seconds
2074 #
2075 # Returns: Nothing on success
2076 # If @protocol is `spice' and Spice is not active, DeviceNotFound
2077 #
2078 # Since: 0.14.0
2079 #
2080 # Notes: Time is relative to the server and currently there is no way to
2081 # coordinate server time with client time. It is not recommended to
2082 # use the absolute time version of the @time parameter unless you're
2083 # sure you are on the same machine as the QEMU instance.
2084 ##
2085 { 'command': 'expire_password', 'data': {'protocol': 'str', 'time': 'str'} }
2086
2087 ##
2088 # @eject:
2089 #
2090 # Ejects a device from a removable drive.
2091 #
2092 # @device: The name of the device
2093 #
2094 # @force: @optional If true, eject regardless of whether the drive is locked.
2095 # If not specified, the default value is false.
2096 #
2097 # Returns: Nothing on success
2098 # If @device is not a valid block device, DeviceNotFound
2099 #
2100 # Notes: Ejecting a device will no media results in success
2101 #
2102 # Since: 0.14.0
2103 ##
2104 { 'command': 'eject', 'data': {'device': 'str', '*force': 'bool'} }
2105
2106 ##
2107 # @change-vnc-password:
2108 #
2109 # Change the VNC server password.
2110 #
2111 # @target: the new password to use with VNC authentication
2112 #
2113 # Since: 1.1
2114 #
2115 # Notes: An empty password in this command will set the password to the empty
2116 # string. Existing clients are unaffected by executing this command.
2117 ##
2118 { 'command': 'change-vnc-password', 'data': {'password': 'str'} }
2119
2120 ##
2121 # @change:
2122 #
2123 # This command is multiple commands multiplexed together.
2124 #
2125 # @device: This is normally the name of a block device but it may also be 'vnc'.
2126 # when it's 'vnc', then sub command depends on @target
2127 #
2128 # @target: If @device is a block device, then this is the new filename.
2129 # If @device is 'vnc', then if the value 'password' selects the vnc
2130 # change password command. Otherwise, this specifies a new server URI
2131 # address to listen to for VNC connections.
2132 #
2133 # @arg: If @device is a block device, then this is an optional format to open
2134 # the device with.
2135 # If @device is 'vnc' and @target is 'password', this is the new VNC
2136 # password to set. If this argument is an empty string, then no future
2137 # logins will be allowed.
2138 #
2139 # Returns: Nothing on success.
2140 # If @device is not a valid block device, DeviceNotFound
2141 # If the new block device is encrypted, DeviceEncrypted. Note that
2142 # if this error is returned, the device has been opened successfully
2143 # and an additional call to @block_passwd is required to set the
2144 # device's password. The behavior of reads and writes to the block
2145 # device between when these calls are executed is undefined.
2146 #
2147 # Notes: It is strongly recommended that this interface is not used especially
2148 # for changing block devices.
2149 #
2150 # Since: 0.14.0
2151 ##
2152 { 'command': 'change',
2153 'data': {'device': 'str', 'target': 'str', '*arg': 'str'} }
2154
2155 ##
2156 # @block_set_io_throttle:
2157 #
2158 # Change I/O throttle limits for a block drive.
2159 #
2160 # @device: The name of the device
2161 #
2162 # @bps: total throughput limit in bytes per second
2163 #
2164 # @bps_rd: read throughput limit in bytes per second
2165 #
2166 # @bps_wr: write throughput limit in bytes per second
2167 #
2168 # @iops: total I/O operations per second
2169 #
2170 # @ops_rd: read I/O operations per second
2171 #
2172 # @iops_wr: write I/O operations per second
2173 #
2174 # Returns: Nothing on success
2175 # If @device is not a valid block device, DeviceNotFound
2176 #
2177 # Since: 1.1
2178 ##
2179 { 'command': 'block_set_io_throttle',
2180 'data': { 'device': 'str', 'bps': 'int', 'bps_rd': 'int', 'bps_wr': 'int',
2181 'iops': 'int', 'iops_rd': 'int', 'iops_wr': 'int' } }
2182
2183 ##
2184 # @block-stream:
2185 #
2186 # Copy data from a backing file into a block device.
2187 #
2188 # The block streaming operation is performed in the background until the entire
2189 # backing file has been copied. This command returns immediately once streaming
2190 # has started. The status of ongoing block streaming operations can be checked
2191 # with query-block-jobs. The operation can be stopped before it has completed
2192 # using the block-job-cancel command.
2193 #
2194 # If a base file is specified then sectors are not copied from that base file and
2195 # its backing chain. When streaming completes the image file will have the base
2196 # file as its backing file. This can be used to stream a subset of the backing
2197 # file chain instead of flattening the entire image.
2198 #
2199 # On successful completion the image file is updated to drop the backing file
2200 # and the BLOCK_JOB_COMPLETED event is emitted.
2201 #
2202 # @device: the device name
2203 #
2204 # @base: #optional the common backing file name
2205 #
2206 # @speed: #optional the maximum speed, in bytes per second
2207 #
2208 # @on-error: #optional the action to take on an error (default report).
2209 # 'stop' and 'enospc' can only be used if the block device
2210 # supports io-status (see BlockInfo). Since 1.3.
2211 #
2212 # Returns: Nothing on success
2213 # If @device does not exist, DeviceNotFound
2214 #
2215 # Since: 1.1
2216 ##
2217 { 'command': 'block-stream',
2218 'data': { 'device': 'str', '*base': 'str', '*speed': 'int',
2219 '*on-error': 'BlockdevOnError' } }
2220
2221 ##
2222 # @block-job-set-speed:
2223 #
2224 # Set maximum speed for a background block operation.
2225 #
2226 # This command can only be issued when there is an active block job.
2227 #
2228 # Throttling can be disabled by setting the speed to 0.
2229 #
2230 # @device: the device name
2231 #
2232 # @speed: the maximum speed, in bytes per second, or 0 for unlimited.
2233 # Defaults to 0.
2234 #
2235 # Returns: Nothing on success
2236 # If no background operation is active on this device, DeviceNotActive
2237 #
2238 # Since: 1.1
2239 ##
2240 { 'command': 'block-job-set-speed',
2241 'data': { 'device': 'str', 'speed': 'int' } }
2242
2243 ##
2244 # @block-job-cancel:
2245 #
2246 # Stop an active background block operation.
2247 #
2248 # This command returns immediately after marking the active background block
2249 # operation for cancellation. It is an error to call this command if no
2250 # operation is in progress.
2251 #
2252 # The operation will cancel as soon as possible and then emit the
2253 # BLOCK_JOB_CANCELLED event. Before that happens the job is still visible when
2254 # enumerated using query-block-jobs.
2255 #
2256 # For streaming, the image file retains its backing file unless the streaming
2257 # operation happens to complete just as it is being cancelled. A new streaming
2258 # operation can be started at a later time to finish copying all data from the
2259 # backing file.
2260 #
2261 # @device: the device name
2262 #
2263 # @force: #optional whether to allow cancellation of a paused job (default
2264 # false). Since 1.3.
2265 #
2266 # Returns: Nothing on success
2267 # If no background operation is active on this device, DeviceNotActive
2268 #
2269 # Since: 1.1
2270 ##
2271 { 'command': 'block-job-cancel', 'data': { 'device': 'str', '*force': 'bool' } }
2272
2273 ##
2274 # @block-job-pause:
2275 #
2276 # Pause an active background block operation.
2277 #
2278 # This command returns immediately after marking the active background block
2279 # operation for pausing. It is an error to call this command if no
2280 # operation is in progress. Pausing an already paused job has no cumulative
2281 # effect; a single block-job-resume command will resume the job.
2282 #
2283 # The operation will pause as soon as possible. No event is emitted when
2284 # the operation is actually paused. Cancelling a paused job automatically
2285 # resumes it.
2286 #
2287 # @device: the device name
2288 #
2289 # Returns: Nothing on success
2290 # If no background operation is active on this device, DeviceNotActive
2291 #
2292 # Since: 1.3
2293 ##
2294 { 'command': 'block-job-pause', 'data': { 'device': 'str' } }
2295
2296 ##
2297 # @block-job-resume:
2298 #
2299 # Resume an active background block operation.
2300 #
2301 # This command returns immediately after resuming a paused background block
2302 # operation. It is an error to call this command if no operation is in
2303 # progress. Resuming an already running job is not an error.
2304 #
2305 # This command also clears the error status of the job.
2306 #
2307 # @device: the device name
2308 #
2309 # Returns: Nothing on success
2310 # If no background operation is active on this device, DeviceNotActive
2311 #
2312 # Since: 1.3
2313 ##
2314 { 'command': 'block-job-resume', 'data': { 'device': 'str' } }
2315
2316 ##
2317 # @block-job-complete:
2318 #
2319 # Manually trigger completion of an active background block operation. This
2320 # is supported for drive mirroring, where it also switches the device to
2321 # write to the target path only. The ability to complete is signaled with
2322 # a BLOCK_JOB_READY event.
2323 #
2324 # This command completes an active background block operation synchronously.
2325 # The ordering of this command's return with the BLOCK_JOB_COMPLETED event
2326 # is not defined. Note that if an I/O error occurs during the processing of
2327 # this command: 1) the command itself will fail; 2) the error will be processed
2328 # according to the rerror/werror arguments that were specified when starting
2329 # the operation.
2330 #
2331 # A cancelled or paused job cannot be completed.
2332 #
2333 # @device: the device name
2334 #
2335 # Returns: Nothing on success
2336 # If no background operation is active on this device, DeviceNotActive
2337 #
2338 # Since: 1.3
2339 ##
2340 { 'command': 'block-job-complete', 'data': { 'device': 'str' } }
2341
2342 ##
2343 # @ObjectTypeInfo:
2344 #
2345 # This structure describes a search result from @qom-list-types
2346 #
2347 # @name: the type name found in the search
2348 #
2349 # Since: 1.1
2350 #
2351 # Notes: This command is experimental and may change syntax in future releases.
2352 ##
2353 { 'type': 'ObjectTypeInfo',
2354 'data': { 'name': 'str' } }
2355
2356 ##
2357 # @qom-list-types:
2358 #
2359 # This command will return a list of types given search parameters
2360 #
2361 # @implements: if specified, only return types that implement this type name
2362 #
2363 # @abstract: if true, include abstract types in the results
2364 #
2365 # Returns: a list of @ObjectTypeInfo or an empty list if no results are found
2366 #
2367 # Since: 1.1
2368 ##
2369 { 'command': 'qom-list-types',
2370 'data': { '*implements': 'str', '*abstract': 'bool' },
2371 'returns': [ 'ObjectTypeInfo' ] }
2372
2373 ##
2374 # @DevicePropertyInfo:
2375 #
2376 # Information about device properties.
2377 #
2378 # @name: the name of the property
2379 # @type: the typename of the property
2380 #
2381 # Since: 1.2
2382 ##
2383 { 'type': 'DevicePropertyInfo',
2384 'data': { 'name': 'str', 'type': 'str' } }
2385
2386 ##
2387 # @device-list-properties:
2388 #
2389 # List properties associated with a device.
2390 #
2391 # @typename: the type name of a device
2392 #
2393 # Returns: a list of DevicePropertyInfo describing a devices properties
2394 #
2395 # Since: 1.2
2396 ##
2397 { 'command': 'device-list-properties',
2398 'data': { 'typename': 'str'},
2399 'returns': [ 'DevicePropertyInfo' ] }
2400
2401 ##
2402 # @migrate
2403 #
2404 # Migrates the current running guest to another Virtual Machine.
2405 #
2406 # @uri: the Uniform Resource Identifier of the destination VM
2407 #
2408 # @blk: #optional do block migration (full disk copy)
2409 #
2410 # @inc: #optional incremental disk copy migration
2411 #
2412 # @detach: this argument exists only for compatibility reasons and
2413 # is ignored by QEMU
2414 #
2415 # Returns: nothing on success
2416 #
2417 # Since: 0.14.0
2418 ##
2419 { 'command': 'migrate',
2420 'data': {'uri': 'str', '*blk': 'bool', '*inc': 'bool', '*detach': 'bool' } }
2421
2422 # @xen-save-devices-state:
2423 #
2424 # Save the state of all devices to file. The RAM and the block devices
2425 # of the VM are not saved by this command.
2426 #
2427 # @filename: the file to save the state of the devices to as binary
2428 # data. See xen-save-devices-state.txt for a description of the binary
2429 # format.
2430 #
2431 # Returns: Nothing on success
2432 #
2433 # Since: 1.1
2434 ##
2435 { 'command': 'xen-save-devices-state', 'data': {'filename': 'str'} }
2436
2437 ##
2438 # @xen-set-global-dirty-log
2439 #
2440 # Enable or disable the global dirty log mode.
2441 #
2442 # @enable: true to enable, false to disable.
2443 #
2444 # Returns: nothing
2445 #
2446 # Since: 1.3
2447 ##
2448 { 'command': 'xen-set-global-dirty-log', 'data': { 'enable': 'bool' } }
2449
2450 ##
2451 # @device_del:
2452 #
2453 # Remove a device from a guest
2454 #
2455 # @id: the name of the device
2456 #
2457 # Returns: Nothing on success
2458 # If @id is not a valid device, DeviceNotFound
2459 #
2460 # Notes: When this command completes, the device may not be removed from the
2461 # guest. Hot removal is an operation that requires guest cooperation.
2462 # This command merely requests that the guest begin the hot removal
2463 # process. Completion of the device removal process is signaled with a
2464 # DEVICE_DELETED event. Guest reset will automatically complete removal
2465 # for all devices.
2466 #
2467 # Since: 0.14.0
2468 ##
2469 { 'command': 'device_del', 'data': {'id': 'str'} }
2470
2471 ##
2472 # @dump-guest-memory
2473 #
2474 # Dump guest's memory to vmcore. It is a synchronous operation that can take
2475 # very long depending on the amount of guest memory. This command is only
2476 # supported on i386 and x86_64.
2477 #
2478 # @paging: if true, do paging to get guest's memory mapping. This allows
2479 # using gdb to process the core file.
2480 #
2481 # IMPORTANT: this option can make QEMU allocate several gigabytes
2482 # of RAM. This can happen for a large guest, or a
2483 # malicious guest pretending to be large.
2484 #
2485 # Also, paging=true has the following limitations:
2486 #
2487 # 1. The guest may be in a catastrophic state or can have corrupted
2488 # memory, which cannot be trusted
2489 # 2. The guest can be in real-mode even if paging is enabled. For
2490 # example, the guest uses ACPI to sleep, and ACPI sleep state
2491 # goes in real-mode
2492 #
2493 # @protocol: the filename or file descriptor of the vmcore. The supported
2494 # protocols are:
2495 #
2496 # 1. file: the protocol starts with "file:", and the following
2497 # string is the file's path.
2498 # 2. fd: the protocol starts with "fd:", and the following string
2499 # is the fd's name.
2500 #
2501 # @begin: #optional if specified, the starting physical address.
2502 #
2503 # @length: #optional if specified, the memory size, in bytes. If you don't
2504 # want to dump all guest's memory, please specify the start @begin
2505 # and @length
2506 #
2507 # Returns: nothing on success
2508 #
2509 # Since: 1.2
2510 ##
2511 { 'command': 'dump-guest-memory',
2512 'data': { 'paging': 'bool', 'protocol': 'str', '*begin': 'int',
2513 '*length': 'int' } }
2514
2515 ##
2516 # @netdev_add:
2517 #
2518 # Add a network backend.
2519 #
2520 # @type: the type of network backend. Current valid values are 'user', 'tap',
2521 # 'vde', 'socket', 'dump' and 'bridge'
2522 #
2523 # @id: the name of the new network backend
2524 #
2525 # @props: #optional a list of properties to be passed to the backend in
2526 # the format 'name=value', like 'ifname=tap0,script=no'
2527 #
2528 # Notes: The semantics of @props is not well defined. Future commands will be
2529 # introduced that provide stronger typing for backend creation.
2530 #
2531 # Since: 0.14.0
2532 #
2533 # Returns: Nothing on success
2534 # If @type is not a valid network backend, DeviceNotFound
2535 ##
2536 { 'command': 'netdev_add',
2537 'data': {'type': 'str', 'id': 'str', '*props': '**'},
2538 'gen': 'no' }
2539
2540 ##
2541 # @netdev_del:
2542 #
2543 # Remove a network backend.
2544 #
2545 # @id: the name of the network backend to remove
2546 #
2547 # Returns: Nothing on success
2548 # If @id is not a valid network backend, DeviceNotFound
2549 #
2550 # Since: 0.14.0
2551 ##
2552 { 'command': 'netdev_del', 'data': {'id': 'str'} }
2553
2554 ##
2555 # @NetdevNoneOptions
2556 #
2557 # Use it alone to have zero network devices.
2558 #
2559 # Since 1.2
2560 ##
2561 { 'type': 'NetdevNoneOptions',
2562 'data': { } }
2563
2564 ##
2565 # @NetLegacyNicOptions
2566 #
2567 # Create a new Network Interface Card.
2568 #
2569 # @netdev: #optional id of -netdev to connect to
2570 #
2571 # @macaddr: #optional MAC address
2572 #
2573 # @model: #optional device model (e1000, rtl8139, virtio etc.)
2574 #
2575 # @addr: #optional PCI device address
2576 #
2577 # @vectors: #optional number of MSI-x vectors, 0 to disable MSI-X
2578 #
2579 # Since 1.2
2580 ##
2581 { 'type': 'NetLegacyNicOptions',
2582 'data': {
2583 '*netdev': 'str',
2584 '*macaddr': 'str',
2585 '*model': 'str',
2586 '*addr': 'str',
2587 '*vectors': 'uint32' } }
2588
2589 ##
2590 # @String
2591 #
2592 # A fat type wrapping 'str', to be embedded in lists.
2593 #
2594 # Since 1.2
2595 ##
2596 { 'type': 'String',
2597 'data': {
2598 'str': 'str' } }
2599
2600 ##
2601 # @NetdevUserOptions
2602 #
2603 # Use the user mode network stack which requires no administrator privilege to
2604 # run.
2605 #
2606 # @hostname: #optional client hostname reported by the builtin DHCP server
2607 #
2608 # @restrict: #optional isolate the guest from the host
2609 #
2610 # @ip: #optional legacy parameter, use net= instead
2611 #
2612 # @net: #optional IP address and optional netmask
2613 #
2614 # @host: #optional guest-visible address of the host
2615 #
2616 # @tftp: #optional root directory of the built-in TFTP server
2617 #
2618 # @bootfile: #optional BOOTP filename, for use with tftp=
2619 #
2620 # @dhcpstart: #optional the first of the 16 IPs the built-in DHCP server can
2621 # assign
2622 #
2623 # @dns: #optional guest-visible address of the virtual nameserver
2624 #
2625 # @dnssearch: #optional list of DNS suffixes to search, passed as DHCP option
2626 # to the guest
2627 #
2628 # @smb: #optional root directory of the built-in SMB server
2629 #
2630 # @smbserver: #optional IP address of the built-in SMB server
2631 #
2632 # @hostfwd: #optional redirect incoming TCP or UDP host connections to guest
2633 # endpoints
2634 #
2635 # @guestfwd: #optional forward guest TCP connections
2636 #
2637 # Since 1.2
2638 ##
2639 { 'type': 'NetdevUserOptions',
2640 'data': {
2641 '*hostname': 'str',
2642 '*restrict': 'bool',
2643 '*ip': 'str',
2644 '*net': 'str',
2645 '*host': 'str',
2646 '*tftp': 'str',
2647 '*bootfile': 'str',
2648 '*dhcpstart': 'str',
2649 '*dns': 'str',
2650 '*dnssearch': ['String'],
2651 '*smb': 'str',
2652 '*smbserver': 'str',
2653 '*hostfwd': ['String'],
2654 '*guestfwd': ['String'] } }
2655
2656 ##
2657 # @NetdevTapOptions
2658 #
2659 # Connect the host TAP network interface name to the VLAN.
2660 #
2661 # @ifname: #optional interface name
2662 #
2663 # @fd: #optional file descriptor of an already opened tap
2664 #
2665 # @fds: #optional multiple file descriptors of already opened multiqueue capable
2666 # tap
2667 #
2668 # @script: #optional script to initialize the interface
2669 #
2670 # @downscript: #optional script to shut down the interface
2671 #
2672 # @helper: #optional command to execute to configure bridge
2673 #
2674 # @sndbuf: #optional send buffer limit. Understands [TGMKkb] suffixes.
2675 #
2676 # @vnet_hdr: #optional enable the IFF_VNET_HDR flag on the tap interface
2677 #
2678 # @vhost: #optional enable vhost-net network accelerator
2679 #
2680 # @vhostfd: #optional file descriptor of an already opened vhost net device
2681 #
2682 # @vhostfds: #optional file descriptors of multiple already opened vhost net
2683 # devices
2684 #
2685 # @vhostforce: #optional vhost on for non-MSIX virtio guests
2686 #
2687 # @queues: #optional number of queues to be created for multiqueue capable tap
2688 #
2689 # Since 1.2
2690 ##
2691 { 'type': 'NetdevTapOptions',
2692 'data': {
2693 '*ifname': 'str',
2694 '*fd': 'str',
2695 '*fds': 'str',
2696 '*script': 'str',
2697 '*downscript': 'str',
2698 '*helper': 'str',
2699 '*sndbuf': 'size',
2700 '*vnet_hdr': 'bool',
2701 '*vhost': 'bool',
2702 '*vhostfd': 'str',
2703 '*vhostfds': 'str',
2704 '*vhostforce': 'bool',
2705 '*queues': 'uint32'} }
2706
2707 ##
2708 # @NetdevSocketOptions
2709 #
2710 # Connect the VLAN to a remote VLAN in another QEMU virtual machine using a TCP
2711 # socket connection.
2712 #
2713 # @fd: #optional file descriptor of an already opened socket
2714 #
2715 # @listen: #optional port number, and optional hostname, to listen on
2716 #
2717 # @connect: #optional port number, and optional hostname, to connect to
2718 #
2719 # @mcast: #optional UDP multicast address and port number
2720 #
2721 # @localaddr: #optional source address and port for multicast and udp packets
2722 #
2723 # @udp: #optional UDP unicast address and port number
2724 #
2725 # Since 1.2
2726 ##
2727 { 'type': 'NetdevSocketOptions',
2728 'data': {
2729 '*fd': 'str',
2730 '*listen': 'str',
2731 '*connect': 'str',
2732 '*mcast': 'str',
2733 '*localaddr': 'str',
2734 '*udp': 'str' } }
2735
2736 ##
2737 # @NetdevVdeOptions
2738 #
2739 # Connect the VLAN to a vde switch running on the host.
2740 #
2741 # @sock: #optional socket path
2742 #
2743 # @port: #optional port number
2744 #
2745 # @group: #optional group owner of socket
2746 #
2747 # @mode: #optional permissions for socket
2748 #
2749 # Since 1.2
2750 ##
2751 { 'type': 'NetdevVdeOptions',
2752 'data': {
2753 '*sock': 'str',
2754 '*port': 'uint16',
2755 '*group': 'str',
2756 '*mode': 'uint16' } }
2757
2758 ##
2759 # @NetdevDumpOptions
2760 #
2761 # Dump VLAN network traffic to a file.
2762 #
2763 # @len: #optional per-packet size limit (64k default). Understands [TGMKkb]
2764 # suffixes.
2765 #
2766 # @file: #optional dump file path (default is qemu-vlan0.pcap)
2767 #
2768 # Since 1.2
2769 ##
2770 { 'type': 'NetdevDumpOptions',
2771 'data': {
2772 '*len': 'size',
2773 '*file': 'str' } }
2774
2775 ##
2776 # @NetdevBridgeOptions
2777 #
2778 # Connect a host TAP network interface to a host bridge device.
2779 #
2780 # @br: #optional bridge name
2781 #
2782 # @helper: #optional command to execute to configure bridge
2783 #
2784 # Since 1.2
2785 ##
2786 { 'type': 'NetdevBridgeOptions',
2787 'data': {
2788 '*br': 'str',
2789 '*helper': 'str' } }
2790
2791 ##
2792 # @NetdevHubPortOptions
2793 #
2794 # Connect two or more net clients through a software hub.
2795 #
2796 # @hubid: hub identifier number
2797 #
2798 # Since 1.2
2799 ##
2800 { 'type': 'NetdevHubPortOptions',
2801 'data': {
2802 'hubid': 'int32' } }
2803
2804 ##
2805 # @NetClientOptions
2806 #
2807 # A discriminated record of network device traits.
2808 #
2809 # Since 1.2
2810 ##
2811 { 'union': 'NetClientOptions',
2812 'data': {
2813 'none': 'NetdevNoneOptions',
2814 'nic': 'NetLegacyNicOptions',
2815 'user': 'NetdevUserOptions',
2816 'tap': 'NetdevTapOptions',
2817 'socket': 'NetdevSocketOptions',
2818 'vde': 'NetdevVdeOptions',
2819 'dump': 'NetdevDumpOptions',
2820 'bridge': 'NetdevBridgeOptions',
2821 'hubport': 'NetdevHubPortOptions' } }
2822
2823 ##
2824 # @NetLegacy
2825 #
2826 # Captures the configuration of a network device; legacy.
2827 #
2828 # @vlan: #optional vlan number
2829 #
2830 # @id: #optional identifier for monitor commands
2831 #
2832 # @name: #optional identifier for monitor commands, ignored if @id is present
2833 #
2834 # @opts: device type specific properties (legacy)
2835 #
2836 # Since 1.2
2837 ##
2838 { 'type': 'NetLegacy',
2839 'data': {
2840 '*vlan': 'int32',
2841 '*id': 'str',
2842 '*name': 'str',
2843 'opts': 'NetClientOptions' } }
2844
2845 ##
2846 # @Netdev
2847 #
2848 # Captures the configuration of a network device.
2849 #
2850 # @id: identifier for monitor commands.
2851 #
2852 # @opts: device type specific properties
2853 #
2854 # Since 1.2
2855 ##
2856 { 'type': 'Netdev',
2857 'data': {
2858 'id': 'str',
2859 'opts': 'NetClientOptions' } }
2860
2861 ##
2862 # @InetSocketAddress
2863 #
2864 # Captures a socket address or address range in the Internet namespace.
2865 #
2866 # @host: host part of the address
2867 #
2868 # @port: port part of the address, or lowest port if @to is present
2869 #
2870 # @to: highest port to try
2871 #
2872 # @ipv4: whether to accept IPv4 addresses, default try both IPv4 and IPv6
2873 # #optional
2874 #
2875 # @ipv6: whether to accept IPv6 addresses, default try both IPv4 and IPv6
2876 # #optional
2877 #
2878 # Since 1.3
2879 ##
2880 { 'type': 'InetSocketAddress',
2881 'data': {
2882 'host': 'str',
2883 'port': 'str',
2884 '*to': 'uint16',
2885 '*ipv4': 'bool',
2886 '*ipv6': 'bool' } }
2887
2888 ##
2889 # @UnixSocketAddress
2890 #
2891 # Captures a socket address in the local ("Unix socket") namespace.
2892 #
2893 # @path: filesystem path to use
2894 #
2895 # Since 1.3
2896 ##
2897 { 'type': 'UnixSocketAddress',
2898 'data': {
2899 'path': 'str' } }
2900
2901 ##
2902 # @SocketAddress
2903 #
2904 # Captures the address of a socket, which could also be a named file descriptor
2905 #
2906 # Since 1.3
2907 ##
2908 { 'union': 'SocketAddress',
2909 'data': {
2910 'inet': 'InetSocketAddress',
2911 'unix': 'UnixSocketAddress',
2912 'fd': 'String' } }
2913
2914 ##
2915 # @getfd:
2916 #
2917 # Receive a file descriptor via SCM rights and assign it a name
2918 #
2919 # @fdname: file descriptor name
2920 #
2921 # Returns: Nothing on success
2922 #
2923 # Since: 0.14.0
2924 #
2925 # Notes: If @fdname already exists, the file descriptor assigned to
2926 # it will be closed and replaced by the received file
2927 # descriptor.
2928 # The 'closefd' command can be used to explicitly close the
2929 # file descriptor when it is no longer needed.
2930 ##
2931 { 'command': 'getfd', 'data': {'fdname': 'str'} }
2932
2933 ##
2934 # @closefd:
2935 #
2936 # Close a file descriptor previously passed via SCM rights
2937 #
2938 # @fdname: file descriptor name
2939 #
2940 # Returns: Nothing on success
2941 #
2942 # Since: 0.14.0
2943 ##
2944 { 'command': 'closefd', 'data': {'fdname': 'str'} }
2945
2946 ##
2947 # @MachineInfo:
2948 #
2949 # Information describing a machine.
2950 #
2951 # @name: the name of the machine
2952 #
2953 # @alias: #optional an alias for the machine name
2954 #
2955 # @default: #optional whether the machine is default
2956 #
2957 # @cpu-max: maximum number of CPUs supported by the machine type
2958 # (since 1.5.0)
2959 #
2960 # Since: 1.2.0
2961 ##
2962 { 'type': 'MachineInfo',
2963 'data': { 'name': 'str', '*alias': 'str',
2964 '*is-default': 'bool', 'cpu-max': 'int' } }
2965
2966 ##
2967 # @query-machines:
2968 #
2969 # Return a list of supported machines
2970 #
2971 # Returns: a list of MachineInfo
2972 #
2973 # Since: 1.2.0
2974 ##
2975 { 'command': 'query-machines', 'returns': ['MachineInfo'] }
2976
2977 ##
2978 # @CpuDefinitionInfo:
2979 #
2980 # Virtual CPU definition.
2981 #
2982 # @name: the name of the CPU definition
2983 #
2984 # Since: 1.2.0
2985 ##
2986 { 'type': 'CpuDefinitionInfo',
2987 'data': { 'name': 'str' } }
2988
2989 ##
2990 # @query-cpu-definitions:
2991 #
2992 # Return a list of supported virtual CPU definitions
2993 #
2994 # Returns: a list of CpuDefInfo
2995 #
2996 # Since: 1.2.0
2997 ##
2998 { 'command': 'query-cpu-definitions', 'returns': ['CpuDefinitionInfo'] }
2999
3000 # @AddfdInfo:
3001 #
3002 # Information about a file descriptor that was added to an fd set.
3003 #
3004 # @fdset-id: The ID of the fd set that @fd was added to.
3005 #
3006 # @fd: The file descriptor that was received via SCM rights and
3007 # added to the fd set.
3008 #
3009 # Since: 1.2.0
3010 ##
3011 { 'type': 'AddfdInfo', 'data': {'fdset-id': 'int', 'fd': 'int'} }
3012
3013 ##
3014 # @add-fd:
3015 #
3016 # Add a file descriptor, that was passed via SCM rights, to an fd set.
3017 #
3018 # @fdset-id: #optional The ID of the fd set to add the file descriptor to.
3019 #
3020 # @opaque: #optional A free-form string that can be used to describe the fd.
3021 #
3022 # Returns: @AddfdInfo on success
3023 # If file descriptor was not received, FdNotSupplied
3024 # If @fdset-id is a negative value, InvalidParameterValue
3025 #
3026 # Notes: The list of fd sets is shared by all monitor connections.
3027 #
3028 # If @fdset-id is not specified, a new fd set will be created.
3029 #
3030 # Since: 1.2.0
3031 ##
3032 { 'command': 'add-fd', 'data': {'*fdset-id': 'int', '*opaque': 'str'},
3033 'returns': 'AddfdInfo' }
3034
3035 ##
3036 # @remove-fd:
3037 #
3038 # Remove a file descriptor from an fd set.
3039 #
3040 # @fdset-id: The ID of the fd set that the file descriptor belongs to.
3041 #
3042 # @fd: #optional The file descriptor that is to be removed.
3043 #
3044 # Returns: Nothing on success
3045 # If @fdset-id or @fd is not found, FdNotFound
3046 #
3047 # Since: 1.2.0
3048 #
3049 # Notes: The list of fd sets is shared by all monitor connections.
3050 #
3051 # If @fd is not specified, all file descriptors in @fdset-id
3052 # will be removed.
3053 ##
3054 { 'command': 'remove-fd', 'data': {'fdset-id': 'int', '*fd': 'int'} }
3055
3056 ##
3057 # @FdsetFdInfo:
3058 #
3059 # Information about a file descriptor that belongs to an fd set.
3060 #
3061 # @fd: The file descriptor value.
3062 #
3063 # @opaque: #optional A free-form string that can be used to describe the fd.
3064 #
3065 # Since: 1.2.0
3066 ##
3067 { 'type': 'FdsetFdInfo',
3068 'data': {'fd': 'int', '*opaque': 'str'} }
3069
3070 ##
3071 # @FdsetInfo:
3072 #
3073 # Information about an fd set.
3074 #
3075 # @fdset-id: The ID of the fd set.
3076 #
3077 # @fds: A list of file descriptors that belong to this fd set.
3078 #
3079 # Since: 1.2.0
3080 ##
3081 { 'type': 'FdsetInfo',
3082 'data': {'fdset-id': 'int', 'fds': ['FdsetFdInfo']} }
3083
3084 ##
3085 # @query-fdsets:
3086 #
3087 # Return information describing all fd sets.
3088 #
3089 # Returns: A list of @FdsetInfo
3090 #
3091 # Since: 1.2.0
3092 #
3093 # Note: The list of fd sets is shared by all monitor connections.
3094 #
3095 ##
3096 { 'command': 'query-fdsets', 'returns': ['FdsetInfo'] }
3097
3098 ##
3099 # @TargetInfo:
3100 #
3101 # Information describing the QEMU target.
3102 #
3103 # @arch: the target architecture (eg "x86_64", "i386", etc)
3104 #
3105 # Since: 1.2.0
3106 ##
3107 { 'type': 'TargetInfo',
3108 'data': { 'arch': 'str' } }
3109
3110 ##
3111 # @query-target:
3112 #
3113 # Return information about the target for this QEMU
3114 #
3115 # Returns: TargetInfo
3116 #
3117 # Since: 1.2.0
3118 ##
3119 { 'command': 'query-target', 'returns': 'TargetInfo' }
3120
3121 ##
3122 # @QKeyCode:
3123 #
3124 # An enumeration of key name.
3125 #
3126 # This is used by the send-key command.
3127 #
3128 # Since: 1.3.0
3129 ##
3130 { 'enum': 'QKeyCode',
3131 'data': [ 'shift', 'shift_r', 'alt', 'alt_r', 'altgr', 'altgr_r', 'ctrl',
3132 'ctrl_r', 'menu', 'esc', '1', '2', '3', '4', '5', '6', '7', '8',
3133 '9', '0', 'minus', 'equal', 'backspace', 'tab', 'q', 'w', 'e',
3134 'r', 't', 'y', 'u', 'i', 'o', 'p', 'bracket_left', 'bracket_right',
3135 'ret', 'a', 's', 'd', 'f', 'g', 'h', 'j', 'k', 'l', 'semicolon',
3136 'apostrophe', 'grave_accent', 'backslash', 'z', 'x', 'c', 'v', 'b',
3137 'n', 'm', 'comma', 'dot', 'slash', 'asterisk', 'spc', 'caps_lock',
3138 'f1', 'f2', 'f3', 'f4', 'f5', 'f6', 'f7', 'f8', 'f9', 'f10',
3139 'num_lock', 'scroll_lock', 'kp_divide', 'kp_multiply',
3140 'kp_subtract', 'kp_add', 'kp_enter', 'kp_decimal', 'sysrq', 'kp_0',
3141 'kp_1', 'kp_2', 'kp_3', 'kp_4', 'kp_5', 'kp_6', 'kp_7', 'kp_8',
3142 'kp_9', 'less', 'f11', 'f12', 'print', 'home', 'pgup', 'pgdn', 'end',
3143 'left', 'up', 'down', 'right', 'insert', 'delete', 'stop', 'again',
3144 'props', 'undo', 'front', 'copy', 'open', 'paste', 'find', 'cut',
3145 'lf', 'help', 'meta_l', 'meta_r', 'compose' ] }
3146
3147 ##
3148 # @KeyValue
3149 #
3150 # Represents a keyboard key.
3151 #
3152 # Since: 1.3.0
3153 ##
3154 { 'union': 'KeyValue',
3155 'data': {
3156 'number': 'int',
3157 'qcode': 'QKeyCode' } }
3158
3159 ##
3160 # @send-key:
3161 #
3162 # Send keys to guest.
3163 #
3164 # @keys: An array of @KeyValue elements. All @KeyValues in this array are
3165 # simultaneously sent to the guest. A @KeyValue.number value is sent
3166 # directly to the guest, while @KeyValue.qcode must be a valid
3167 # @QKeyCode value
3168 #
3169 # @hold-time: #optional time to delay key up events, milliseconds. Defaults
3170 # to 100
3171 #
3172 # Returns: Nothing on success
3173 # If key is unknown or redundant, InvalidParameter
3174 #
3175 # Since: 1.3.0
3176 #
3177 ##
3178 { 'command': 'send-key',
3179 'data': { 'keys': ['KeyValue'], '*hold-time': 'int' } }
3180
3181 ##
3182 # @screendump:
3183 #
3184 # Write a PPM of the VGA screen to a file.
3185 #
3186 # @filename: the path of a new PPM file to store the image
3187 #
3188 # Returns: Nothing on success
3189 #
3190 # Since: 0.14.0
3191 ##
3192 { 'command': 'screendump', 'data': {'filename': 'str'} }
3193
3194 ##
3195 # @nbd-server-start:
3196 #
3197 # Start an NBD server listening on the given host and port. Block
3198 # devices can then be exported using @nbd-server-add. The NBD
3199 # server will present them as named exports; for example, another
3200 # QEMU instance could refer to them as "nbd:HOST:PORT:exportname=NAME".
3201 #
3202 # @addr: Address on which to listen.
3203 #
3204 # Returns: error if the server is already running.
3205 #
3206 # Since: 1.3.0
3207 ##
3208 { 'command': 'nbd-server-start',
3209 'data': { 'addr': 'SocketAddress' } }
3210
3211 ##
3212 # @nbd-server-add:
3213 #
3214 # Export a device to QEMU's embedded NBD server.
3215 #
3216 # @device: Block device to be exported
3217 #
3218 # @writable: Whether clients should be able to write to the device via the
3219 # NBD connection (default false). #optional
3220 #
3221 # Returns: error if the device is already marked for export.
3222 #
3223 # Since: 1.3.0
3224 ##
3225 { 'command': 'nbd-server-add', 'data': {'device': 'str', '*writable': 'bool'} }
3226
3227 ##
3228 # @nbd-server-stop:
3229 #
3230 # Stop QEMU's embedded NBD server, and unregister all devices previously
3231 # added via @nbd-server-add.
3232 #
3233 # Since: 1.3.0
3234 ##
3235 { 'command': 'nbd-server-stop' }
3236
3237 ##
3238 # @ChardevFile:
3239 #
3240 # Configuration info for file chardevs.
3241 #
3242 # @in: #optional The name of the input file
3243 # @out: The name of the output file
3244 #
3245 # Since: 1.4
3246 ##
3247 { 'type': 'ChardevFile', 'data': { '*in' : 'str',
3248 'out' : 'str' } }
3249
3250 ##
3251 # @ChardevHostdev:
3252 #
3253 # Configuration info for device and pipe chardevs.
3254 #
3255 # @device: The name of the special file for the device,
3256 # i.e. /dev/ttyS0 on Unix or COM1: on Windows
3257 # @type: What kind of device this is.
3258 #
3259 # Since: 1.4
3260 ##
3261 { 'type': 'ChardevHostdev', 'data': { 'device' : 'str' } }
3262
3263 ##
3264 # @ChardevSocket:
3265 #
3266 # Configuration info for (stream) socket chardevs.
3267 #
3268 # @addr: socket address to listen on (server=true)
3269 # or connect to (server=false)
3270 # @server: #optional create server socket (default: true)
3271 # @wait: #optional wait for incoming connection on server
3272 # sockets (default: false).
3273 # @nodelay: #optional set TCP_NODELAY socket option (default: false)
3274 # @telnet: #optional enable telnet protocol on server
3275 # sockets (default: false)
3276 #
3277 # Since: 1.4
3278 ##
3279 { 'type': 'ChardevSocket', 'data': { 'addr' : 'SocketAddress',
3280 '*server' : 'bool',
3281 '*wait' : 'bool',
3282 '*nodelay' : 'bool',
3283 '*telnet' : 'bool' } }
3284
3285 ##
3286 # @ChardevUdp:
3287 #
3288 # Configuration info for datagram socket chardevs.
3289 #
3290 # @remote: remote address
3291 # @local: #optional local address
3292 #
3293 # Since: 1.5
3294 ##
3295 { 'type': 'ChardevUdp', 'data': { 'remote' : 'SocketAddress',
3296 '*local' : 'SocketAddress' } }
3297
3298 ##
3299 # @ChardevMux:
3300 #
3301 # Configuration info for mux chardevs.
3302 #
3303 # @chardev: name of the base chardev.
3304 #
3305 # Since: 1.5
3306 ##
3307 { 'type': 'ChardevMux', 'data': { 'chardev' : 'str' } }
3308
3309 ##
3310 # @ChardevStdio:
3311 #
3312 # Configuration info for stdio chardevs.
3313 #
3314 # @signal: #optional Allow signals (such as SIGINT triggered by ^C)
3315 # be delivered to qemu. Default: true in -nographic mode,
3316 # false otherwise.
3317 #
3318 # Since: 1.5
3319 ##
3320 { 'type': 'ChardevStdio', 'data': { '*signal' : 'bool' } }
3321
3322 ##
3323 # @ChardevSpiceChannel:
3324 #
3325 # Configuration info for spice vm channel chardevs.
3326 #
3327 # @type: kind of channel (for example vdagent).
3328 #
3329 # Since: 1.5
3330 ##
3331 { 'type': 'ChardevSpiceChannel', 'data': { 'type' : 'str' } }
3332
3333 ##
3334 # @ChardevSpicePort:
3335 #
3336 # Configuration info for spice port chardevs.
3337 #
3338 # @fqdn: name of the channel (see docs/spice-port-fqdn.txt)
3339 #
3340 # Since: 1.5
3341 ##
3342 { 'type': 'ChardevSpicePort', 'data': { 'fqdn' : 'str' } }
3343
3344 ##
3345 # @ChardevVC:
3346 #
3347 # Configuration info for virtual console chardevs.
3348 #
3349 # @width: console width, in pixels
3350 # @height: console height, in pixels
3351 # @cols: console width, in chars
3352 # @rows: console height, in chars
3353 #
3354 # Since: 1.5
3355 ##
3356 { 'type': 'ChardevVC', 'data': { '*width' : 'int',
3357 '*height' : 'int',
3358 '*cols' : 'int',
3359 '*rows' : 'int' } }
3360
3361 ##
3362 # @ChardevMemory:
3363 #
3364 # Configuration info for memory chardevs
3365 #
3366 # @size: #optional Ringbuffer size, must be power of two, default is 65536
3367 #
3368 # Since: 1.5
3369 ##
3370 { 'type': 'ChardevMemory', 'data': { '*size' : 'int' } }
3371
3372 ##
3373 # @ChardevBackend:
3374 #
3375 # Configuration info for the new chardev backend.
3376 #
3377 # Since: 1.4
3378 ##
3379 { 'type': 'ChardevDummy', 'data': { } }
3380
3381 { 'union': 'ChardevBackend', 'data': { 'file' : 'ChardevFile',
3382 'serial' : 'ChardevHostdev',
3383 'parallel': 'ChardevHostdev',
3384 'pipe' : 'ChardevHostdev',
3385 'socket' : 'ChardevSocket',
3386 'udp' : 'ChardevUdp',
3387 'pty' : 'ChardevDummy',
3388 'null' : 'ChardevDummy',
3389 'mux' : 'ChardevMux',
3390 'msmouse': 'ChardevDummy',
3391 'braille': 'ChardevDummy',
3392 'stdio' : 'ChardevStdio',
3393 'console': 'ChardevDummy',
3394 'spicevmc' : 'ChardevSpiceChannel',
3395 'spiceport' : 'ChardevSpicePort',
3396 'vc' : 'ChardevVC',
3397 'memory' : 'ChardevMemory' } }
3398
3399 ##
3400 # @ChardevReturn:
3401 #
3402 # Return info about the chardev backend just created.
3403 #
3404 # @pty: #optional name of the slave pseudoterminal device, present if
3405 # and only if a chardev of type 'pty' was created
3406 #
3407 # Since: 1.4
3408 ##
3409 { 'type' : 'ChardevReturn', 'data': { '*pty' : 'str' } }
3410
3411 ##
3412 # @chardev-add:
3413 #
3414 # Add a character device backend
3415 #
3416 # @id: the chardev's ID, must be unique
3417 # @backend: backend type and parameters
3418 #
3419 # Returns: ChardevReturn.
3420 #
3421 # Since: 1.4
3422 ##
3423 { 'command': 'chardev-add', 'data': {'id' : 'str',
3424 'backend' : 'ChardevBackend' },
3425 'returns': 'ChardevReturn' }
3426
3427 ##
3428 # @chardev-remove:
3429 #
3430 # Remove a character device backend
3431 #
3432 # @id: the chardev's ID, must exist and not be in use
3433 #
3434 # Returns: Nothing on success
3435 #
3436 # Since: 1.4
3437 ##
3438 { 'command': 'chardev-remove', 'data': {'id': 'str'} }
3439
3440 ##
3441 # @TpmModel:
3442 #
3443 # An enumeration of TPM models
3444 #
3445 # @tpm-tis: TPM TIS model
3446 #
3447 # Since: 1.5
3448 ##
3449 { 'enum': 'TpmModel', 'data': [ 'tpm-tis' ] }
3450
3451 ##
3452 # @query-tpm-models:
3453 #
3454 # Return a list of supported TPM models
3455 #
3456 # Returns: a list of TpmModel
3457 #
3458 # Since: 1.5
3459 ##
3460 { 'command': 'query-tpm-models', 'returns': ['TpmModel'] }
3461
3462 ##
3463 # @TpmType:
3464 #
3465 # An enumeration of TPM types
3466 #
3467 # @passthrough: TPM passthrough type
3468 #
3469 # Since: 1.5
3470 ##
3471 { 'enum': 'TpmType', 'data': [ 'passthrough' ] }
3472
3473 ##
3474 # @query-tpm-types:
3475 #
3476 # Return a list of supported TPM types
3477 #
3478 # Returns: a list of TpmType
3479 #
3480 # Since: 1.5
3481 ##
3482 { 'command': 'query-tpm-types', 'returns': ['TpmType'] }
3483
3484 ##
3485 # @TPMPassthroughOptions:
3486 #
3487 # Information about the TPM passthrough type
3488 #
3489 # @path: #optional string describing the path used for accessing the TPM device
3490 #
3491 # @cancel-path: #optional string showing the TPM's sysfs cancel file
3492 # for cancellation of TPM commands while they are executing
3493 #
3494 # Since: 1.5
3495 ##
3496 { 'type': 'TPMPassthroughOptions', 'data': { '*path' : 'str',
3497 '*cancel-path' : 'str'} }
3498
3499 ##
3500 # @TpmTypeOptions:
3501 #
3502 # A union referencing different TPM backend types' configuration options
3503 #
3504 # @passthrough: The configuration options for the TPM passthrough type
3505 #
3506 # Since: 1.5
3507 ##
3508 { 'union': 'TpmTypeOptions',
3509 'data': { 'passthrough' : 'TPMPassthroughOptions' } }
3510
3511 ##
3512 # @TpmInfo:
3513 #
3514 # Information about the TPM
3515 #
3516 # @id: The Id of the TPM
3517 #
3518 # @model: The TPM frontend model
3519 #
3520 # @options: The TPM (backend) type configuration options
3521 #
3522 # Since: 1.5
3523 ##
3524 { 'type': 'TPMInfo',
3525 'data': {'id': 'str',
3526 'model': 'TpmModel',
3527 'options': 'TpmTypeOptions' } }
3528
3529 ##
3530 # @query-tpm:
3531 #
3532 # Return information about the TPM device
3533 #
3534 # Returns: @TPMInfo on success
3535 #
3536 # Since: 1.5
3537 ##
3538 { 'command': 'query-tpm', 'returns': ['TPMInfo'] }
3539
3540 ##
3541 # @AcpiTableOptions
3542 #
3543 # Specify an ACPI table on the command line to load.
3544 #
3545 # At most one of @file and @data can be specified. The list of files specified
3546 # by any one of them is loaded and concatenated in order. If both are omitted,
3547 # @data is implied.
3548 #
3549 # Other fields / optargs can be used to override fields of the generic ACPI
3550 # table header; refer to the ACPI specification 5.0, section 5.2.6 System
3551 # Description Table Header. If a header field is not overridden, then the
3552 # corresponding value from the concatenated blob is used (in case of @file), or
3553 # it is filled in with a hard-coded value (in case of @data).
3554 #
3555 # String fields are copied into the matching ACPI member from lowest address
3556 # upwards, and silently truncated / NUL-padded to length.
3557 #
3558 # @sig: #optional table signature / identifier (4 bytes)
3559 #
3560 # @rev: #optional table revision number (dependent on signature, 1 byte)
3561 #
3562 # @oem_id: #optional OEM identifier (6 bytes)
3563 #
3564 # @oem_table_id: #optional OEM table identifier (8 bytes)
3565 #
3566 # @oem_rev: #optional OEM-supplied revision number (4 bytes)
3567 #
3568 # @asl_compiler_id: #optional identifier of the utility that created the table
3569 # (4 bytes)
3570 #
3571 # @asl_compiler_rev: #optional revision number of the utility that created the
3572 # table (4 bytes)
3573 #
3574 # @file: #optional colon (:) separated list of pathnames to load and
3575 # concatenate as table data. The resultant binary blob is expected to
3576 # have an ACPI table header. At least one file is required. This field
3577 # excludes @data.
3578 #
3579 # @data: #optional colon (:) separated list of pathnames to load and
3580 # concatenate as table data. The resultant binary blob must not have an
3581 # ACPI table header. At least one file is required. This field excludes
3582 # @file.
3583 #
3584 # Since 1.5
3585 ##
3586 { 'type': 'AcpiTableOptions',
3587 'data': {
3588 '*sig': 'str',
3589 '*rev': 'uint8',
3590 '*oem_id': 'str',
3591 '*oem_table_id': 'str',
3592 '*oem_rev': 'uint32',
3593 '*asl_compiler_id': 'str',
3594 '*asl_compiler_rev': 'uint32',
3595 '*file': 'str',
3596 '*data': 'str' }}
3597
3598 ##
3599 # @CommandLineParameterType:
3600 #
3601 # Possible types for an option parameter.
3602 #
3603 # @string: accepts a character string
3604 #
3605 # @boolean: accepts "on" or "off"
3606 #
3607 # @number: accepts a number
3608 #
3609 # @size: accepts a number followed by an optional suffix (K)ilo,
3610 # (M)ega, (G)iga, (T)era
3611 #
3612 # Since 1.5
3613 ##
3614 { 'enum': 'CommandLineParameterType',
3615 'data': ['string', 'boolean', 'number', 'size'] }
3616
3617 ##
3618 # @CommandLineParameterInfo:
3619 #
3620 # Details about a single parameter of a command line option.
3621 #
3622 # @name: parameter name
3623 #
3624 # @type: parameter @CommandLineParameterType
3625 #
3626 # @help: #optional human readable text string, not suitable for parsing.
3627 #
3628 # Since 1.5
3629 ##
3630 { 'type': 'CommandLineParameterInfo',
3631 'data': { 'name': 'str',
3632 'type': 'CommandLineParameterType',
3633 '*help': 'str' } }
3634
3635 ##
3636 # @CommandLineOptionInfo:
3637 #
3638 # Details about a command line option, including its list of parameter details
3639 #
3640 # @option: option name
3641 #
3642 # @parameters: an array of @CommandLineParameterInfo
3643 #
3644 # Since 1.5
3645 ##
3646 { 'type': 'CommandLineOptionInfo',
3647 'data': { 'option': 'str', 'parameters': ['CommandLineParameterInfo'] } }
3648
3649 ##
3650 # @query-command-line-options:
3651 #
3652 # Query command line option schema.
3653 #
3654 # @option: #optional option name
3655 #
3656 # Returns: list of @CommandLineOptionInfo for all options (or for the given
3657 # @option). Returns an error if the given @option doesn't exist.
3658 #
3659 # Since 1.5
3660 ##
3661 {'command': 'query-command-line-options', 'data': { '*option': 'str' },
3662 'returns': ['CommandLineOptionInfo'] }
3663
3664 ##
3665 # @X86CPURegister32
3666 #
3667 # A X86 32-bit register
3668 #
3669 # Since: 1.5
3670 ##
3671 { 'enum': 'X86CPURegister32',
3672 'data': [ 'EAX', 'EBX', 'ECX', 'EDX', 'ESP', 'EBP', 'ESI', 'EDI' ] }
3673
3674 ##
3675 # @X86CPUFeatureWordInfo
3676 #
3677 # Information about a X86 CPU feature word
3678 #
3679 # @cpuid-input-eax: Input EAX value for CPUID instruction for that feature word
3680 #
3681 # @cpuid-input-ecx: #optional Input ECX value for CPUID instruction for that
3682 # feature word
3683 #
3684 # @cpuid-register: Output register containing the feature bits
3685 #
3686 # @features: value of output register, containing the feature bits
3687 #
3688 # Since: 1.5
3689 ##
3690 { 'type': 'X86CPUFeatureWordInfo',
3691 'data': { 'cpuid-input-eax': 'int',
3692 '*cpuid-input-ecx': 'int',
3693 'cpuid-register': 'X86CPURegister32',
3694 'features': 'int' } }
3695
3696 ##
3697 # @RxState:
3698 #
3699 # Packets receiving state
3700 #
3701 # @normal: filter assigned packets according to the mac-table
3702 #
3703 # @none: don't receive any assigned packet
3704 #
3705 # @all: receive all assigned packets
3706 #
3707 # Since: 1.6
3708 ##
3709 { 'enum': 'RxState', 'data': [ 'normal', 'none', 'all' ] }
3710
3711 ##
3712 # @RxFilterInfo:
3713 #
3714 # Rx-filter information for a NIC.
3715 #
3716 # @name: net client name
3717 #
3718 # @promiscuous: whether promiscuous mode is enabled
3719 #
3720 # @multicast: multicast receive state
3721 #
3722 # @unicast: unicast receive state
3723 #
3724 # @broadcast-allowed: whether to receive broadcast
3725 #
3726 # @multicast-overflow: multicast table is overflowed or not
3727 #
3728 # @unicast-overflow: unicast table is overflowed or not
3729 #
3730 # @main-mac: the main macaddr string
3731 #
3732 # @vlan-table: a list of active vlan id
3733 #
3734 # @unicast-table: a list of unicast macaddr string
3735 #
3736 # @multicast-table: a list of multicast macaddr string
3737 #
3738 # Since 1.6
3739 ##
3740
3741 { 'type': 'RxFilterInfo',
3742 'data': {
3743 'name': 'str',
3744 'promiscuous': 'bool',
3745 'multicast': 'RxState',
3746 'unicast': 'RxState',
3747 'broadcast-allowed': 'bool',
3748 'multicast-overflow': 'bool',
3749 'unicast-overflow': 'bool',
3750 'main-mac': 'str',
3751 'vlan-table': ['int'],
3752 'unicast-table': ['str'],
3753 'multicast-table': ['str'] }}
3754
3755 ##
3756 # @query-rx-filter:
3757 #
3758 # Return rx-filter information for all NICs (or for the given NIC).
3759 #
3760 # @name: #optional net client name
3761 #
3762 # Returns: list of @RxFilterInfo for all NICs (or for the given NIC).
3763 # Returns an error if the given @name doesn't exist, or given
3764 # NIC doesn't support rx-filter querying, or given net client
3765 # isn't a NIC.
3766 #
3767 # Since: 1.6
3768 ##
3769 { 'command': 'query-rx-filter', 'data': { '*name': 'str' },
3770 'returns': ['RxFilterInfo'] }