]>
Commit | Line | Data |
---|---|---|
e3193601 | 1 | # -*- Mode: Python -*- |
4d8bb958 MAL |
2 | ## |
3 | # = Introduction | |
4 | # | |
5 | # This document describes all commands currently supported by QMP. | |
6 | # | |
7 | # Most of the time their usage is exactly the same as in the user Monitor, this | |
8 | # means that any other document which also describe commands (the manpage, | |
9 | # QEMU's manual, etc) can and should be consulted. | |
10 | # | |
11 | # QMP has two types of commands: regular and query commands. Regular commands | |
12 | # usually change the Virtual Machine's state someway, while query commands just | |
13 | # return information. The sections below are divided accordingly. | |
14 | # | |
15 | # It's important to observe that all communication examples are formatted in | |
16 | # a reader-friendly way, so that they're easier to understand. However, in real | |
17 | # protocol usage, they're emitted as a single line. | |
18 | # | |
19 | # Also, the following notation is used to denote data flow: | |
20 | # | |
21 | # Example: | |
22 | # | |
23 | # | -> data issued by the Client | |
24 | # | <- Server data response | |
e3193601 | 25 | # |
4d8bb958 MAL |
26 | # Please, refer to the QMP specification (docs/qmp-spec.txt) for |
27 | # detailed information on the Server command and response formats. | |
28 | # | |
29 | # = Stability Considerations | |
30 | # | |
31 | # The current QMP command set (described in this file) may be useful for a | |
32 | # number of use cases, however it's limited and several commands have bad | |
33 | # defined semantics, specially with regard to command completion. | |
34 | # | |
35 | # These problems are going to be solved incrementally in the next QEMU releases | |
36 | # and we're going to establish a deprecation policy for badly defined commands. | |
37 | # | |
38 | # If you're planning to adopt QMP, please observe the following: | |
39 | # | |
40 | # 1. The deprecation policy will take effect and be documented soon, please | |
41 | # check the documentation of each used command as soon as a new release of | |
42 | # QEMU is available | |
43 | # | |
44 | # 2. DO NOT rely on anything which is not explicit documented | |
45 | # | |
46 | # 3. Errors, in special, are not documented. Applications should NOT check | |
47 | # for specific errors classes or data (it's strongly recommended to only | |
48 | # check for the "error" key) | |
49 | # | |
50 | ## | |
48a32bed | 51 | |
bc52d03f MA |
52 | { 'pragma': { 'doc-required': true } } |
53 | ||
1554a8fa MA |
54 | # Whitelists to permit QAPI rule violations; think twice before you |
55 | # add to them! | |
56 | { 'pragma': { | |
57 | # Commands allowed to return a non-dictionary: | |
58 | 'returns-whitelist': [ | |
59 | 'human-monitor-command', | |
60 | 'qom-get', | |
61 | 'query-migrate-cache-size', | |
62 | 'query-tpm-models', | |
63 | 'query-tpm-types', | |
2cfbae3c MA |
64 | 'ringbuf-read' ], |
65 | 'name-case-whitelist': [ | |
66 | 'ACPISlotType', # DIMM, visible through query-acpi-ospm-status | |
67 | 'CpuInfoMIPS', # PC, visible through query-cpu | |
68 | 'CpuInfoTricore', # PC, visible through query-cpu | |
69 | 'QapiErrorClass', # all members, visible through errors | |
70 | 'UuidInfo', # UUID, visible through query-uuid | |
71 | 'X86CPURegister32', # all members, visible indirectly through qom-get | |
72 | 'q_obj_CpuInfo-base' # CPU, visible through query-cpu | |
73 | ] } } | |
1554a8fa | 74 | |
d34bda71 BC |
75 | # QAPI common definitions |
76 | { 'include': 'qapi/common.json' } | |
104059da | 77 | |
a090187d DB |
78 | # QAPI crypto definitions |
79 | { 'include': 'qapi/crypto.json' } | |
80 | ||
5db15096 BC |
81 | # QAPI block definitions |
82 | { 'include': 'qapi/block.json' } | |
83 | ||
82d72d9d WX |
84 | # QAPI event definitions |
85 | { 'include': 'qapi/event.json' } | |
86 | ||
1dde0f48 LV |
87 | # Tracing commands |
88 | { 'include': 'qapi/trace.json' } | |
89 | ||
39a18158 MA |
90 | # QAPI introspection |
91 | { 'include': 'qapi/introspect.json' } | |
92 | ||
d3a48372 MAL |
93 | ## |
94 | # = QMP commands | |
95 | ## | |
96 | ||
119ebac1 MAL |
97 | ## |
98 | # @qmp_capabilities: | |
99 | # | |
100 | # Enable QMP capabilities. | |
101 | # | |
102 | # Arguments: None. | |
103 | # | |
104 | # Example: | |
105 | # | |
106 | # -> { "execute": "qmp_capabilities" } | |
107 | # <- { "return": {} } | |
108 | # | |
109 | # Notes: This command is valid exactly when first connecting: it must be | |
110 | # issued before any other command will be accepted, and will fail once the | |
111 | # monitor is accepting other commands. (see qemu docs/qmp-spec.txt) | |
112 | # | |
113 | # Since: 0.13 | |
114 | # | |
115 | ## | |
116 | { 'command': 'qmp_capabilities' } | |
117 | ||
104059da | 118 | ## |
801db5ec | 119 | # @LostTickPolicy: |
104059da PB |
120 | # |
121 | # Policy for handling lost ticks in timer devices. | |
122 | # | |
123 | # @discard: throw away the missed tick(s) and continue with future injection | |
124 | # normally. Guest time may be delayed, unless the OS has explicit | |
125 | # handling of lost ticks | |
126 | # | |
127 | # @delay: continue to deliver ticks at the normal rate. Guest time will be | |
128 | # delayed due to the late tick | |
129 | # | |
130 | # @merge: merge the missed tick(s) into one tick and inject. Guest time | |
131 | # may be delayed, depending on how the OS reacts to the merging | |
132 | # of ticks | |
133 | # | |
134 | # @slew: deliver ticks at a higher rate to catch up with the missed tick. The | |
135 | # guest time should not be delayed once catchup is complete. | |
136 | # | |
137 | # Since: 2.0 | |
138 | ## | |
139 | { 'enum': 'LostTickPolicy', | |
140 | 'data': ['discard', 'delay', 'merge', 'slew' ] } | |
141 | ||
49687ace | 142 | ## |
5072f7b3 | 143 | # @add_client: |
b224e5e2 LC |
144 | # |
145 | # Allow client connections for VNC, Spice and socket based | |
146 | # character devices to be passed in to QEMU via SCM_RIGHTS. | |
147 | # | |
148 | # @protocol: protocol name. Valid names are "vnc", "spice" or the | |
149 | # name of a character device (eg. from -chardev id=XXXX) | |
150 | # | |
151 | # @fdname: file descriptor name previously passed via 'getfd' command | |
152 | # | |
1d8bda12 | 153 | # @skipauth: whether to skip authentication. Only applies |
b224e5e2 LC |
154 | # to "vnc" and "spice" protocols |
155 | # | |
1d8bda12 | 156 | # @tls: whether to perform TLS. Only applies to the "spice" |
b224e5e2 LC |
157 | # protocol |
158 | # | |
159 | # Returns: nothing on success. | |
160 | # | |
161 | # Since: 0.14.0 | |
65ce54f5 MAL |
162 | # |
163 | # Example: | |
164 | # | |
165 | # -> { "execute": "add_client", "arguments": { "protocol": "vnc", | |
166 | # "fdname": "myclient" } } | |
167 | # <- { "return": {} } | |
168 | # | |
b224e5e2 LC |
169 | ## |
170 | { 'command': 'add_client', | |
171 | 'data': { 'protocol': 'str', 'fdname': 'str', '*skipauth': 'bool', | |
172 | '*tls': 'bool' } } | |
173 | ||
48a32bed AL |
174 | ## |
175 | # @NameInfo: | |
176 | # | |
177 | # Guest name information. | |
178 | # | |
1d8bda12 | 179 | # @name: The name of the guest |
48a32bed | 180 | # |
5072f7b3 | 181 | # Since: 0.14.0 |
48a32bed | 182 | ## |
895a2a80 | 183 | { 'struct': 'NameInfo', 'data': {'*name': 'str'} } |
48a32bed AL |
184 | |
185 | ## | |
186 | # @query-name: | |
187 | # | |
188 | # Return the name information of a guest. | |
189 | # | |
190 | # Returns: @NameInfo of the guest | |
191 | # | |
5072f7b3 | 192 | # Since: 0.14.0 |
3aa4c6cd MAL |
193 | # |
194 | # Example: | |
195 | # | |
196 | # -> { "execute": "query-name" } | |
197 | # <- { "return": { "name": "qemu-name" } } | |
198 | # | |
48a32bed AL |
199 | ## |
200 | { 'command': 'query-name', 'returns': 'NameInfo' } | |
b9c15f16 | 201 | |
292a2602 LC |
202 | ## |
203 | # @KvmInfo: | |
204 | # | |
205 | # Information about support for KVM acceleration | |
206 | # | |
207 | # @enabled: true if KVM acceleration is active | |
208 | # | |
209 | # @present: true if KVM acceleration is built into this executable | |
210 | # | |
211 | # Since: 0.14.0 | |
212 | ## | |
895a2a80 | 213 | { 'struct': 'KvmInfo', 'data': {'enabled': 'bool', 'present': 'bool'} } |
292a2602 LC |
214 | |
215 | ## | |
216 | # @query-kvm: | |
217 | # | |
218 | # Returns information about KVM acceleration | |
219 | # | |
220 | # Returns: @KvmInfo | |
221 | # | |
222 | # Since: 0.14.0 | |
b4f65cd2 MAL |
223 | # |
224 | # Example: | |
225 | # | |
226 | # -> { "execute": "query-kvm" } | |
227 | # <- { "return": { "enabled": true, "present": true } } | |
228 | # | |
292a2602 LC |
229 | ## |
230 | { 'command': 'query-kvm', 'returns': 'KvmInfo' } | |
231 | ||
1fa9a5e4 | 232 | ## |
5072f7b3 | 233 | # @RunState: |
1fa9a5e4 | 234 | # |
6932a69b | 235 | # An enumeration of VM run states. |
1fa9a5e4 LC |
236 | # |
237 | # @debug: QEMU is running on a debugger | |
238 | # | |
0a24c7b1 LC |
239 | # @finish-migrate: guest is paused to finish the migration process |
240 | # | |
1e998146 PB |
241 | # @inmigrate: guest is paused waiting for an incoming migration. Note |
242 | # that this state does not tell whether the machine will start at the | |
243 | # end of the migration. This depends on the command-line -S option and | |
244 | # any invocation of 'stop' or 'cont' that has happened since QEMU was | |
245 | # started. | |
1fa9a5e4 LC |
246 | # |
247 | # @internal-error: An internal error that prevents further guest execution | |
248 | # has occurred | |
249 | # | |
250 | # @io-error: the last IOP has failed and the device is configured to pause | |
251 | # on I/O errors | |
252 | # | |
253 | # @paused: guest has been paused via the 'stop' command | |
254 | # | |
255 | # @postmigrate: guest is paused following a successful 'migrate' | |
256 | # | |
257 | # @prelaunch: QEMU was started with -S and guest has not started | |
258 | # | |
1fa9a5e4 LC |
259 | # @restore-vm: guest is paused to restore VM state |
260 | # | |
261 | # @running: guest is actively running | |
262 | # | |
263 | # @save-vm: guest is paused to save the VM state | |
264 | # | |
265 | # @shutdown: guest is shut down (and -no-shutdown is in use) | |
266 | # | |
ad02b96a LC |
267 | # @suspended: guest is suspended (ACPI S3) |
268 | # | |
1fa9a5e4 | 269 | # @watchdog: the watchdog action is configured to pause and has been triggered |
ede085b3 HT |
270 | # |
271 | # @guest-panicked: guest has been panicked as a result of guest OS panic | |
21142ba7 | 272 | # |
252093a7 HZ |
273 | # @colo: guest is paused to save/restore VM state under colo checkpoint, |
274 | # VM can not get into this state unless colo capability is enabled | |
275 | # for migration. (since 2.8) | |
1fa9a5e4 LC |
276 | ## |
277 | { 'enum': 'RunState', | |
278 | 'data': [ 'debug', 'inmigrate', 'internal-error', 'io-error', 'paused', | |
279 | 'postmigrate', 'prelaunch', 'finish-migrate', 'restore-vm', | |
ede085b3 | 280 | 'running', 'save-vm', 'shutdown', 'suspended', 'watchdog', |
21142ba7 | 281 | 'guest-panicked', 'colo' ] } |
1fa9a5e4 LC |
282 | |
283 | ## | |
284 | # @StatusInfo: | |
285 | # | |
286 | # Information about VCPU run state | |
287 | # | |
288 | # @running: true if all VCPUs are runnable, false if not runnable | |
289 | # | |
290 | # @singlestep: true if VCPUs are in single-step mode | |
291 | # | |
292 | # @status: the virtual machine @RunState | |
293 | # | |
294 | # Since: 0.14.0 | |
295 | # | |
296 | # Notes: @singlestep is enabled through the GDB stub | |
297 | ## | |
895a2a80 | 298 | { 'struct': 'StatusInfo', |
1fa9a5e4 LC |
299 | 'data': {'running': 'bool', 'singlestep': 'bool', 'status': 'RunState'} } |
300 | ||
301 | ## | |
302 | # @query-status: | |
303 | # | |
304 | # Query the run status of all VCPUs | |
305 | # | |
306 | # Returns: @StatusInfo reflecting all VCPUs | |
307 | # | |
308 | # Since: 0.14.0 | |
477bc1e4 MAL |
309 | # |
310 | # Example: | |
311 | # | |
312 | # -> { "execute": "query-status" } | |
313 | # <- { "return": { "running": true, | |
314 | # "singlestep": false, | |
315 | # "status": "running" } } | |
316 | # | |
1fa9a5e4 LC |
317 | ## |
318 | { 'command': 'query-status', 'returns': 'StatusInfo' } | |
319 | ||
efab767e LC |
320 | ## |
321 | # @UuidInfo: | |
322 | # | |
0ed90f77 | 323 | # Guest UUID information (Universally Unique Identifier). |
efab767e LC |
324 | # |
325 | # @UUID: the UUID of the guest | |
326 | # | |
327 | # Since: 0.14.0 | |
328 | # | |
329 | # Notes: If no UUID was specified for the guest, a null UUID is returned. | |
330 | ## | |
895a2a80 | 331 | { 'struct': 'UuidInfo', 'data': {'UUID': 'str'} } |
efab767e LC |
332 | |
333 | ## | |
334 | # @query-uuid: | |
335 | # | |
336 | # Query the guest UUID information. | |
337 | # | |
338 | # Returns: The @UuidInfo for the guest | |
339 | # | |
5072f7b3 | 340 | # Since: 0.14.0 |
0ed90f77 MAL |
341 | # |
342 | # Example: | |
343 | # | |
344 | # -> { "execute": "query-uuid" } | |
345 | # <- { "return": { "UUID": "550e8400-e29b-41d4-a716-446655440000" } } | |
346 | # | |
efab767e LC |
347 | ## |
348 | { 'command': 'query-uuid', 'returns': 'UuidInfo' } | |
349 | ||
c5a415a0 LC |
350 | ## |
351 | # @ChardevInfo: | |
352 | # | |
353 | # Information about a character device. | |
354 | # | |
355 | # @label: the label of the character device | |
356 | # | |
357 | # @filename: the filename of the character device | |
358 | # | |
32a97ea1 LE |
359 | # @frontend-open: shows whether the frontend device attached to this backend |
360 | # (eg. with the chardev=... option) is in open or closed state | |
361 | # (since 2.1) | |
362 | # | |
c5a415a0 LC |
363 | # Notes: @filename is encoded using the QEMU command line character device |
364 | # encoding. See the QEMU man page for details. | |
365 | # | |
366 | # Since: 0.14.0 | |
367 | ## | |
895a2a80 | 368 | { 'struct': 'ChardevInfo', 'data': {'label': 'str', |
32a97ea1 LE |
369 | 'filename': 'str', |
370 | 'frontend-open': 'bool'} } | |
c5a415a0 LC |
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 | |
4055aa8d MAL |
380 | # |
381 | # Example: | |
382 | # | |
383 | # -> { "execute": "query-chardev" } | |
384 | # <- { | |
385 | # "return": [ | |
386 | # { | |
387 | # "label": "charchannel0", | |
388 | # "filename": "unix:/var/lib/libvirt/qemu/seabios.rhel6.agent,server", | |
389 | # "frontend-open": false | |
390 | # }, | |
391 | # { | |
392 | # "label": "charmonitor", | |
393 | # "filename": "unix:/var/lib/libvirt/qemu/seabios.rhel6.monitor,server", | |
394 | # "frontend-open": true | |
395 | # }, | |
396 | # { | |
397 | # "label": "charserial0", | |
398 | # "filename": "pty:/dev/pts/2", | |
399 | # "frontend-open": true | |
400 | # } | |
401 | # ] | |
402 | # } | |
403 | # | |
c5a415a0 LC |
404 | ## |
405 | { 'command': 'query-chardev', 'returns': ['ChardevInfo'] } | |
aa9b79bc | 406 | |
77d1c3c6 MK |
407 | ## |
408 | # @ChardevBackendInfo: | |
409 | # | |
410 | # Information about a character device backend | |
411 | # | |
412 | # @name: The backend name | |
413 | # | |
414 | # Since: 2.0 | |
415 | ## | |
895a2a80 | 416 | { 'struct': 'ChardevBackendInfo', 'data': {'name': 'str'} } |
77d1c3c6 MK |
417 | |
418 | ## | |
419 | # @query-chardev-backends: | |
420 | # | |
421 | # Returns information about character device backends. | |
422 | # | |
423 | # Returns: a list of @ChardevBackendInfo | |
424 | # | |
425 | # Since: 2.0 | |
90e365c0 MAL |
426 | # |
427 | # Example: | |
428 | # | |
429 | # -> { "execute": "query-chardev-backends" } | |
430 | # <- { | |
431 | # "return":[ | |
432 | # { | |
433 | # "name":"udp" | |
434 | # }, | |
435 | # { | |
436 | # "name":"tcp" | |
437 | # }, | |
438 | # { | |
439 | # "name":"unix" | |
440 | # }, | |
441 | # { | |
442 | # "name":"spiceport" | |
443 | # } | |
444 | # ] | |
445 | # } | |
446 | # | |
77d1c3c6 MK |
447 | ## |
448 | { 'command': 'query-chardev-backends', 'returns': ['ChardevBackendInfo'] } | |
449 | ||
1f590cf9 LL |
450 | ## |
451 | # @DataFormat: | |
452 | # | |
453 | # An enumeration of data format. | |
454 | # | |
3949e594 | 455 | # @utf8: Data is a UTF-8 string (RFC 3629) |
1f590cf9 | 456 | # |
3949e594 | 457 | # @base64: Data is Base64 encoded binary (RFC 3548) |
1f590cf9 LL |
458 | # |
459 | # Since: 1.4 | |
460 | ## | |
ad0f171e | 461 | { 'enum': 'DataFormat', |
1f590cf9 LL |
462 | 'data': [ 'utf8', 'base64' ] } |
463 | ||
464 | ## | |
3949e594 | 465 | # @ringbuf-write: |
1f590cf9 | 466 | # |
3949e594 | 467 | # Write to a ring buffer character device. |
1f590cf9 | 468 | # |
3949e594 | 469 | # @device: the ring buffer character device name |
1f590cf9 | 470 | # |
3949e594 | 471 | # @data: data to write |
1f590cf9 | 472 | # |
1d8bda12 | 473 | # @format: data encoding (default 'utf8'). |
3949e594 MA |
474 | # - base64: data must be base64 encoded text. Its binary |
475 | # decoding gets written. | |
3949e594 MA |
476 | # - utf8: data's UTF-8 encoding is written |
477 | # - data itself is always Unicode regardless of format, like | |
478 | # any other string. | |
1f590cf9 LL |
479 | # |
480 | # Returns: Nothing on success | |
1f590cf9 LL |
481 | # |
482 | # Since: 1.4 | |
a4143a84 MAL |
483 | # |
484 | # Example: | |
485 | # | |
486 | # -> { "execute": "ringbuf-write", | |
487 | # "arguments": { "device": "foo", | |
488 | # "data": "abcdefgh", | |
489 | # "format": "utf8" } } | |
490 | # <- { "return": {} } | |
491 | # | |
1f590cf9 | 492 | ## |
3949e594 | 493 | { 'command': 'ringbuf-write', |
82e59a67 | 494 | 'data': {'device': 'str', 'data': 'str', |
1f590cf9 LL |
495 | '*format': 'DataFormat'} } |
496 | ||
49b6d722 | 497 | ## |
3949e594 | 498 | # @ringbuf-read: |
49b6d722 | 499 | # |
3949e594 | 500 | # Read from a ring buffer character device. |
49b6d722 | 501 | # |
3949e594 | 502 | # @device: the ring buffer character device name |
49b6d722 | 503 | # |
3949e594 | 504 | # @size: how many bytes to read at most |
49b6d722 | 505 | # |
1d8bda12 | 506 | # @format: data encoding (default 'utf8'). |
3949e594 MA |
507 | # - base64: the data read is returned in base64 encoding. |
508 | # - utf8: the data read is interpreted as UTF-8. | |
509 | # Bug: can screw up when the buffer contains invalid UTF-8 | |
510 | # sequences, NUL characters, after the ring buffer lost | |
511 | # data, and when reading stops because the size limit is | |
512 | # reached. | |
513 | # - The return value is always Unicode regardless of format, | |
514 | # like any other string. | |
49b6d722 | 515 | # |
3ab651fc | 516 | # Returns: data read from the device |
49b6d722 LL |
517 | # |
518 | # Since: 1.4 | |
4f19a01b MAL |
519 | # |
520 | # Example: | |
521 | # | |
522 | # -> { "execute": "ringbuf-read", | |
523 | # "arguments": { "device": "foo", | |
524 | # "size": 1000, | |
525 | # "format": "utf8" } } | |
526 | # <- { "return": "abcdefgh" } | |
527 | # | |
49b6d722 | 528 | ## |
3949e594 | 529 | { 'command': 'ringbuf-read', |
49b6d722 | 530 | 'data': {'device': 'str', 'size': 'int', '*format': 'DataFormat'}, |
3ab651fc | 531 | 'returns': 'str' } |
49b6d722 | 532 | |
4860853d DB |
533 | ## |
534 | # @EventInfo: | |
535 | # | |
536 | # Information about a QMP event | |
537 | # | |
538 | # @name: The event name | |
539 | # | |
540 | # Since: 1.2.0 | |
541 | ## | |
895a2a80 | 542 | { 'struct': 'EventInfo', 'data': {'name': 'str'} } |
4860853d DB |
543 | |
544 | ## | |
545 | # @query-events: | |
546 | # | |
547 | # Return a list of supported QMP events by this server | |
548 | # | |
549 | # Returns: A list of @EventInfo for all supported events | |
550 | # | |
551 | # Since: 1.2.0 | |
66c2f5a5 MAL |
552 | # |
553 | # Example: | |
554 | # | |
555 | # -> { "execute": "query-events" } | |
556 | # <- { | |
557 | # "return": [ | |
558 | # { | |
559 | # "name":"SHUTDOWN" | |
560 | # }, | |
561 | # { | |
562 | # "name":"RESET" | |
563 | # } | |
564 | # ] | |
565 | # } | |
566 | # | |
567 | # Note: This example has been shortened as the real response is too long. | |
568 | # | |
4860853d DB |
569 | ## |
570 | { 'command': 'query-events', 'returns': ['EventInfo'] } | |
571 | ||
791e7c82 | 572 | ## |
5072f7b3 | 573 | # @MigrationStats: |
791e7c82 LC |
574 | # |
575 | # Detailed migration status. | |
576 | # | |
577 | # @transferred: amount of bytes already transferred to the target VM | |
578 | # | |
579 | # @remaining: amount of bytes remaining to be transferred to the target VM | |
580 | # | |
581 | # @total: total amount of bytes involved in the migration process | |
582 | # | |
f1c72795 PL |
583 | # @duplicate: number of duplicate (zero) pages (since 1.2) |
584 | # | |
585 | # @skipped: number of skipped zero pages (since 1.5) | |
004d4c10 | 586 | # |
5072f7b3 | 587 | # @normal: number of normal pages (since 1.2) |
004d4c10 | 588 | # |
8d017193 JQ |
589 | # @normal-bytes: number of normal bytes sent (since 1.2) |
590 | # | |
591 | # @dirty-pages-rate: number of pages dirtied by second by the | |
592 | # guest (since 1.3) | |
004d4c10 | 593 | # |
7e114f8c MH |
594 | # @mbps: throughput in megabits/sec. (since 1.6) |
595 | # | |
58570ed8 C |
596 | # @dirty-sync-count: number of times that dirty ram was synchronized (since 2.1) |
597 | # | |
d3bf5418 DDAG |
598 | # @postcopy-requests: The number of page requests received from the destination |
599 | # (since 2.7) | |
600 | # | |
030ce1f8 CF |
601 | # @page-size: The number of bytes per page for the various page-based |
602 | # statistics (since 2.10) | |
603 | # | |
004d4c10 | 604 | # Since: 0.14.0 |
791e7c82 | 605 | ## |
895a2a80 | 606 | { 'struct': 'MigrationStats', |
d5f8a570 | 607 | 'data': {'transferred': 'int', 'remaining': 'int', 'total': 'int' , |
f1c72795 | 608 | 'duplicate': 'int', 'skipped': 'int', 'normal': 'int', |
7e114f8c | 609 | 'normal-bytes': 'int', 'dirty-pages-rate' : 'int', |
d3bf5418 | 610 | 'mbps' : 'number', 'dirty-sync-count' : 'int', |
030ce1f8 | 611 | 'postcopy-requests' : 'int', 'page-size' : 'int' } } |
791e7c82 | 612 | |
f36d55af | 613 | ## |
5072f7b3 | 614 | # @XBZRLECacheStats: |
f36d55af OW |
615 | # |
616 | # Detailed XBZRLE migration cache statistics | |
617 | # | |
618 | # @cache-size: XBZRLE cache size | |
619 | # | |
620 | # @bytes: amount of bytes already transferred to the target VM | |
621 | # | |
622 | # @pages: amount of pages transferred to the target VM | |
623 | # | |
624 | # @cache-miss: number of cache miss | |
625 | # | |
8bc39233 C |
626 | # @cache-miss-rate: rate of cache miss (since 2.1) |
627 | # | |
f36d55af OW |
628 | # @overflow: number of overflows |
629 | # | |
630 | # Since: 1.2 | |
631 | ## | |
895a2a80 | 632 | { 'struct': 'XBZRLECacheStats', |
f36d55af | 633 | 'data': {'cache-size': 'int', 'bytes': 'int', 'pages': 'int', |
8bc39233 C |
634 | 'cache-miss': 'int', 'cache-miss-rate': 'number', |
635 | 'overflow': 'int' } } | |
f36d55af | 636 | |
49687ace | 637 | ## |
24b8c39b HZ |
638 | # @MigrationStatus: |
639 | # | |
640 | # An enumeration of migration status. | |
641 | # | |
642 | # @none: no migration has ever happened. | |
643 | # | |
644 | # @setup: migration process has been initiated. | |
645 | # | |
646 | # @cancelling: in the process of cancelling migration. | |
647 | # | |
648 | # @cancelled: cancelling migration is finished. | |
649 | # | |
650 | # @active: in the process of doing migration. | |
651 | # | |
9ec055ae DDAG |
652 | # @postcopy-active: like active, but now in postcopy mode. (since 2.5) |
653 | # | |
24b8c39b HZ |
654 | # @completed: migration is finished. |
655 | # | |
656 | # @failed: some error occurred during migration process. | |
657 | # | |
252093a7 HZ |
658 | # @colo: VM is in the process of fault tolerance, VM can not get into this |
659 | # state unless colo capability is enabled for migration. (since 2.8) | |
0b827d5e | 660 | # |
24b8c39b HZ |
661 | # Since: 2.3 |
662 | # | |
663 | ## | |
664 | { 'enum': 'MigrationStatus', | |
665 | 'data': [ 'none', 'setup', 'cancelling', 'cancelled', | |
0b827d5e | 666 | 'active', 'postcopy-active', 'completed', 'failed', 'colo' ] } |
24b8c39b | 667 | |
791e7c82 | 668 | ## |
5072f7b3 | 669 | # @MigrationInfo: |
791e7c82 LC |
670 | # |
671 | # Information about current migration process. | |
672 | # | |
1d8bda12 | 673 | # @status: @MigrationStatus describing the current migration status. |
24b8c39b | 674 | # If this field is not returned, no migration process |
791e7c82 LC |
675 | # has been initiated |
676 | # | |
1d8bda12 | 677 | # @ram: @MigrationStats containing detailed migration |
d5f8a570 | 678 | # status, only returned if status is 'active' or |
24b8c39b | 679 | # 'completed'(since 1.2) |
791e7c82 | 680 | # |
1d8bda12 | 681 | # @disk: @MigrationStats containing detailed disk migration |
791e7c82 LC |
682 | # status, only returned if status is 'active' and it is a block |
683 | # migration | |
684 | # | |
1d8bda12 | 685 | # @xbzrle-cache: @XBZRLECacheStats containing detailed XBZRLE |
f36d55af OW |
686 | # migration statistics, only returned if XBZRLE feature is on and |
687 | # status is 'active' or 'completed' (since 1.2) | |
688 | # | |
1d8bda12 | 689 | # @total-time: total amount of milliseconds since migration started. |
7aa939af JQ |
690 | # If migration has ended, it returns the total migration |
691 | # time. (since 1.2) | |
692 | # | |
1d8bda12 | 693 | # @downtime: only present when migration finishes correctly |
9c5a9fcf JQ |
694 | # total downtime in milliseconds for the guest. |
695 | # (since 1.3) | |
696 | # | |
1d8bda12 | 697 | # @expected-downtime: only present while migration is active |
2c52ddf1 JQ |
698 | # expected downtime in milliseconds for the guest in last walk |
699 | # of the dirty bitmap. (since 1.3) | |
700 | # | |
1d8bda12 | 701 | # @setup-time: amount of setup time in milliseconds _before_ the |
ed4fbd10 MH |
702 | # iterations begin but _after_ the QMP command is issued. This is designed |
703 | # to provide an accounting of any activities (such as RDMA pinning) which | |
704 | # may be expensive, but do not actually occur during the iterative | |
705 | # migration rounds themselves. (since 1.6) | |
706 | # | |
1d8bda12 | 707 | # @cpu-throttle-percentage: percentage of time guest cpus are being |
d85a31d1 JH |
708 | # throttled during auto-converge. This is only present when auto-converge |
709 | # has started throttling guest cpus. (Since 2.7) | |
4782893e | 710 | # |
1d8bda12 | 711 | # @error-desc: the human readable error description string, when |
d59ce6f3 | 712 | # @status is 'failed'. Clients should not attempt to parse the |
bdbba12b | 713 | # error strings. (Since 2.7) |
d59ce6f3 | 714 | # |
791e7c82 LC |
715 | # Since: 0.14.0 |
716 | ## | |
895a2a80 | 717 | { 'struct': 'MigrationInfo', |
24b8c39b | 718 | 'data': {'*status': 'MigrationStatus', '*ram': 'MigrationStats', |
f36d55af | 719 | '*disk': 'MigrationStats', |
7aa939af | 720 | '*xbzrle-cache': 'XBZRLECacheStats', |
9c5a9fcf | 721 | '*total-time': 'int', |
2c52ddf1 | 722 | '*expected-downtime': 'int', |
ed4fbd10 | 723 | '*downtime': 'int', |
4782893e | 724 | '*setup-time': 'int', |
d59ce6f3 DB |
725 | '*cpu-throttle-percentage': 'int', |
726 | '*error-desc': 'str'} } | |
791e7c82 LC |
727 | |
728 | ## | |
5072f7b3 | 729 | # @query-migrate: |
791e7c82 | 730 | # |
104b1caf MAL |
731 | # Returns information about current migration process. If migration |
732 | # is active there will be another json-object with RAM migration | |
733 | # status and if block migration is active another one with block | |
734 | # migration status. | |
791e7c82 LC |
735 | # |
736 | # Returns: @MigrationInfo | |
737 | # | |
738 | # Since: 0.14.0 | |
104b1caf MAL |
739 | # |
740 | # Example: | |
741 | # | |
742 | # 1. Before the first migration | |
743 | # | |
744 | # -> { "execute": "query-migrate" } | |
745 | # <- { "return": {} } | |
746 | # | |
747 | # 2. Migration is done and has succeeded | |
748 | # | |
749 | # -> { "execute": "query-migrate" } | |
750 | # <- { "return": { | |
751 | # "status": "completed", | |
752 | # "ram":{ | |
753 | # "transferred":123, | |
754 | # "remaining":123, | |
755 | # "total":246, | |
756 | # "total-time":12345, | |
757 | # "setup-time":12345, | |
758 | # "downtime":12345, | |
759 | # "duplicate":123, | |
760 | # "normal":123, | |
761 | # "normal-bytes":123456, | |
762 | # "dirty-sync-count":15 | |
763 | # } | |
764 | # } | |
765 | # } | |
766 | # | |
767 | # 3. Migration is done and has failed | |
768 | # | |
769 | # -> { "execute": "query-migrate" } | |
770 | # <- { "return": { "status": "failed" } } | |
771 | # | |
772 | # 4. Migration is being performed and is not a block migration: | |
773 | # | |
774 | # -> { "execute": "query-migrate" } | |
775 | # <- { | |
776 | # "return":{ | |
777 | # "status":"active", | |
778 | # "ram":{ | |
779 | # "transferred":123, | |
780 | # "remaining":123, | |
781 | # "total":246, | |
782 | # "total-time":12345, | |
783 | # "setup-time":12345, | |
784 | # "expected-downtime":12345, | |
785 | # "duplicate":123, | |
786 | # "normal":123, | |
787 | # "normal-bytes":123456, | |
788 | # "dirty-sync-count":15 | |
789 | # } | |
790 | # } | |
791 | # } | |
792 | # | |
793 | # 5. Migration is being performed and is a block migration: | |
794 | # | |
795 | # -> { "execute": "query-migrate" } | |
796 | # <- { | |
797 | # "return":{ | |
798 | # "status":"active", | |
799 | # "ram":{ | |
800 | # "total":1057024, | |
801 | # "remaining":1053304, | |
802 | # "transferred":3720, | |
803 | # "total-time":12345, | |
804 | # "setup-time":12345, | |
805 | # "expected-downtime":12345, | |
806 | # "duplicate":123, | |
807 | # "normal":123, | |
808 | # "normal-bytes":123456, | |
809 | # "dirty-sync-count":15 | |
810 | # }, | |
811 | # "disk":{ | |
812 | # "total":20971520, | |
813 | # "remaining":20880384, | |
814 | # "transferred":91136 | |
815 | # } | |
816 | # } | |
817 | # } | |
818 | # | |
819 | # 6. Migration is being performed and XBZRLE is active: | |
820 | # | |
821 | # -> { "execute": "query-migrate" } | |
822 | # <- { | |
823 | # "return":{ | |
824 | # "status":"active", | |
825 | # "capabilities" : [ { "capability": "xbzrle", "state" : true } ], | |
826 | # "ram":{ | |
827 | # "total":1057024, | |
828 | # "remaining":1053304, | |
829 | # "transferred":3720, | |
830 | # "total-time":12345, | |
831 | # "setup-time":12345, | |
832 | # "expected-downtime":12345, | |
833 | # "duplicate":10, | |
834 | # "normal":3333, | |
835 | # "normal-bytes":3412992, | |
836 | # "dirty-sync-count":15 | |
837 | # }, | |
838 | # "xbzrle-cache":{ | |
839 | # "cache-size":67108864, | |
840 | # "bytes":20971520, | |
841 | # "pages":2444343, | |
842 | # "cache-miss":2244, | |
843 | # "cache-miss-rate":0.123, | |
844 | # "overflow":34434 | |
845 | # } | |
846 | # } | |
847 | # } | |
848 | # | |
791e7c82 LC |
849 | ## |
850 | { 'command': 'query-migrate', 'returns': 'MigrationInfo' } | |
851 | ||
bbf6da32 | 852 | ## |
5072f7b3 | 853 | # @MigrationCapability: |
bbf6da32 OW |
854 | # |
855 | # Migration capabilities enumeration | |
856 | # | |
857 | # @xbzrle: Migration supports xbzrle (Xor Based Zero Run Length Encoding). | |
858 | # This feature allows us to minimize migration traffic for certain work | |
859 | # loads, by sending compressed difference of the pages | |
860 | # | |
41310c68 | 861 | # @rdma-pin-all: Controls whether or not the entire VM memory footprint is |
60d9222c | 862 | # mlock()'d on demand or all at once. Refer to docs/rdma.txt for usage. |
41310c68 | 863 | # Disabled by default. (since 2.0) |
60d9222c | 864 | # |
323004a3 PL |
865 | # @zero-blocks: During storage migration encode blocks of zeroes efficiently. This |
866 | # essentially saves 1MB of zeroes per block on the wire. Enabling requires | |
867 | # source and target VM to support this feature. To enable it is sufficient | |
868 | # to enable the capability on the source VM. The feature is disabled by | |
869 | # default. (since 1.6) | |
870 | # | |
dde4e694 LL |
871 | # @compress: Use multiple compression threads to accelerate live migration. |
872 | # This feature can help to reduce the migration traffic, by sending | |
873 | # compressed pages. Please note that if compress and xbzrle are both | |
874 | # on, compress only takes effect in the ram bulk stage, after that, | |
875 | # it will be disabled and only xbzrle takes effect, this can help to | |
876 | # minimize migration traffic. The feature is disabled by default. | |
877 | # (since 2.4 ) | |
878 | # | |
b05dc723 JQ |
879 | # @events: generate events for each migration state change |
880 | # (since 2.4 ) | |
881 | # | |
9781c371 JQ |
882 | # @auto-converge: If enabled, QEMU will automatically throttle down the guest |
883 | # to speed up convergence of RAM migration. (since 1.6) | |
884 | # | |
32c3db5b | 885 | # @postcopy-ram: Start executing on the migration target before all of RAM has |
53dd370c | 886 | # been migrated, pulling the remaining pages along as needed. NOTE: If |
32c3db5b | 887 | # the migration fails during postcopy the VM will fail. (since 2.6) |
53dd370c | 888 | # |
35a6ed4f HZ |
889 | # @x-colo: If enabled, migration will never end, and the state of the VM on the |
890 | # primary side will be migrated continuously to the VM on secondary | |
891 | # side, this process is called COarse-Grain LOck Stepping (COLO) for | |
892 | # Non-stop Service. (since 2.8) | |
893 | # | |
53f09a10 PB |
894 | # @release-ram: if enabled, qemu will free the migrated ram pages on the source |
895 | # during postcopy-ram migration. (since 2.9) | |
896 | # | |
2833c59b JQ |
897 | # @block: If enabled, QEMU will also migrate the contents of all block |
898 | # devices. Default is disabled. A possible alternative uses | |
899 | # mirror jobs to a builtin NBD server on the destination, which | |
900 | # offers more flexibility. | |
901 | # (Since 2.10) | |
902 | # | |
c788ada8 PX |
903 | # @return-path: If enabled, migration will use the return path even |
904 | # for precopy. (since 2.10) | |
905 | # | |
bbf6da32 OW |
906 | # Since: 1.2 |
907 | ## | |
908 | { 'enum': 'MigrationCapability', | |
dde4e694 | 909 | 'data': ['xbzrle', 'rdma-pin-all', 'auto-converge', 'zero-blocks', |
2833c59b | 910 | 'compress', 'events', 'postcopy-ram', 'x-colo', 'release-ram', |
c788ada8 | 911 | 'block', 'return-path' ] } |
bbf6da32 OW |
912 | |
913 | ## | |
5072f7b3 | 914 | # @MigrationCapabilityStatus: |
bbf6da32 OW |
915 | # |
916 | # Migration capability information | |
917 | # | |
918 | # @capability: capability enum | |
919 | # | |
920 | # @state: capability state bool | |
921 | # | |
922 | # Since: 1.2 | |
923 | ## | |
895a2a80 | 924 | { 'struct': 'MigrationCapabilityStatus', |
bbf6da32 OW |
925 | 'data': { 'capability' : 'MigrationCapability', 'state' : 'bool' } } |
926 | ||
927 | ## | |
5072f7b3 | 928 | # @migrate-set-capabilities: |
00458433 OW |
929 | # |
930 | # Enable/Disable the following migration capabilities (like xbzrle) | |
931 | # | |
932 | # @capabilities: json array of capability modifications to make | |
933 | # | |
934 | # Since: 1.2 | |
0a0bb964 MAL |
935 | # |
936 | # Example: | |
937 | # | |
938 | # -> { "execute": "migrate-set-capabilities" , "arguments": | |
939 | # { "capabilities": [ { "capability": "xbzrle", "state": true } ] } } | |
940 | # | |
00458433 OW |
941 | ## |
942 | { 'command': 'migrate-set-capabilities', | |
943 | 'data': { 'capabilities': ['MigrationCapabilityStatus'] } } | |
944 | ||
945 | ## | |
5072f7b3 | 946 | # @query-migrate-capabilities: |
bbf6da32 OW |
947 | # |
948 | # Returns information about the current migration capabilities status | |
949 | # | |
950 | # Returns: @MigrationCapabilitiesStatus | |
951 | # | |
952 | # Since: 1.2 | |
135b238e MAL |
953 | # |
954 | # Example: | |
955 | # | |
956 | # -> { "execute": "query-migrate-capabilities" } | |
957 | # <- { "return": [ | |
958 | # {"state": false, "capability": "xbzrle"}, | |
959 | # {"state": false, "capability": "rdma-pin-all"}, | |
960 | # {"state": false, "capability": "auto-converge"}, | |
961 | # {"state": false, "capability": "zero-blocks"}, | |
962 | # {"state": false, "capability": "compress"}, | |
963 | # {"state": true, "capability": "events"}, | |
964 | # {"state": false, "capability": "postcopy-ram"}, | |
965 | # {"state": false, "capability": "x-colo"} | |
966 | # ]} | |
967 | # | |
bbf6da32 OW |
968 | ## |
969 | { 'command': 'query-migrate-capabilities', 'returns': ['MigrationCapabilityStatus']} | |
970 | ||
49687ace | 971 | ## |
5072f7b3 | 972 | # @MigrationParameter: |
43c60a81 LL |
973 | # |
974 | # Migration parameters enumeration | |
975 | # | |
976 | # @compress-level: Set the compression level to be used in live migration, | |
977 | # the compression level is an integer between 0 and 9, where 0 means | |
978 | # no compression, 1 means the best compression speed, and 9 means best | |
979 | # compression ratio which will consume more CPU. | |
980 | # | |
981 | # @compress-threads: Set compression thread count to be used in live migration, | |
982 | # the compression thread count is an integer between 1 and 255. | |
983 | # | |
984 | # @decompress-threads: Set decompression thread count to be used in live | |
985 | # migration, the decompression thread count is an integer between 1 | |
986 | # and 255. Usually, decompression is at least 4 times as fast as | |
987 | # compression, so set the decompress-threads to the number about 1/4 | |
988 | # of compress-threads is adequate. | |
989 | # | |
d85a31d1 JH |
990 | # @cpu-throttle-initial: Initial percentage of time guest cpus are throttled |
991 | # when migration auto-converge is activated. The | |
992 | # default value is 20. (Since 2.7) | |
1626fee3 | 993 | # |
d85a31d1 JH |
994 | # @cpu-throttle-increment: throttle percentage increase each time |
995 | # auto-converge detects that migration is not making | |
996 | # progress. The default value is 10. (Since 2.7) | |
69ef1f36 DB |
997 | # |
998 | # @tls-creds: ID of the 'tls-creds' object that provides credentials for | |
999 | # establishing a TLS connection over the migration data channel. | |
1000 | # On the outgoing side of the migration, the credentials must | |
1001 | # be for a 'client' endpoint, while for the incoming side the | |
1002 | # credentials must be for a 'server' endpoint. Setting this | |
1003 | # will enable TLS for all migrations. The default is unset, | |
1004 | # resulting in unsecured migration at the QEMU level. (Since 2.7) | |
1005 | # | |
1006 | # @tls-hostname: hostname of the target host for the migration. This is | |
1007 | # required when using x509 based TLS credentials and the | |
1008 | # migration URI does not already include a hostname. For | |
1009 | # example if using fd: or exec: based migration, the | |
1010 | # hostname must be provided so that the server's x509 | |
bdbba12b | 1011 | # certificate identity can be validated. (Since 2.7) |
69ef1f36 | 1012 | # |
2ff30257 AA |
1013 | # @max-bandwidth: to set maximum speed for migration. maximum speed in |
1014 | # bytes per second. (Since 2.8) | |
1015 | # | |
1016 | # @downtime-limit: set maximum tolerated downtime for migration. maximum | |
1017 | # downtime in milliseconds (Since 2.8) | |
1018 | # | |
68b53591 HZ |
1019 | # @x-checkpoint-delay: The delay time (in ms) between two COLO checkpoints in |
1020 | # periodic mode. (Since 2.8) | |
1021 | # | |
2833c59b JQ |
1022 | # @block-incremental: Affects how much storage is migrated when the |
1023 | # block migration capability is enabled. When false, the entire | |
1024 | # storage backing chain is migrated into a flattened image at | |
1025 | # the destination; when true, only the active qcow2 layer is | |
1026 | # migrated and the destination must already have access to the | |
1027 | # same backing chain as was used on the source. (since 2.10) | |
1028 | # | |
43c60a81 LL |
1029 | # Since: 2.4 |
1030 | ## | |
1031 | { 'enum': 'MigrationParameter', | |
1626fee3 | 1032 | 'data': ['compress-level', 'compress-threads', 'decompress-threads', |
69ef1f36 | 1033 | 'cpu-throttle-initial', 'cpu-throttle-increment', |
2ff30257 | 1034 | 'tls-creds', 'tls-hostname', 'max-bandwidth', |
2833c59b | 1035 | 'downtime-limit', 'x-checkpoint-delay', 'block-incremental' ] } |
43c60a81 | 1036 | |
49687ace | 1037 | ## |
5072f7b3 | 1038 | # @migrate-set-parameters: |
85de8323 | 1039 | # |
c2dd311c | 1040 | # Set various migration parameters. |
69ef1f36 | 1041 | # |
85de8323 | 1042 | # Since: 2.4 |
35db41e5 MAL |
1043 | # |
1044 | # Example: | |
1045 | # | |
1046 | # -> { "execute": "migrate-set-parameters" , | |
1047 | # "arguments": { "compress-level": 1 } } | |
1048 | # | |
85de8323 | 1049 | ## |
7f375e04 | 1050 | { 'command': 'migrate-set-parameters', 'boxed': true, |
de63ab61 | 1051 | 'data': 'MigrationParameters' } |
85de8323 | 1052 | |
49687ace | 1053 | ## |
5072f7b3 | 1054 | # @MigrationParameters: |
85de8323 | 1055 | # |
de63ab61 EB |
1056 | # Optional members can be omitted on input ('migrate-set-parameters') |
1057 | # but most members will always be present on output | |
1058 | # ('query-migrate-parameters'), with the exception of tls-creds and | |
1059 | # tls-hostname. | |
85de8323 | 1060 | # |
1d8bda12 | 1061 | # @compress-level: compression level |
85de8323 | 1062 | # |
1d8bda12 | 1063 | # @compress-threads: compression thread count |
85de8323 | 1064 | # |
1d8bda12 | 1065 | # @decompress-threads: decompression thread count |
1626fee3 | 1066 | # |
1d8bda12 | 1067 | # @cpu-throttle-initial: Initial percentage of time guest cpus are |
de63ab61 EB |
1068 | # throttledwhen migration auto-converge is activated. |
1069 | # The default value is 20. (Since 2.7) | |
1070 | # | |
1d8bda12 | 1071 | # @cpu-throttle-increment: throttle percentage increase each time |
d85a31d1 JH |
1072 | # auto-converge detects that migration is not making |
1073 | # progress. The default value is 10. (Since 2.7) | |
1626fee3 | 1074 | # |
1d8bda12 | 1075 | # @tls-creds: ID of the 'tls-creds' object that provides credentials |
de63ab61 EB |
1076 | # for establishing a TLS connection over the migration data |
1077 | # channel. On the outgoing side of the migration, the credentials | |
1078 | # must be for a 'client' endpoint, while for the incoming side the | |
69ef1f36 DB |
1079 | # credentials must be for a 'server' endpoint. Setting this |
1080 | # will enable TLS for all migrations. The default is unset, | |
bdbba12b | 1081 | # resulting in unsecured migration at the QEMU level. (Since 2.7) |
4af245dc DB |
1082 | # An empty string means that QEMU will use plain text mode for |
1083 | # migration, rather than TLS (Since 2.9) | |
69ef1f36 | 1084 | # |
1d8bda12 | 1085 | # @tls-hostname: hostname of the target host for the migration. This |
de63ab61 | 1086 | # is required when using x509 based TLS credentials and the |
69ef1f36 DB |
1087 | # migration URI does not already include a hostname. For |
1088 | # example if using fd: or exec: based migration, the | |
1089 | # hostname must be provided so that the server's x509 | |
bdbba12b | 1090 | # certificate identity can be validated. (Since 2.7) |
4af245dc DB |
1091 | # An empty string means that QEMU will use the hostname |
1092 | # associated with the migration URI, if any. (Since 2.9) | |
69ef1f36 | 1093 | # |
2ff30257 AA |
1094 | # @max-bandwidth: to set maximum speed for migration. maximum speed in |
1095 | # bytes per second. (Since 2.8) | |
1096 | # | |
1097 | # @downtime-limit: set maximum tolerated downtime for migration. maximum | |
1098 | # downtime in milliseconds (Since 2.8) | |
1099 | # | |
68b53591 HZ |
1100 | # @x-checkpoint-delay: the delay time between two COLO checkpoints. (Since 2.8) |
1101 | # | |
2833c59b JQ |
1102 | # @block-incremental: Affects how much storage is migrated when the |
1103 | # block migration capability is enabled. When false, the entire | |
1104 | # storage backing chain is migrated into a flattened image at | |
1105 | # the destination; when true, only the active qcow2 layer is | |
1106 | # migrated and the destination must already have access to the | |
1107 | # same backing chain as was used on the source. (since 2.10) | |
1108 | # | |
85de8323 LL |
1109 | # Since: 2.4 |
1110 | ## | |
1111 | { 'struct': 'MigrationParameters', | |
de63ab61 EB |
1112 | 'data': { '*compress-level': 'int', |
1113 | '*compress-threads': 'int', | |
1114 | '*decompress-threads': 'int', | |
1115 | '*cpu-throttle-initial': 'int', | |
1116 | '*cpu-throttle-increment': 'int', | |
1117 | '*tls-creds': 'str', | |
2ff30257 AA |
1118 | '*tls-hostname': 'str', |
1119 | '*max-bandwidth': 'int', | |
68b53591 | 1120 | '*downtime-limit': 'int', |
2833c59b JQ |
1121 | '*x-checkpoint-delay': 'int', |
1122 | '*block-incremental': 'bool' } } | |
6235b9cd | 1123 | |
85de8323 | 1124 | ## |
5072f7b3 | 1125 | # @query-migrate-parameters: |
85de8323 LL |
1126 | # |
1127 | # Returns information about the current migration parameters | |
1128 | # | |
1129 | # Returns: @MigrationParameters | |
1130 | # | |
1131 | # Since: 2.4 | |
cf56cfad MAL |
1132 | # |
1133 | # Example: | |
1134 | # | |
1135 | # -> { "execute": "query-migrate-parameters" } | |
1136 | # <- { "return": { | |
1137 | # "decompress-threads": 2, | |
1138 | # "cpu-throttle-increment": 10, | |
1139 | # "compress-threads": 8, | |
1140 | # "compress-level": 1, | |
1141 | # "cpu-throttle-initial": 20, | |
1142 | # "max-bandwidth": 33554432, | |
1143 | # "downtime-limit": 300 | |
1144 | # } | |
1145 | # } | |
1146 | # | |
85de8323 LL |
1147 | ## |
1148 | { 'command': 'query-migrate-parameters', | |
1149 | 'returns': 'MigrationParameters' } | |
1150 | ||
b8a185bc | 1151 | ## |
5072f7b3 | 1152 | # @client_migrate_info: |
b8a185bc MA |
1153 | # |
1154 | # Set migration information for remote display. This makes the server | |
1155 | # ask the client to automatically reconnect using the new parameters | |
1156 | # once migration finished successfully. Only implemented for SPICE. | |
1157 | # | |
1158 | # @protocol: must be "spice" | |
1159 | # @hostname: migration target hostname | |
1d8bda12 MA |
1160 | # @port: spice tcp port for plaintext channels |
1161 | # @tls-port: spice tcp port for tls-secured channels | |
1162 | # @cert-subject: server certificate subject | |
b8a185bc MA |
1163 | # |
1164 | # Since: 0.14.0 | |
d0d3fc7f MAL |
1165 | # |
1166 | # Example: | |
1167 | # | |
1168 | # -> { "execute": "client_migrate_info", | |
1169 | # "arguments": { "protocol": "spice", | |
1170 | # "hostname": "virt42.lab.kraxel.org", | |
1171 | # "port": 1234 } } | |
1172 | # <- { "return": {} } | |
1173 | # | |
b8a185bc MA |
1174 | ## |
1175 | { 'command': 'client_migrate_info', | |
1176 | 'data': { 'protocol': 'str', 'hostname': 'str', '*port': 'int', | |
1177 | '*tls-port': 'int', '*cert-subject': 'str' } } | |
1178 | ||
4886a1bc | 1179 | ## |
5072f7b3 | 1180 | # @migrate-start-postcopy: |
4886a1bc | 1181 | # |
a54d340b | 1182 | # Followup to a migration command to switch the migration to postcopy mode. |
32c3db5b | 1183 | # The postcopy-ram capability must be set before the original migration |
a54d340b | 1184 | # command. |
4886a1bc DDAG |
1185 | # |
1186 | # Since: 2.5 | |
3c3ea00a MAL |
1187 | # |
1188 | # Example: | |
1189 | # | |
1190 | # -> { "execute": "migrate-start-postcopy" } | |
1191 | # <- { "return": {} } | |
1192 | # | |
49687ace | 1193 | ## |
4886a1bc DDAG |
1194 | { 'command': 'migrate-start-postcopy' } |
1195 | ||
e235cec3 | 1196 | ## |
5072f7b3 | 1197 | # @COLOMessage: |
4f97558e HZ |
1198 | # |
1199 | # The message transmission between Primary side and Secondary side. | |
1200 | # | |
1201 | # @checkpoint-ready: Secondary VM (SVM) is ready for checkpointing | |
1202 | # | |
1203 | # @checkpoint-request: Primary VM (PVM) tells SVM to prepare for checkpointing | |
1204 | # | |
1205 | # @checkpoint-reply: SVM gets PVM's checkpoint request | |
1206 | # | |
1207 | # @vmstate-send: VM's state will be sent by PVM. | |
1208 | # | |
1209 | # @vmstate-size: The total size of VMstate. | |
1210 | # | |
1211 | # @vmstate-received: VM's state has been received by SVM. | |
1212 | # | |
1213 | # @vmstate-loaded: VM's state has been loaded by SVM. | |
1214 | # | |
1215 | # Since: 2.8 | |
1216 | ## | |
1217 | { 'enum': 'COLOMessage', | |
1218 | 'data': [ 'checkpoint-ready', 'checkpoint-request', 'checkpoint-reply', | |
1219 | 'vmstate-send', 'vmstate-size', 'vmstate-received', | |
1220 | 'vmstate-loaded' ] } | |
1221 | ||
d89e666e | 1222 | ## |
5072f7b3 | 1223 | # @COLOMode: |
d89e666e HZ |
1224 | # |
1225 | # The colo mode | |
1226 | # | |
1227 | # @unknown: unknown mode | |
1228 | # | |
1229 | # @primary: master side | |
1230 | # | |
1231 | # @secondary: slave side | |
1232 | # | |
1233 | # Since: 2.8 | |
1234 | ## | |
1235 | { 'enum': 'COLOMode', | |
1236 | 'data': [ 'unknown', 'primary', 'secondary'] } | |
1237 | ||
aef06085 | 1238 | ## |
5072f7b3 | 1239 | # @FailoverStatus: |
aef06085 HZ |
1240 | # |
1241 | # An enumeration of COLO failover status | |
1242 | # | |
1243 | # @none: no failover has ever happened | |
1244 | # | |
1245 | # @require: got failover requirement but not handled | |
1246 | # | |
1247 | # @active: in the process of doing failover | |
1248 | # | |
1249 | # @completed: finish the process of failover | |
1250 | # | |
a8664ba5 HZ |
1251 | # @relaunch: restart the failover process, from 'none' -> 'completed' (Since 2.9) |
1252 | # | |
aef06085 HZ |
1253 | # Since: 2.8 |
1254 | ## | |
1255 | { 'enum': 'FailoverStatus', | |
a8664ba5 | 1256 | 'data': [ 'none', 'require', 'active', 'completed', 'relaunch' ] } |
aef06085 | 1257 | |
d89e666e | 1258 | ## |
5072f7b3 | 1259 | # @x-colo-lost-heartbeat: |
d89e666e HZ |
1260 | # |
1261 | # Tell qemu that heartbeat is lost, request it to do takeover procedures. | |
1262 | # If this command is sent to the PVM, the Primary side will exit COLO mode. | |
1263 | # If sent to the Secondary, the Secondary side will run failover work, | |
1264 | # then takes over server operation to become the service VM. | |
1265 | # | |
1266 | # Since: 2.8 | |
c08d6443 MAL |
1267 | # |
1268 | # Example: | |
1269 | # | |
1270 | # -> { "execute": "x-colo-lost-heartbeat" } | |
1271 | # <- { "return": {} } | |
1272 | # | |
d89e666e HZ |
1273 | ## |
1274 | { 'command': 'x-colo-lost-heartbeat' } | |
1275 | ||
1276 | ## | |
e235cec3 LC |
1277 | # @MouseInfo: |
1278 | # | |
1279 | # Information about a mouse device. | |
1280 | # | |
1281 | # @name: the name of the mouse device | |
1282 | # | |
1283 | # @index: the index of the mouse device | |
1284 | # | |
1285 | # @current: true if this device is currently receiving mouse events | |
1286 | # | |
1287 | # @absolute: true if this device supports absolute coordinates as input | |
1288 | # | |
1289 | # Since: 0.14.0 | |
1290 | ## | |
895a2a80 | 1291 | { 'struct': 'MouseInfo', |
e235cec3 LC |
1292 | 'data': {'name': 'str', 'index': 'int', 'current': 'bool', |
1293 | 'absolute': 'bool'} } | |
1294 | ||
1295 | ## | |
1296 | # @query-mice: | |
1297 | # | |
1298 | # Returns information about each active mouse device | |
1299 | # | |
1300 | # Returns: a list of @MouseInfo for each device | |
1301 | # | |
1302 | # Since: 0.14.0 | |
60639df5 MAL |
1303 | # |
1304 | # Example: | |
1305 | # | |
1306 | # -> { "execute": "query-mice" } | |
1307 | # <- { "return": [ | |
1308 | # { | |
1309 | # "name":"QEMU Microsoft Mouse", | |
1310 | # "index":0, | |
1311 | # "current":false, | |
1312 | # "absolute":false | |
1313 | # }, | |
1314 | # { | |
1315 | # "name":"QEMU PS/2 Mouse", | |
1316 | # "index":1, | |
1317 | # "current":true, | |
1318 | # "absolute":true | |
1319 | # } | |
1320 | # ] | |
1321 | # } | |
1322 | # | |
e235cec3 LC |
1323 | ## |
1324 | { 'command': 'query-mice', 'returns': ['MouseInfo'] } | |
1325 | ||
de0b36b6 | 1326 | ## |
86f4b687 | 1327 | # @CpuInfoArch: |
de0b36b6 | 1328 | # |
86f4b687 EB |
1329 | # An enumeration of cpu types that enable additional information during |
1330 | # @query-cpus. | |
1331 | # | |
1332 | # Since: 2.6 | |
1333 | ## | |
1334 | { 'enum': 'CpuInfoArch', | |
1335 | 'data': ['x86', 'sparc', 'ppc', 'mips', 'tricore', 'other' ] } | |
1336 | ||
1337 | ## | |
3666a97f | 1338 | # @CpuInfo: |
86f4b687 | 1339 | # |
3666a97f | 1340 | # Information about a virtual CPU |
de0b36b6 LC |
1341 | # |
1342 | # @CPU: the index of the virtual CPU | |
1343 | # | |
86f4b687 | 1344 | # @current: this only exists for backwards compatibility and should be ignored |
b80e560b | 1345 | # |
de0b36b6 LC |
1346 | # @halted: true if the virtual CPU is in the halt state. Halt usually refers |
1347 | # to a processor specific low power mode. | |
1348 | # | |
58f88d4b EH |
1349 | # @qom_path: path to the CPU object in the QOM tree (since 2.4) |
1350 | # | |
de0b36b6 LC |
1351 | # @thread_id: ID of the underlying host thread |
1352 | # | |
afed5a5a IM |
1353 | # @props: properties describing to which node/socket/core/thread |
1354 | # virtual CPU belongs to, provided if supported by board (since 2.10) | |
1355 | # | |
86f4b687 EB |
1356 | # @arch: architecture of the cpu, which determines which additional fields |
1357 | # will be listed (since 2.6) | |
1358 | # | |
de0b36b6 LC |
1359 | # Since: 0.14.0 |
1360 | # | |
1361 | # Notes: @halted is a transient state that changes frequently. By the time the | |
1362 | # data is sent to the client, the guest may no longer be halted. | |
1363 | ## | |
3666a97f EB |
1364 | { 'union': 'CpuInfo', |
1365 | 'base': {'CPU': 'int', 'current': 'bool', 'halted': 'bool', | |
afed5a5a IM |
1366 | 'qom_path': 'str', 'thread_id': 'int', |
1367 | '*props': 'CpuInstanceProperties', 'arch': 'CpuInfoArch' }, | |
3666a97f | 1368 | 'discriminator': 'arch', |
86f4b687 EB |
1369 | 'data': { 'x86': 'CpuInfoX86', |
1370 | 'sparc': 'CpuInfoSPARC', | |
1371 | 'ppc': 'CpuInfoPPC', | |
1372 | 'mips': 'CpuInfoMIPS', | |
1373 | 'tricore': 'CpuInfoTricore', | |
1374 | 'other': 'CpuInfoOther' } } | |
1375 | ||
1376 | ## | |
1377 | # @CpuInfoX86: | |
1378 | # | |
1379 | # Additional information about a virtual i386 or x86_64 CPU | |
1380 | # | |
1381 | # @pc: the 64-bit instruction pointer | |
1382 | # | |
5072f7b3 | 1383 | # Since: 2.6 |
86f4b687 EB |
1384 | ## |
1385 | { 'struct': 'CpuInfoX86', 'data': { 'pc': 'int' } } | |
1386 | ||
1387 | ## | |
1388 | # @CpuInfoSPARC: | |
1389 | # | |
1390 | # Additional information about a virtual SPARC CPU | |
1391 | # | |
1392 | # @pc: the PC component of the instruction pointer | |
1393 | # | |
1394 | # @npc: the NPC component of the instruction pointer | |
1395 | # | |
5072f7b3 | 1396 | # Since: 2.6 |
86f4b687 EB |
1397 | ## |
1398 | { 'struct': 'CpuInfoSPARC', 'data': { 'pc': 'int', 'npc': 'int' } } | |
1399 | ||
1400 | ## | |
1401 | # @CpuInfoPPC: | |
1402 | # | |
1403 | # Additional information about a virtual PPC CPU | |
1404 | # | |
1405 | # @nip: the instruction pointer | |
1406 | # | |
5072f7b3 | 1407 | # Since: 2.6 |
86f4b687 EB |
1408 | ## |
1409 | { 'struct': 'CpuInfoPPC', 'data': { 'nip': 'int' } } | |
1410 | ||
1411 | ## | |
1412 | # @CpuInfoMIPS: | |
1413 | # | |
1414 | # Additional information about a virtual MIPS CPU | |
1415 | # | |
1416 | # @PC: the instruction pointer | |
1417 | # | |
5072f7b3 | 1418 | # Since: 2.6 |
86f4b687 EB |
1419 | ## |
1420 | { 'struct': 'CpuInfoMIPS', 'data': { 'PC': 'int' } } | |
1421 | ||
1422 | ## | |
1423 | # @CpuInfoTricore: | |
1424 | # | |
1425 | # Additional information about a virtual Tricore CPU | |
1426 | # | |
1427 | # @PC: the instruction pointer | |
1428 | # | |
5072f7b3 | 1429 | # Since: 2.6 |
86f4b687 EB |
1430 | ## |
1431 | { 'struct': 'CpuInfoTricore', 'data': { 'PC': 'int' } } | |
1432 | ||
1433 | ## | |
1434 | # @CpuInfoOther: | |
1435 | # | |
1436 | # No additional information is available about the virtual CPU | |
1437 | # | |
5072f7b3 | 1438 | # Since: 2.6 |
86f4b687 EB |
1439 | # |
1440 | ## | |
1441 | { 'struct': 'CpuInfoOther', 'data': { } } | |
de0b36b6 LC |
1442 | |
1443 | ## | |
1444 | # @query-cpus: | |
1445 | # | |
1446 | # Returns a list of information about each virtual CPU. | |
1447 | # | |
1448 | # Returns: a list of @CpuInfo for each virtual CPU | |
1449 | # | |
1450 | # Since: 0.14.0 | |
5c5bee64 MAL |
1451 | # |
1452 | # Example: | |
1453 | # | |
1454 | # -> { "execute": "query-cpus" } | |
1455 | # <- { "return": [ | |
1456 | # { | |
1457 | # "CPU":0, | |
1458 | # "current":true, | |
1459 | # "halted":false, | |
1460 | # "qom_path":"/machine/unattached/device[0]", | |
1461 | # "arch":"x86", | |
1462 | # "pc":3227107138, | |
1463 | # "thread_id":3134 | |
1464 | # }, | |
1465 | # { | |
1466 | # "CPU":1, | |
1467 | # "current":false, | |
1468 | # "halted":true, | |
1469 | # "qom_path":"/machine/unattached/device[2]", | |
1470 | # "arch":"x86", | |
1471 | # "pc":7108165, | |
1472 | # "thread_id":3135 | |
1473 | # } | |
1474 | # ] | |
1475 | # } | |
1476 | # | |
de0b36b6 LC |
1477 | ## |
1478 | { 'command': 'query-cpus', 'returns': ['CpuInfo'] } | |
1479 | ||
dc3dd0d2 SH |
1480 | ## |
1481 | # @IOThreadInfo: | |
1482 | # | |
1483 | # Information about an iothread | |
1484 | # | |
1485 | # @id: the identifier of the iothread | |
1486 | # | |
1487 | # @thread-id: ID of the underlying host thread | |
1488 | # | |
5fc00480 PH |
1489 | # @poll-max-ns: maximum polling time in ns, 0 means polling is disabled |
1490 | # (since 2.9) | |
1491 | # | |
1492 | # @poll-grow: how many ns will be added to polling time, 0 means that it's not | |
1493 | # configured (since 2.9) | |
1494 | # | |
1495 | # @poll-shrink: how many ns will be removed from polling time, 0 means that | |
1496 | # it's not configured (since 2.9) | |
1497 | # | |
dc3dd0d2 SH |
1498 | # Since: 2.0 |
1499 | ## | |
895a2a80 | 1500 | { 'struct': 'IOThreadInfo', |
5fc00480 PH |
1501 | 'data': {'id': 'str', |
1502 | 'thread-id': 'int', | |
1503 | 'poll-max-ns': 'int', | |
1504 | 'poll-grow': 'int', | |
1505 | 'poll-shrink': 'int' } } | |
dc3dd0d2 SH |
1506 | |
1507 | ## | |
1508 | # @query-iothreads: | |
1509 | # | |
1510 | # Returns a list of information about each iothread. | |
1511 | # | |
5072f7b3 | 1512 | # Note: this list excludes the QEMU main loop thread, which is not declared |
dc3dd0d2 SH |
1513 | # using the -object iothread command-line option. It is always the main thread |
1514 | # of the process. | |
1515 | # | |
1516 | # Returns: a list of @IOThreadInfo for each iothread | |
1517 | # | |
1518 | # Since: 2.0 | |
fdf4d34f MAL |
1519 | # |
1520 | # Example: | |
1521 | # | |
1522 | # -> { "execute": "query-iothreads" } | |
1523 | # <- { "return": [ | |
1524 | # { | |
1525 | # "id":"iothread0", | |
1526 | # "thread-id":3134 | |
1527 | # }, | |
1528 | # { | |
1529 | # "id":"iothread1", | |
1530 | # "thread-id":3135 | |
1531 | # } | |
1532 | # ] | |
1533 | # } | |
1534 | # | |
dc3dd0d2 SH |
1535 | ## |
1536 | { 'command': 'query-iothreads', 'returns': ['IOThreadInfo'] } | |
1537 | ||
2b54aa87 | 1538 | ## |
5072f7b3 | 1539 | # @NetworkAddressFamily: |
2b54aa87 | 1540 | # |
a589569f WX |
1541 | # The network address family |
1542 | # | |
1543 | # @ipv4: IPV4 family | |
1544 | # | |
1545 | # @ipv6: IPV6 family | |
1546 | # | |
1547 | # @unix: unix socket | |
1548 | # | |
6a02c806 SH |
1549 | # @vsock: vsock family (since 2.8) |
1550 | # | |
a589569f WX |
1551 | # @unknown: otherwise |
1552 | # | |
1553 | # Since: 2.1 | |
1554 | ## | |
1555 | { 'enum': 'NetworkAddressFamily', | |
6a02c806 | 1556 | 'data': [ 'ipv4', 'ipv6', 'unix', 'vsock', 'unknown' ] } |
a589569f WX |
1557 | |
1558 | ## | |
5072f7b3 | 1559 | # @VncBasicInfo: |
2b54aa87 | 1560 | # |
a589569f | 1561 | # The basic information for vnc network connection |
2b54aa87 | 1562 | # |
a589569f | 1563 | # @host: IP address |
2b54aa87 | 1564 | # |
2f44a08b WX |
1565 | # @service: The service name of the vnc port. This may depend on the host |
1566 | # system's service database so symbolic names should not be relied | |
1567 | # on. | |
a589569f WX |
1568 | # |
1569 | # @family: address family | |
1570 | # | |
4478aa76 GH |
1571 | # @websocket: true in case the socket is a websocket (since 2.3). |
1572 | # | |
a589569f WX |
1573 | # Since: 2.1 |
1574 | ## | |
895a2a80 | 1575 | { 'struct': 'VncBasicInfo', |
a589569f WX |
1576 | 'data': { 'host': 'str', |
1577 | 'service': 'str', | |
4478aa76 GH |
1578 | 'family': 'NetworkAddressFamily', |
1579 | 'websocket': 'bool' } } | |
a589569f WX |
1580 | |
1581 | ## | |
5072f7b3 | 1582 | # @VncServerInfo: |
2b54aa87 | 1583 | # |
a589569f | 1584 | # The network connection information for server |
2b54aa87 | 1585 | # |
1d8bda12 | 1586 | # @auth: authentication method used for |
2a7e6857 | 1587 | # the plain (non-websocket) VNC server |
2b54aa87 | 1588 | # |
a589569f WX |
1589 | # Since: 2.1 |
1590 | ## | |
895a2a80 | 1591 | { 'struct': 'VncServerInfo', |
a589569f WX |
1592 | 'base': 'VncBasicInfo', |
1593 | 'data': { '*auth': 'str' } } | |
1594 | ||
1595 | ## | |
1596 | # @VncClientInfo: | |
1597 | # | |
1598 | # Information about a connected VNC client. | |
2b54aa87 | 1599 | # |
1d8bda12 | 1600 | # @x509_dname: If x509 authentication is in use, the Distinguished |
2b54aa87 LC |
1601 | # Name of the client. |
1602 | # | |
1d8bda12 | 1603 | # @sasl_username: If SASL authentication is in use, the SASL username |
2b54aa87 LC |
1604 | # used for authentication. |
1605 | # | |
1606 | # Since: 0.14.0 | |
1607 | ## | |
895a2a80 | 1608 | { 'struct': 'VncClientInfo', |
a589569f | 1609 | 'base': 'VncBasicInfo', |
2f44a08b | 1610 | 'data': { '*x509_dname': 'str', '*sasl_username': 'str' } } |
2b54aa87 LC |
1611 | |
1612 | ## | |
1613 | # @VncInfo: | |
1614 | # | |
1615 | # Information about the VNC session. | |
1616 | # | |
1617 | # @enabled: true if the VNC server is enabled, false otherwise | |
1618 | # | |
1d8bda12 | 1619 | # @host: The hostname the VNC server is bound to. This depends on |
2b54aa87 LC |
1620 | # the name resolution on the host and may be an IP address. |
1621 | # | |
1d8bda12 | 1622 | # @family: 'ipv6' if the host is listening for IPv6 connections |
2b54aa87 LC |
1623 | # 'ipv4' if the host is listening for IPv4 connections |
1624 | # 'unix' if the host is listening on a unix domain socket | |
1625 | # 'unknown' otherwise | |
1626 | # | |
1d8bda12 | 1627 | # @service: The service name of the server's port. This may depends |
2b54aa87 LC |
1628 | # on the host system's service database so symbolic names should not |
1629 | # be relied on. | |
1630 | # | |
1d8bda12 | 1631 | # @auth: the current authentication type used by the server |
2b54aa87 LC |
1632 | # 'none' if no authentication is being used |
1633 | # 'vnc' if VNC authentication is being used | |
1634 | # 'vencrypt+plain' if VEncrypt is used with plain text authentication | |
1635 | # 'vencrypt+tls+none' if VEncrypt is used with TLS and no authentication | |
1636 | # 'vencrypt+tls+vnc' if VEncrypt is used with TLS and VNC authentication | |
1637 | # 'vencrypt+tls+plain' if VEncrypt is used with TLS and plain text auth | |
1638 | # 'vencrypt+x509+none' if VEncrypt is used with x509 and no auth | |
1639 | # 'vencrypt+x509+vnc' if VEncrypt is used with x509 and VNC auth | |
1640 | # 'vencrypt+x509+plain' if VEncrypt is used with x509 and plain text auth | |
1641 | # 'vencrypt+tls+sasl' if VEncrypt is used with TLS and SASL auth | |
1642 | # 'vencrypt+x509+sasl' if VEncrypt is used with x509 and SASL auth | |
1643 | # | |
1644 | # @clients: a list of @VncClientInfo of all currently connected clients | |
1645 | # | |
1646 | # Since: 0.14.0 | |
1647 | ## | |
895a2a80 | 1648 | { 'struct': 'VncInfo', |
a589569f WX |
1649 | 'data': {'enabled': 'bool', '*host': 'str', |
1650 | '*family': 'NetworkAddressFamily', | |
2b54aa87 LC |
1651 | '*service': 'str', '*auth': 'str', '*clients': ['VncClientInfo']} } |
1652 | ||
df887684 | 1653 | ## |
4d5c8bc4 | 1654 | # @VncPrimaryAuth: |
df887684 GH |
1655 | # |
1656 | # vnc primary authentication method. | |
1657 | # | |
1658 | # Since: 2.3 | |
1659 | ## | |
1660 | { 'enum': 'VncPrimaryAuth', | |
1661 | 'data': [ 'none', 'vnc', 'ra2', 'ra2ne', 'tight', 'ultra', | |
1662 | 'tls', 'vencrypt', 'sasl' ] } | |
1663 | ||
1664 | ## | |
1665 | # @VncVencryptSubAuth: | |
1666 | # | |
1667 | # vnc sub authentication method with vencrypt. | |
1668 | # | |
1669 | # Since: 2.3 | |
1670 | ## | |
1671 | { 'enum': 'VncVencryptSubAuth', | |
1672 | 'data': [ 'plain', | |
1673 | 'tls-none', 'x509-none', | |
1674 | 'tls-vnc', 'x509-vnc', | |
1675 | 'tls-plain', 'x509-plain', | |
1676 | 'tls-sasl', 'x509-sasl' ] } | |
1677 | ||
2a7e6857 DB |
1678 | |
1679 | ## | |
1680 | # @VncServerInfo2: | |
1681 | # | |
1682 | # The network connection information for server | |
1683 | # | |
1684 | # @auth: The current authentication type used by the servers | |
1685 | # | |
1d8bda12 | 1686 | # @vencrypt: The vencrypt sub authentication type used by the |
2a7e6857 DB |
1687 | # servers, only specified in case auth == vencrypt. |
1688 | # | |
1689 | # Since: 2.9 | |
1690 | ## | |
1691 | { 'struct': 'VncServerInfo2', | |
1692 | 'base': 'VncBasicInfo', | |
1693 | 'data': { 'auth' : 'VncPrimaryAuth', | |
1694 | '*vencrypt' : 'VncVencryptSubAuth' } } | |
1695 | ||
1696 | ||
df887684 GH |
1697 | ## |
1698 | # @VncInfo2: | |
1699 | # | |
1700 | # Information about a vnc server | |
1701 | # | |
1702 | # @id: vnc server name. | |
1703 | # | |
1704 | # @server: A list of @VncBasincInfo describing all listening sockets. | |
1705 | # The list can be empty (in case the vnc server is disabled). | |
1706 | # It also may have multiple entries: normal + websocket, | |
1707 | # possibly also ipv4 + ipv6 in the future. | |
1708 | # | |
1709 | # @clients: A list of @VncClientInfo of all currently connected clients. | |
1710 | # The list can be empty, for obvious reasons. | |
1711 | # | |
2a7e6857 | 1712 | # @auth: The current authentication type used by the non-websockets servers |
df887684 | 1713 | # |
1d8bda12 | 1714 | # @vencrypt: The vencrypt authentication type used by the servers, |
df887684 GH |
1715 | # only specified in case auth == vencrypt. |
1716 | # | |
1d8bda12 | 1717 | # @display: The display device the vnc server is linked to. |
df887684 GH |
1718 | # |
1719 | # Since: 2.3 | |
1720 | ## | |
895a2a80 | 1721 | { 'struct': 'VncInfo2', |
df887684 | 1722 | 'data': { 'id' : 'str', |
2a7e6857 | 1723 | 'server' : ['VncServerInfo2'], |
df887684 GH |
1724 | 'clients' : ['VncClientInfo'], |
1725 | 'auth' : 'VncPrimaryAuth', | |
1726 | '*vencrypt' : 'VncVencryptSubAuth', | |
1727 | '*display' : 'str' } } | |
1728 | ||
2b54aa87 LC |
1729 | ## |
1730 | # @query-vnc: | |
1731 | # | |
1732 | # Returns information about the current VNC server | |
1733 | # | |
1734 | # Returns: @VncInfo | |
2b54aa87 LC |
1735 | # |
1736 | # Since: 0.14.0 | |
85f96549 MAL |
1737 | # |
1738 | # Example: | |
1739 | # | |
1740 | # -> { "execute": "query-vnc" } | |
1741 | # <- { "return": { | |
1742 | # "enabled":true, | |
1743 | # "host":"0.0.0.0", | |
1744 | # "service":"50402", | |
1745 | # "auth":"vnc", | |
1746 | # "family":"ipv4", | |
1747 | # "clients":[ | |
1748 | # { | |
1749 | # "host":"127.0.0.1", | |
1750 | # "service":"50401", | |
1751 | # "family":"ipv4" | |
1752 | # } | |
1753 | # ] | |
1754 | # } | |
1755 | # } | |
1756 | # | |
2b54aa87 LC |
1757 | ## |
1758 | { 'command': 'query-vnc', 'returns': 'VncInfo' } | |
1759 | ||
df887684 GH |
1760 | ## |
1761 | # @query-vnc-servers: | |
1762 | # | |
1763 | # Returns a list of vnc servers. The list can be empty. | |
1764 | # | |
1765 | # Returns: a list of @VncInfo2 | |
1766 | # | |
1767 | # Since: 2.3 | |
1768 | ## | |
1769 | { 'command': 'query-vnc-servers', 'returns': ['VncInfo2'] } | |
1770 | ||
d1f29646 | 1771 | ## |
5072f7b3 | 1772 | # @SpiceBasicInfo: |
d1f29646 | 1773 | # |
a589569f WX |
1774 | # The basic information for SPICE network connection |
1775 | # | |
1776 | # @host: IP address | |
d1f29646 | 1777 | # |
a589569f | 1778 | # @port: port number |
d1f29646 | 1779 | # |
a589569f | 1780 | # @family: address family |
d1f29646 | 1781 | # |
a589569f WX |
1782 | # Since: 2.1 |
1783 | ## | |
895a2a80 | 1784 | { 'struct': 'SpiceBasicInfo', |
a589569f WX |
1785 | 'data': { 'host': 'str', |
1786 | 'port': 'str', | |
1787 | 'family': 'NetworkAddressFamily' } } | |
1788 | ||
1789 | ## | |
5072f7b3 | 1790 | # @SpiceServerInfo: |
d1f29646 | 1791 | # |
a589569f | 1792 | # Information about a SPICE server |
d1f29646 | 1793 | # |
1d8bda12 | 1794 | # @auth: authentication method |
d1f29646 | 1795 | # |
a589569f WX |
1796 | # Since: 2.1 |
1797 | ## | |
895a2a80 | 1798 | { 'struct': 'SpiceServerInfo', |
a589569f WX |
1799 | 'base': 'SpiceBasicInfo', |
1800 | 'data': { '*auth': 'str' } } | |
1801 | ||
1802 | ## | |
5072f7b3 | 1803 | # @SpiceChannel: |
a589569f WX |
1804 | # |
1805 | # Information about a SPICE client channel. | |
d1f29646 LC |
1806 | # |
1807 | # @connection-id: SPICE connection id number. All channels with the same id | |
1808 | # belong to the same SPICE session. | |
1809 | # | |
7e781c79 CR |
1810 | # @channel-type: SPICE channel type number. "1" is the main control |
1811 | # channel, filter for this one if you want to track spice | |
1812 | # sessions only | |
d1f29646 | 1813 | # |
419e1bdf AL |
1814 | # @channel-id: SPICE channel ID number. Usually "0", might be different when |
1815 | # multiple channels of the same type exist, such as multiple | |
d1f29646 LC |
1816 | # display channels in a multihead setup |
1817 | # | |
1818 | # @tls: true if the channel is encrypted, false otherwise. | |
1819 | # | |
1820 | # Since: 0.14.0 | |
1821 | ## | |
895a2a80 | 1822 | { 'struct': 'SpiceChannel', |
a589569f WX |
1823 | 'base': 'SpiceBasicInfo', |
1824 | 'data': {'connection-id': 'int', 'channel-type': 'int', 'channel-id': 'int', | |
d1f29646 LC |
1825 | 'tls': 'bool'} } |
1826 | ||
4efee029 | 1827 | ## |
5072f7b3 | 1828 | # @SpiceQueryMouseMode: |
4efee029 | 1829 | # |
6932a69b | 1830 | # An enumeration of Spice mouse states. |
4efee029 AL |
1831 | # |
1832 | # @client: Mouse cursor position is determined by the client. | |
1833 | # | |
1834 | # @server: Mouse cursor position is determined by the server. | |
1835 | # | |
1836 | # @unknown: No information is available about mouse mode used by | |
1837 | # the spice server. | |
1838 | # | |
1839 | # Note: spice/enums.h has a SpiceMouseMode already, hence the name. | |
1840 | # | |
1841 | # Since: 1.1 | |
1842 | ## | |
1843 | { 'enum': 'SpiceQueryMouseMode', | |
1844 | 'data': [ 'client', 'server', 'unknown' ] } | |
1845 | ||
d1f29646 | 1846 | ## |
5072f7b3 | 1847 | # @SpiceInfo: |
d1f29646 LC |
1848 | # |
1849 | # Information about the SPICE session. | |
b80e560b | 1850 | # |
d1f29646 LC |
1851 | # @enabled: true if the SPICE server is enabled, false otherwise |
1852 | # | |
61c4efe2 | 1853 | # @migrated: true if the last guest migration completed and spice |
bc7e2602 | 1854 | # migration had completed as well. false otherwise. (since 1.4) |
61c4efe2 | 1855 | # |
1d8bda12 | 1856 | # @host: The hostname the SPICE server is bound to. This depends on |
d1f29646 LC |
1857 | # the name resolution on the host and may be an IP address. |
1858 | # | |
1d8bda12 | 1859 | # @port: The SPICE server's port number. |
d1f29646 | 1860 | # |
1d8bda12 | 1861 | # @compiled-version: SPICE server version. |
d1f29646 | 1862 | # |
1d8bda12 | 1863 | # @tls-port: The SPICE server's TLS port number. |
d1f29646 | 1864 | # |
1d8bda12 | 1865 | # @auth: the current authentication type used by the server |
419e1bdf AL |
1866 | # 'none' if no authentication is being used |
1867 | # 'spice' uses SASL or direct TLS authentication, depending on command | |
1868 | # line options | |
d1f29646 | 1869 | # |
4efee029 AL |
1870 | # @mouse-mode: The mode in which the mouse cursor is displayed currently. Can |
1871 | # be determined by the client or the server, or unknown if spice | |
bc7e2602 | 1872 | # server doesn't provide this information. (since: 1.1) |
4efee029 | 1873 | # |
d1f29646 LC |
1874 | # @channels: a list of @SpiceChannel for each active spice channel |
1875 | # | |
1876 | # Since: 0.14.0 | |
1877 | ## | |
895a2a80 | 1878 | { 'struct': 'SpiceInfo', |
61c4efe2 | 1879 | 'data': {'enabled': 'bool', 'migrated': 'bool', '*host': 'str', '*port': 'int', |
d1f29646 | 1880 | '*tls-port': 'int', '*auth': 'str', '*compiled-version': 'str', |
4efee029 | 1881 | 'mouse-mode': 'SpiceQueryMouseMode', '*channels': ['SpiceChannel']} } |
d1f29646 LC |
1882 | |
1883 | ## | |
5072f7b3 | 1884 | # @query-spice: |
d1f29646 LC |
1885 | # |
1886 | # Returns information about the current SPICE server | |
1887 | # | |
1888 | # Returns: @SpiceInfo | |
1889 | # | |
1890 | # Since: 0.14.0 | |
bc7e2602 MAL |
1891 | # |
1892 | # Example: | |
1893 | # | |
1894 | # -> { "execute": "query-spice" } | |
1895 | # <- { "return": { | |
1896 | # "enabled": true, | |
1897 | # "auth": "spice", | |
1898 | # "port": 5920, | |
1899 | # "tls-port": 5921, | |
1900 | # "host": "0.0.0.0", | |
1901 | # "channels": [ | |
1902 | # { | |
1903 | # "port": "54924", | |
1904 | # "family": "ipv4", | |
1905 | # "channel-type": 1, | |
1906 | # "connection-id": 1804289383, | |
1907 | # "host": "127.0.0.1", | |
1908 | # "channel-id": 0, | |
1909 | # "tls": true | |
1910 | # }, | |
1911 | # { | |
1912 | # "port": "36710", | |
1913 | # "family": "ipv4", | |
1914 | # "channel-type": 4, | |
1915 | # "connection-id": 1804289383, | |
1916 | # "host": "127.0.0.1", | |
1917 | # "channel-id": 0, | |
1918 | # "tls": false | |
1919 | # }, | |
1920 | # [ ... more channels follow ... ] | |
1921 | # ] | |
1922 | # } | |
1923 | # } | |
1924 | # | |
d1f29646 LC |
1925 | ## |
1926 | { 'command': 'query-spice', 'returns': 'SpiceInfo' } | |
1927 | ||
96637bcd LC |
1928 | ## |
1929 | # @BalloonInfo: | |
1930 | # | |
1931 | # Information about the guest balloon device. | |
1932 | # | |
1933 | # @actual: the number of bytes the balloon currently contains | |
1934 | # | |
96637bcd LC |
1935 | # Since: 0.14.0 |
1936 | # | |
96637bcd | 1937 | ## |
895a2a80 | 1938 | { 'struct': 'BalloonInfo', 'data': {'actual': 'int' } } |
96637bcd LC |
1939 | |
1940 | ## | |
1941 | # @query-balloon: | |
1942 | # | |
1943 | # Return information about the balloon device. | |
1944 | # | |
1945 | # Returns: @BalloonInfo on success | |
f504e3dc | 1946 | # |
96637bcd LC |
1947 | # If the balloon driver is enabled but not functional because the KVM |
1948 | # kernel module cannot support it, KvmMissingCap | |
f504e3dc | 1949 | # |
96637bcd LC |
1950 | # If no balloon device is present, DeviceNotActive |
1951 | # | |
1952 | # Since: 0.14.0 | |
f504e3dc MAL |
1953 | # |
1954 | # Example: | |
1955 | # | |
1956 | # -> { "execute": "query-balloon" } | |
1957 | # <- { "return": { | |
1958 | # "actual": 1073741824, | |
1959 | # } | |
1960 | # } | |
1961 | # | |
96637bcd LC |
1962 | ## |
1963 | { 'command': 'query-balloon', 'returns': 'BalloonInfo' } | |
1964 | ||
79627472 LC |
1965 | ## |
1966 | # @PciMemoryRange: | |
1967 | # | |
1968 | # A PCI device memory region | |
1969 | # | |
1970 | # @base: the starting address (guest physical) | |
1971 | # | |
1972 | # @limit: the ending address (guest physical) | |
1973 | # | |
1974 | # Since: 0.14.0 | |
1975 | ## | |
895a2a80 | 1976 | { 'struct': 'PciMemoryRange', 'data': {'base': 'int', 'limit': 'int'} } |
79627472 LC |
1977 | |
1978 | ## | |
5072f7b3 | 1979 | # @PciMemoryRegion: |
79627472 LC |
1980 | # |
1981 | # Information about a PCI device I/O region. | |
1982 | # | |
1983 | # @bar: the index of the Base Address Register for this region | |
1984 | # | |
1985 | # @type: 'io' if the region is a PIO region | |
1986 | # 'memory' if the region is a MMIO region | |
1987 | # | |
3fc3aa6d MAL |
1988 | # @size: memory size |
1989 | # | |
1d8bda12 | 1990 | # @prefetch: if @type is 'memory', true if the memory is prefetchable |
79627472 | 1991 | # |
1d8bda12 | 1992 | # @mem_type_64: if @type is 'memory', true if the BAR is 64-bit |
79627472 LC |
1993 | # |
1994 | # Since: 0.14.0 | |
1995 | ## | |
895a2a80 | 1996 | { 'struct': 'PciMemoryRegion', |
79627472 LC |
1997 | 'data': {'bar': 'int', 'type': 'str', 'address': 'int', 'size': 'int', |
1998 | '*prefetch': 'bool', '*mem_type_64': 'bool' } } | |
1999 | ||
2000 | ## | |
9fa02cd1 | 2001 | # @PciBusInfo: |
79627472 | 2002 | # |
9fa02cd1 | 2003 | # Information about a bus of a PCI Bridge device |
79627472 | 2004 | # |
9fa02cd1 EB |
2005 | # @number: primary bus interface number. This should be the number of the |
2006 | # bus the device resides on. | |
79627472 | 2007 | # |
9fa02cd1 EB |
2008 | # @secondary: secondary bus interface number. This is the number of the |
2009 | # main bus for the bridge | |
79627472 | 2010 | # |
9fa02cd1 EB |
2011 | # @subordinate: This is the highest number bus that resides below the |
2012 | # bridge. | |
79627472 | 2013 | # |
9fa02cd1 | 2014 | # @io_range: The PIO range for all devices on this bridge |
79627472 | 2015 | # |
9fa02cd1 | 2016 | # @memory_range: The MMIO range for all devices on this bridge |
79627472 | 2017 | # |
9fa02cd1 EB |
2018 | # @prefetchable_range: The range of prefetchable MMIO for all devices on |
2019 | # this bridge | |
2020 | # | |
2021 | # Since: 2.4 | |
2022 | ## | |
2023 | { 'struct': 'PciBusInfo', | |
2024 | 'data': {'number': 'int', 'secondary': 'int', 'subordinate': 'int', | |
2025 | 'io_range': 'PciMemoryRange', | |
2026 | 'memory_range': 'PciMemoryRange', | |
2027 | 'prefetchable_range': 'PciMemoryRange' } } | |
2028 | ||
2029 | ## | |
2030 | # @PciBridgeInfo: | |
2031 | # | |
2032 | # Information about a PCI Bridge device | |
2033 | # | |
2034 | # @bus: information about the bus the device resides on | |
79627472 LC |
2035 | # |
2036 | # @devices: a list of @PciDeviceInfo for each device on this bridge | |
2037 | # | |
2038 | # Since: 0.14.0 | |
2039 | ## | |
895a2a80 | 2040 | { 'struct': 'PciBridgeInfo', |
9fa02cd1 EB |
2041 | 'data': {'bus': 'PciBusInfo', '*devices': ['PciDeviceInfo']} } |
2042 | ||
2043 | ## | |
2044 | # @PciDeviceClass: | |
2045 | # | |
2046 | # Information about the Class of a PCI device | |
2047 | # | |
1d8bda12 | 2048 | # @desc: a string description of the device's class |
9fa02cd1 EB |
2049 | # |
2050 | # @class: the class code of the device | |
2051 | # | |
2052 | # Since: 2.4 | |
2053 | ## | |
2054 | { 'struct': 'PciDeviceClass', | |
2055 | 'data': {'*desc': 'str', 'class': 'int'} } | |
2056 | ||
2057 | ## | |
2058 | # @PciDeviceId: | |
2059 | # | |
2060 | # Information about the Id of a PCI device | |
2061 | # | |
2062 | # @device: the PCI device id | |
2063 | # | |
2064 | # @vendor: the PCI vendor id | |
2065 | # | |
2066 | # Since: 2.4 | |
2067 | ## | |
2068 | { 'struct': 'PciDeviceId', | |
2069 | 'data': {'device': 'int', 'vendor': 'int'} } | |
79627472 LC |
2070 | |
2071 | ## | |
2072 | # @PciDeviceInfo: | |
2073 | # | |
2074 | # Information about a PCI device | |
2075 | # | |
2076 | # @bus: the bus number of the device | |
2077 | # | |
2078 | # @slot: the slot the device is located in | |
2079 | # | |
2080 | # @function: the function of the slot used by the device | |
2081 | # | |
9fa02cd1 | 2082 | # @class_info: the class of the device |
79627472 | 2083 | # |
9fa02cd1 | 2084 | # @id: the PCI device id |
79627472 | 2085 | # |
1d8bda12 | 2086 | # @irq: if an IRQ is assigned to the device, the IRQ number |
79627472 LC |
2087 | # |
2088 | # @qdev_id: the device name of the PCI device | |
2089 | # | |
2090 | # @pci_bridge: if the device is a PCI bridge, the bridge information | |
2091 | # | |
2092 | # @regions: a list of the PCI I/O regions associated with the device | |
2093 | # | |
2094 | # Notes: the contents of @class_info.desc are not stable and should only be | |
2095 | # treated as informational. | |
2096 | # | |
2097 | # Since: 0.14.0 | |
2098 | ## | |
895a2a80 | 2099 | { 'struct': 'PciDeviceInfo', |
79627472 | 2100 | 'data': {'bus': 'int', 'slot': 'int', 'function': 'int', |
9fa02cd1 | 2101 | 'class_info': 'PciDeviceClass', 'id': 'PciDeviceId', |
79627472 LC |
2102 | '*irq': 'int', 'qdev_id': 'str', '*pci_bridge': 'PciBridgeInfo', |
2103 | 'regions': ['PciMemoryRegion']} } | |
2104 | ||
2105 | ## | |
2106 | # @PciInfo: | |
2107 | # | |
2108 | # Information about a PCI bus | |
2109 | # | |
2110 | # @bus: the bus index | |
2111 | # | |
2112 | # @devices: a list of devices on this bus | |
2113 | # | |
2114 | # Since: 0.14.0 | |
2115 | ## | |
895a2a80 | 2116 | { 'struct': 'PciInfo', 'data': {'bus': 'int', 'devices': ['PciDeviceInfo']} } |
79627472 LC |
2117 | |
2118 | ## | |
2119 | # @query-pci: | |
2120 | # | |
2121 | # Return information about the PCI bus topology of the guest. | |
2122 | # | |
3fc3aa6d MAL |
2123 | # Returns: a list of @PciInfo for each PCI bus. Each bus is |
2124 | # represented by a json-object, which has a key with a json-array of | |
2125 | # all PCI devices attached to it. Each device is represented by a | |
2126 | # json-object. | |
79627472 LC |
2127 | # |
2128 | # Since: 0.14.0 | |
3fc3aa6d MAL |
2129 | # |
2130 | # Example: | |
2131 | # | |
2132 | # -> { "execute": "query-pci" } | |
2133 | # <- { "return": [ | |
2134 | # { | |
2135 | # "bus": 0, | |
2136 | # "devices": [ | |
2137 | # { | |
2138 | # "bus": 0, | |
2139 | # "qdev_id": "", | |
2140 | # "slot": 0, | |
2141 | # "class_info": { | |
2142 | # "class": 1536, | |
2143 | # "desc": "Host bridge" | |
2144 | # }, | |
2145 | # "id": { | |
2146 | # "device": 32902, | |
2147 | # "vendor": 4663 | |
2148 | # }, | |
2149 | # "function": 0, | |
2150 | # "regions": [ | |
2151 | # ] | |
2152 | # }, | |
2153 | # { | |
2154 | # "bus": 0, | |
2155 | # "qdev_id": "", | |
2156 | # "slot": 1, | |
2157 | # "class_info": { | |
2158 | # "class": 1537, | |
2159 | # "desc": "ISA bridge" | |
2160 | # }, | |
2161 | # "id": { | |
2162 | # "device": 32902, | |
2163 | # "vendor": 28672 | |
2164 | # }, | |
2165 | # "function": 0, | |
2166 | # "regions": [ | |
2167 | # ] | |
2168 | # }, | |
2169 | # { | |
2170 | # "bus": 0, | |
2171 | # "qdev_id": "", | |
2172 | # "slot": 1, | |
2173 | # "class_info": { | |
2174 | # "class": 257, | |
2175 | # "desc": "IDE controller" | |
2176 | # }, | |
2177 | # "id": { | |
2178 | # "device": 32902, | |
2179 | # "vendor": 28688 | |
2180 | # }, | |
2181 | # "function": 1, | |
2182 | # "regions": [ | |
2183 | # { | |
2184 | # "bar": 4, | |
2185 | # "size": 16, | |
2186 | # "address": 49152, | |
2187 | # "type": "io" | |
2188 | # } | |
2189 | # ] | |
2190 | # }, | |
2191 | # { | |
2192 | # "bus": 0, | |
2193 | # "qdev_id": "", | |
2194 | # "slot": 2, | |
2195 | # "class_info": { | |
2196 | # "class": 768, | |
2197 | # "desc": "VGA controller" | |
2198 | # }, | |
2199 | # "id": { | |
2200 | # "device": 4115, | |
2201 | # "vendor": 184 | |
2202 | # }, | |
2203 | # "function": 0, | |
2204 | # "regions": [ | |
2205 | # { | |
2206 | # "prefetch": true, | |
2207 | # "mem_type_64": false, | |
2208 | # "bar": 0, | |
2209 | # "size": 33554432, | |
2210 | # "address": 4026531840, | |
2211 | # "type": "memory" | |
2212 | # }, | |
2213 | # { | |
2214 | # "prefetch": false, | |
2215 | # "mem_type_64": false, | |
2216 | # "bar": 1, | |
2217 | # "size": 4096, | |
2218 | # "address": 4060086272, | |
2219 | # "type": "memory" | |
2220 | # }, | |
2221 | # { | |
2222 | # "prefetch": false, | |
2223 | # "mem_type_64": false, | |
2224 | # "bar": 6, | |
2225 | # "size": 65536, | |
2226 | # "address": -1, | |
2227 | # "type": "memory" | |
2228 | # } | |
2229 | # ] | |
2230 | # }, | |
2231 | # { | |
2232 | # "bus": 0, | |
2233 | # "qdev_id": "", | |
2234 | # "irq": 11, | |
2235 | # "slot": 4, | |
2236 | # "class_info": { | |
2237 | # "class": 1280, | |
2238 | # "desc": "RAM controller" | |
2239 | # }, | |
2240 | # "id": { | |
2241 | # "device": 6900, | |
2242 | # "vendor": 4098 | |
2243 | # }, | |
2244 | # "function": 0, | |
2245 | # "regions": [ | |
2246 | # { | |
2247 | # "bar": 0, | |
2248 | # "size": 32, | |
2249 | # "address": 49280, | |
2250 | # "type": "io" | |
2251 | # } | |
2252 | # ] | |
2253 | # } | |
2254 | # ] | |
2255 | # } | |
2256 | # ] | |
2257 | # } | |
2258 | # | |
2259 | # Note: This example has been shortened as the real response is too long. | |
2260 | # | |
79627472 LC |
2261 | ## |
2262 | { 'command': 'query-pci', 'returns': ['PciInfo'] } | |
2263 | ||
7a7f325e LC |
2264 | ## |
2265 | # @quit: | |
2266 | # | |
2267 | # This command will cause the QEMU process to exit gracefully. While every | |
2268 | # attempt is made to send the QMP response before terminating, this is not | |
2269 | # guaranteed. When using this interface, a premature EOF would not be | |
2270 | # unexpected. | |
2271 | # | |
2272 | # Since: 0.14.0 | |
8046bf53 MAL |
2273 | # |
2274 | # Example: | |
2275 | # | |
2276 | # -> { "execute": "quit" } | |
2277 | # <- { "return": {} } | |
7a7f325e LC |
2278 | ## |
2279 | { 'command': 'quit' } | |
5f158f21 LC |
2280 | |
2281 | ## | |
2282 | # @stop: | |
2283 | # | |
2284 | # Stop all guest VCPU execution. | |
2285 | # | |
2286 | # Since: 0.14.0 | |
2287 | # | |
2288 | # Notes: This function will succeed even if the guest is already in the stopped | |
1e998146 PB |
2289 | # state. In "inmigrate" state, it will ensure that the guest |
2290 | # remains paused once migration finishes, as if the -S option was | |
2291 | # passed on the command line. | |
9787339e MAL |
2292 | # |
2293 | # Example: | |
2294 | # | |
2295 | # -> { "execute": "stop" } | |
2296 | # <- { "return": {} } | |
2297 | # | |
5f158f21 LC |
2298 | ## |
2299 | { 'command': 'stop' } | |
38d22653 LC |
2300 | |
2301 | ## | |
2302 | # @system_reset: | |
2303 | # | |
2304 | # Performs a hard reset of a guest. | |
2305 | # | |
2306 | # Since: 0.14.0 | |
cd98e00b MAL |
2307 | # |
2308 | # Example: | |
2309 | # | |
2310 | # -> { "execute": "system_reset" } | |
2311 | # <- { "return": {} } | |
2312 | # | |
38d22653 LC |
2313 | ## |
2314 | { 'command': 'system_reset' } | |
5bc465e4 LC |
2315 | |
2316 | ## | |
2317 | # @system_powerdown: | |
2318 | # | |
2319 | # Requests that a guest perform a powerdown operation. | |
2320 | # | |
2321 | # Since: 0.14.0 | |
2322 | # | |
2323 | # Notes: A guest may or may not respond to this command. This command | |
2324 | # returning does not indicate that a guest has accepted the request or | |
2325 | # that it has shut down. Many guests will respond to this command by | |
2326 | # prompting the user in some way. | |
04fcbabc MAL |
2327 | # Example: |
2328 | # | |
2329 | # -> { "execute": "system_powerdown" } | |
2330 | # <- { "return": {} } | |
2331 | # | |
5bc465e4 LC |
2332 | ## |
2333 | { 'command': 'system_powerdown' } | |
755f1968 LC |
2334 | |
2335 | ## | |
2336 | # @cpu: | |
2337 | # | |
2338 | # This command is a nop that is only provided for the purposes of compatibility. | |
2339 | # | |
2340 | # Since: 0.14.0 | |
2341 | # | |
2342 | # Notes: Do not use this command. | |
2343 | ## | |
2344 | { 'command': 'cpu', 'data': {'index': 'int'} } | |
0cfd6a9a | 2345 | |
69ca3ea5 | 2346 | ## |
5072f7b3 | 2347 | # @cpu-add: |
69ca3ea5 IM |
2348 | # |
2349 | # Adds CPU with specified ID | |
2350 | # | |
2351 | # @id: ID of CPU to be created, valid values [0..max_cpus) | |
2352 | # | |
2353 | # Returns: Nothing on success | |
2354 | # | |
5072f7b3 | 2355 | # Since: 1.5 |
a7b83754 MAL |
2356 | # |
2357 | # Example: | |
2358 | # | |
2359 | # -> { "execute": "cpu-add", "arguments": { "id": 2 } } | |
2360 | # <- { "return": {} } | |
2361 | # | |
69ca3ea5 IM |
2362 | ## |
2363 | { 'command': 'cpu-add', 'data': {'id': 'int'} } | |
2364 | ||
0cfd6a9a LC |
2365 | ## |
2366 | # @memsave: | |
2367 | # | |
2368 | # Save a portion of guest memory to a file. | |
2369 | # | |
2370 | # @val: the virtual address of the guest to start from | |
2371 | # | |
2372 | # @size: the size of memory region to save | |
2373 | # | |
2374 | # @filename: the file to save the memory to as binary data | |
2375 | # | |
1d8bda12 | 2376 | # @cpu-index: the index of the virtual CPU to use for translating the |
0cfd6a9a LC |
2377 | # virtual address (defaults to CPU 0) |
2378 | # | |
2379 | # Returns: Nothing on success | |
0cfd6a9a LC |
2380 | # |
2381 | # Since: 0.14.0 | |
2382 | # | |
2383 | # Notes: Errors were not reliably returned until 1.1 | |
30831b63 MAL |
2384 | # |
2385 | # Example: | |
2386 | # | |
2387 | # -> { "execute": "memsave", | |
2388 | # "arguments": { "val": 10, | |
2389 | # "size": 100, | |
2390 | # "filename": "/tmp/virtual-mem-dump" } } | |
2391 | # <- { "return": {} } | |
2392 | # | |
0cfd6a9a LC |
2393 | ## |
2394 | { 'command': 'memsave', | |
2395 | 'data': {'val': 'int', 'size': 'int', 'filename': 'str', '*cpu-index': 'int'} } | |
6d3962bf LC |
2396 | |
2397 | ## | |
2398 | # @pmemsave: | |
2399 | # | |
2400 | # Save a portion of guest physical memory to a file. | |
2401 | # | |
2402 | # @val: the physical address of the guest to start from | |
2403 | # | |
2404 | # @size: the size of memory region to save | |
2405 | # | |
2406 | # @filename: the file to save the memory to as binary data | |
2407 | # | |
2408 | # Returns: Nothing on success | |
6d3962bf LC |
2409 | # |
2410 | # Since: 0.14.0 | |
2411 | # | |
2412 | # Notes: Errors were not reliably returned until 1.1 | |
978d4d97 MAL |
2413 | # |
2414 | # Example: | |
2415 | # | |
2416 | # -> { "execute": "pmemsave", | |
2417 | # "arguments": { "val": 10, | |
2418 | # "size": 100, | |
2419 | # "filename": "/tmp/physical-mem-dump" } } | |
2420 | # <- { "return": {} } | |
2421 | # | |
6d3962bf LC |
2422 | ## |
2423 | { 'command': 'pmemsave', | |
2424 | 'data': {'val': 'int', 'size': 'int', 'filename': 'str'} } | |
e42e818b LC |
2425 | |
2426 | ## | |
2427 | # @cont: | |
2428 | # | |
2429 | # Resume guest VCPU execution. | |
2430 | # | |
2431 | # Since: 0.14.0 | |
2432 | # | |
2433 | # Returns: If successful, nothing | |
e42e818b | 2434 | # |
1e998146 PB |
2435 | # Notes: This command will succeed if the guest is currently running. It |
2436 | # will also succeed if the guest is in the "inmigrate" state; in | |
2437 | # this case, the effect of the command is to make sure the guest | |
2438 | # starts once migration finishes, removing the effect of the -S | |
2439 | # command line option if it was passed. | |
3815d0de MAL |
2440 | # |
2441 | # Example: | |
2442 | # | |
2443 | # -> { "execute": "cont" } | |
2444 | # <- { "return": {} } | |
2445 | # | |
e42e818b LC |
2446 | ## |
2447 | { 'command': 'cont' } | |
2448 | ||
9b9df25a GH |
2449 | ## |
2450 | # @system_wakeup: | |
2451 | # | |
2452 | # Wakeup guest from suspend. Does nothing in case the guest isn't suspended. | |
2453 | # | |
2454 | # Since: 1.1 | |
2455 | # | |
2456 | # Returns: nothing. | |
253cdee1 MAL |
2457 | # |
2458 | # Example: | |
2459 | # | |
2460 | # -> { "execute": "system_wakeup" } | |
2461 | # <- { "return": {} } | |
2462 | # | |
9b9df25a GH |
2463 | ## |
2464 | { 'command': 'system_wakeup' } | |
2465 | ||
ab49ab5c LC |
2466 | ## |
2467 | # @inject-nmi: | |
2468 | # | |
9cb805fd | 2469 | # Injects a Non-Maskable Interrupt into the default CPU (x86/s390) or all CPUs (ppc64). |
149ea099 | 2470 | # The command fails when the guest doesn't support injecting. |
ab49ab5c LC |
2471 | # |
2472 | # Returns: If successful, nothing | |
ab49ab5c LC |
2473 | # |
2474 | # Since: 0.14.0 | |
2475 | # | |
9cb805fd | 2476 | # Note: prior to 2.1, this command was only supported for x86 and s390 VMs |
149ea099 MAL |
2477 | # |
2478 | # Example: | |
2479 | # | |
2480 | # -> { "execute": "inject-nmi" } | |
2481 | # <- { "return": {} } | |
2482 | # | |
ab49ab5c LC |
2483 | ## |
2484 | { 'command': 'inject-nmi' } | |
4b37156c LC |
2485 | |
2486 | ## | |
2487 | # @set_link: | |
2488 | # | |
2489 | # Sets the link status of a virtual network adapter. | |
2490 | # | |
2491 | # @name: the device name of the virtual network adapter | |
2492 | # | |
2493 | # @up: true to set the link status to be up | |
2494 | # | |
2495 | # Returns: Nothing on success | |
2496 | # If @name is not a valid network device, DeviceNotFound | |
2497 | # | |
2498 | # Since: 0.14.0 | |
2499 | # | |
2500 | # Notes: Not all network adapters support setting link status. This command | |
2501 | # will succeed even if the network adapter does not support link status | |
2502 | # notification. | |
f9cfb8f7 MAL |
2503 | # |
2504 | # Example: | |
2505 | # | |
2506 | # -> { "execute": "set_link", | |
2507 | # "arguments": { "name": "e1000.0", "up": false } } | |
2508 | # <- { "return": {} } | |
2509 | # | |
4b37156c LC |
2510 | ## |
2511 | { 'command': 'set_link', 'data': {'name': 'str', 'up': 'bool'} } | |
a4dea8a9 | 2512 | |
d72f3264 LC |
2513 | ## |
2514 | # @balloon: | |
2515 | # | |
2516 | # Request the balloon driver to change its balloon size. | |
2517 | # | |
2518 | # @value: the target size of the balloon in bytes | |
2519 | # | |
2520 | # Returns: Nothing on success | |
2521 | # If the balloon driver is enabled but not functional because the KVM | |
2522 | # kernel module cannot support it, KvmMissingCap | |
2523 | # If no balloon device is present, DeviceNotActive | |
2524 | # | |
2525 | # Notes: This command just issues a request to the guest. When it returns, | |
2526 | # the balloon size may not have changed. A guest can change the balloon | |
2527 | # size independent of this command. | |
2528 | # | |
2529 | # Since: 0.14.0 | |
7b338db7 MAL |
2530 | # |
2531 | # Example: | |
2532 | # | |
2533 | # -> { "execute": "balloon", "arguments": { "value": 536870912 } } | |
2534 | # <- { "return": {} } | |
2535 | # | |
d72f3264 LC |
2536 | ## |
2537 | { 'command': 'balloon', 'data': {'value': 'int'} } | |
5e7caacb | 2538 | |
78b18b78 | 2539 | ## |
5072f7b3 | 2540 | # @Abort: |
78b18b78 SH |
2541 | # |
2542 | # This action can be used to test transaction failure. | |
2543 | # | |
2544 | # Since: 1.6 | |
5072f7b3 | 2545 | ## |
895a2a80 | 2546 | { 'struct': 'Abort', |
78b18b78 SH |
2547 | 'data': { } } |
2548 | ||
94d16a64 | 2549 | ## |
5072f7b3 | 2550 | # @ActionCompletionMode: |
94d16a64 JS |
2551 | # |
2552 | # An enumeration of Transactional completion modes. | |
2553 | # | |
2554 | # @individual: Do not attempt to cancel any other Actions if any Actions fail | |
2555 | # after the Transaction request succeeds. All Actions that | |
2556 | # can complete successfully will do so without waiting on others. | |
2557 | # This is the default. | |
2558 | # | |
2559 | # @grouped: If any Action fails after the Transaction succeeds, cancel all | |
2560 | # Actions. Actions do not complete until all Actions are ready to | |
2561 | # complete. May be rejected by Actions that do not support this | |
2562 | # completion mode. | |
2563 | # | |
2564 | # Since: 2.5 | |
2565 | ## | |
2566 | { 'enum': 'ActionCompletionMode', | |
2567 | 'data': [ 'individual', 'grouped' ] } | |
2568 | ||
8802d1fd | 2569 | ## |
5072f7b3 | 2570 | # @TransactionAction: |
8802d1fd | 2571 | # |
52e7c241 | 2572 | # A discriminated record of operations that can be performed with |
41dc1dc0 | 2573 | # @transaction. Action @type can be: |
b7b9d39a | 2574 | # |
41dc1dc0 MAL |
2575 | # - @abort: since 1.6 |
2576 | # - @block-dirty-bitmap-add: since 2.5 | |
2577 | # - @block-dirty-bitmap-clear: since 2.5 | |
2578 | # - @blockdev-backup: since 2.3 | |
2579 | # - @blockdev-snapshot: since 2.5 | |
2580 | # - @blockdev-snapshot-internal-sync: since 1.7 | |
2581 | # - @blockdev-snapshot-sync: since 1.1 | |
2582 | # - @drive-backup: since 1.6 | |
b7b9d39a | 2583 | # |
41dc1dc0 | 2584 | # Since: 1.1 |
8802d1fd | 2585 | ## |
c8a83e85 | 2586 | { 'union': 'TransactionAction', |
52e7c241 | 2587 | 'data': { |
bbe86010 | 2588 | 'abort': 'Abort', |
df9a681d | 2589 | 'block-dirty-bitmap-add': 'BlockDirtyBitmapAdd', |
41dc1dc0 MAL |
2590 | 'block-dirty-bitmap-clear': 'BlockDirtyBitmap', |
2591 | 'blockdev-backup': 'BlockdevBackup', | |
2592 | 'blockdev-snapshot': 'BlockdevSnapshot', | |
2593 | 'blockdev-snapshot-internal-sync': 'BlockdevSnapshotInternal', | |
2594 | 'blockdev-snapshot-sync': 'BlockdevSnapshotSync', | |
2595 | 'drive-backup': 'DriveBackup' | |
52e7c241 | 2596 | } } |
8802d1fd | 2597 | |
94d16a64 | 2598 | ## |
5072f7b3 | 2599 | # @TransactionProperties: |
94d16a64 JS |
2600 | # |
2601 | # Optional arguments to modify the behavior of a Transaction. | |
2602 | # | |
1d8bda12 | 2603 | # @completion-mode: Controls how jobs launched asynchronously by |
94d16a64 JS |
2604 | # Actions will complete or fail as a group. |
2605 | # See @ActionCompletionMode for details. | |
2606 | # | |
2607 | # Since: 2.5 | |
2608 | ## | |
2609 | { 'struct': 'TransactionProperties', | |
2610 | 'data': { | |
2611 | '*completion-mode': 'ActionCompletionMode' | |
2612 | } | |
2613 | } | |
2614 | ||
8802d1fd | 2615 | ## |
5072f7b3 | 2616 | # @transaction: |
8802d1fd | 2617 | # |
c8a83e85 KW |
2618 | # Executes a number of transactionable QMP commands atomically. If any |
2619 | # operation fails, then the entire set of actions will be abandoned and the | |
2620 | # appropriate error returned. | |
8802d1fd | 2621 | # |
5c82b0f1 MAL |
2622 | # For external snapshots, the dictionary contains the device, the file to use for |
2623 | # the new snapshot, and the format. The default format, if not specified, is | |
2624 | # qcow2. | |
2625 | # | |
2626 | # Each new snapshot defaults to being created by QEMU (wiping any | |
2627 | # contents if the file already exists), but it is also possible to reuse | |
2628 | # an externally-created file. In the latter case, you should ensure that | |
2629 | # the new image file has the same contents as the current one; QEMU cannot | |
2630 | # perform any meaningful check. Typically this is achieved by using the | |
2631 | # current image file as the backing file for the new image. | |
2632 | # | |
2633 | # On failure, the original disks pre-snapshot attempt will be used. | |
2634 | # | |
2635 | # For internal snapshots, the dictionary contains the device and the snapshot's | |
2636 | # name. If an internal snapshot matching name already exists, the request will | |
2637 | # be rejected. Only some image formats support it, for example, qcow2, rbd, | |
2638 | # and sheepdog. | |
2639 | # | |
2640 | # On failure, qemu will try delete the newly created internal snapshot in the | |
2641 | # transaction. When an I/O error occurs during deletion, the user needs to fix | |
2642 | # it later with qemu-img or other command. | |
2643 | # | |
94d16a64 JS |
2644 | # @actions: List of @TransactionAction; |
2645 | # information needed for the respective operations. | |
2646 | # | |
1d8bda12 | 2647 | # @properties: structure of additional options to control the |
94d16a64 JS |
2648 | # execution of the transaction. See @TransactionProperties |
2649 | # for additional detail. | |
8802d1fd JC |
2650 | # |
2651 | # Returns: nothing on success | |
5c82b0f1 | 2652 | # |
c8a83e85 | 2653 | # Errors depend on the operations of the transaction |
8802d1fd | 2654 | # |
c8a83e85 KW |
2655 | # Note: The transaction aborts on the first failure. Therefore, there will be |
2656 | # information on only one failed operation returned in an error condition, and | |
52e7c241 PB |
2657 | # subsequent actions will not have been attempted. |
2658 | # | |
5072f7b3 | 2659 | # Since: 1.1 |
5c82b0f1 MAL |
2660 | # |
2661 | # Example: | |
2662 | # | |
2663 | # -> { "execute": "transaction", | |
2664 | # "arguments": { "actions": [ | |
2665 | # { "type": "blockdev-snapshot-sync", "data" : { "device": "ide-hd0", | |
2666 | # "snapshot-file": "/some/place/my-image", | |
2667 | # "format": "qcow2" } }, | |
2668 | # { "type": "blockdev-snapshot-sync", "data" : { "node-name": "myfile", | |
2669 | # "snapshot-file": "/some/place/my-image2", | |
2670 | # "snapshot-node-name": "node3432", | |
2671 | # "mode": "existing", | |
2672 | # "format": "qcow2" } }, | |
2673 | # { "type": "blockdev-snapshot-sync", "data" : { "device": "ide-hd1", | |
2674 | # "snapshot-file": "/some/place/my-image2", | |
2675 | # "mode": "existing", | |
2676 | # "format": "qcow2" } }, | |
2677 | # { "type": "blockdev-snapshot-internal-sync", "data" : { | |
2678 | # "device": "ide-hd2", | |
2679 | # "name": "snapshot0" } } ] } } | |
2680 | # <- { "return": {} } | |
2681 | # | |
8802d1fd | 2682 | ## |
52e7c241 | 2683 | { 'command': 'transaction', |
94d16a64 JS |
2684 | 'data': { 'actions': [ 'TransactionAction' ], |
2685 | '*properties': 'TransactionProperties' | |
2686 | } | |
2687 | } | |
8802d1fd | 2688 | |
d51a67b4 LC |
2689 | ## |
2690 | # @human-monitor-command: | |
2691 | # | |
2692 | # Execute a command on the human monitor and return the output. | |
2693 | # | |
2694 | # @command-line: the command to execute in the human monitor | |
2695 | # | |
1d8bda12 | 2696 | # @cpu-index: The CPU to use for commands that require an implicit CPU |
d51a67b4 LC |
2697 | # |
2698 | # Returns: the output of the command as a string | |
2699 | # | |
1ad166b6 | 2700 | # Since: 0.14.0 |
08e4ed6c | 2701 | # |
1ad166b6 | 2702 | # Notes: This command only exists as a stop-gap. Its use is highly |
e9ac76ac MAL |
2703 | # discouraged. The semantics of this command are not |
2704 | # guaranteed: this means that command names, arguments and | |
2705 | # responses can change or be removed at ANY time. Applications | |
2706 | # that rely on long term stability guarantees should NOT | |
2707 | # use this command. | |
b952b558 | 2708 | # |
1ad166b6 | 2709 | # Known limitations: |
b952b558 | 2710 | # |
3df58d41 | 2711 | # * This command is stateless, this means that commands that depend |
1ad166b6 | 2712 | # on state information (such as getfd) might not work |
d9b902db | 2713 | # |
788cf9f8 | 2714 | # * Commands that prompt the user for data don't currently work |
e9ac76ac MAL |
2715 | # |
2716 | # Example: | |
2717 | # | |
2718 | # -> { "execute": "human-monitor-command", | |
2719 | # "arguments": { "command-line": "info kvm" } } | |
2720 | # <- { "return": "kvm support: enabled\r\n" } | |
2721 | # | |
d9b902db | 2722 | ## |
1ad166b6 BC |
2723 | { 'command': 'human-monitor-command', |
2724 | 'data': {'command-line': 'str', '*cpu-index': 'int'}, | |
2725 | 'returns': 'str' } | |
d9b902db PB |
2726 | |
2727 | ## | |
5072f7b3 | 2728 | # @migrate_cancel: |
6cdedb07 LC |
2729 | # |
2730 | # Cancel the current executing migration process. | |
2731 | # | |
2732 | # Returns: nothing on success | |
2733 | # | |
2734 | # Notes: This command succeeds even if there is no migration process running. | |
2735 | # | |
2736 | # Since: 0.14.0 | |
92dcfb43 MAL |
2737 | # |
2738 | # Example: | |
2739 | # | |
2740 | # -> { "execute": "migrate_cancel" } | |
2741 | # <- { "return": {} } | |
2742 | # | |
6cdedb07 LC |
2743 | ## |
2744 | { 'command': 'migrate_cancel' } | |
4f0a993b LC |
2745 | |
2746 | ## | |
5072f7b3 | 2747 | # @migrate_set_downtime: |
4f0a993b LC |
2748 | # |
2749 | # Set maximum tolerated downtime for migration. | |
2750 | # | |
2751 | # @value: maximum downtime in seconds | |
2752 | # | |
2753 | # Returns: nothing on success | |
2754 | # | |
2ff30257 AA |
2755 | # Notes: This command is deprecated in favor of 'migrate-set-parameters' |
2756 | # | |
4f0a993b | 2757 | # Since: 0.14.0 |
de0b45ea MAL |
2758 | # |
2759 | # Example: | |
2760 | # | |
2761 | # -> { "execute": "migrate_set_downtime", "arguments": { "value": 0.1 } } | |
2762 | # <- { "return": {} } | |
2763 | # | |
4f0a993b LC |
2764 | ## |
2765 | { 'command': 'migrate_set_downtime', 'data': {'value': 'number'} } | |
3dc85383 LC |
2766 | |
2767 | ## | |
5072f7b3 | 2768 | # @migrate_set_speed: |
3dc85383 LC |
2769 | # |
2770 | # Set maximum speed for migration. | |
2771 | # | |
ab989533 | 2772 | # @value: maximum speed in bytes per second. |
3dc85383 LC |
2773 | # |
2774 | # Returns: nothing on success | |
2775 | # | |
2ff30257 | 2776 | # Notes: This command is deprecated in favor of 'migrate-set-parameters' |
3dc85383 LC |
2777 | # |
2778 | # Since: 0.14.0 | |
ab989533 MAL |
2779 | # |
2780 | # Example: | |
2781 | # | |
2782 | # -> { "execute": "migrate_set_speed", "arguments": { "value": 1024 } } | |
2783 | # <- { "return": {} } | |
2784 | # | |
3dc85383 LC |
2785 | ## |
2786 | { 'command': 'migrate_set_speed', 'data': {'value': 'int'} } | |
b4b12c62 | 2787 | |
9e1ba4cc | 2788 | ## |
5072f7b3 | 2789 | # @migrate-set-cache-size: |
9e1ba4cc | 2790 | # |
8f457b67 | 2791 | # Set cache size to be used by XBZRLE migration |
9e1ba4cc OW |
2792 | # |
2793 | # @value: cache size in bytes | |
2794 | # | |
2795 | # The size will be rounded down to the nearest power of 2. | |
2796 | # The cache size can be modified before and during ongoing migration | |
2797 | # | |
2798 | # Returns: nothing on success | |
2799 | # | |
2800 | # Since: 1.2 | |
8f457b67 MAL |
2801 | # |
2802 | # Example: | |
2803 | # | |
2804 | # -> { "execute": "migrate-set-cache-size", | |
2805 | # "arguments": { "value": 536870912 } } | |
2806 | # <- { "return": {} } | |
2807 | # | |
9e1ba4cc OW |
2808 | ## |
2809 | { 'command': 'migrate-set-cache-size', 'data': {'value': 'int'} } | |
2810 | ||
2811 | ## | |
5072f7b3 | 2812 | # @query-migrate-cache-size: |
9e1ba4cc | 2813 | # |
b953601b | 2814 | # Query migration XBZRLE cache size |
9e1ba4cc OW |
2815 | # |
2816 | # Returns: XBZRLE cache size in bytes | |
2817 | # | |
2818 | # Since: 1.2 | |
b953601b MAL |
2819 | # |
2820 | # Example: | |
2821 | # | |
2822 | # -> { "execute": "query-migrate-cache-size" } | |
2823 | # <- { "return": 67108864 } | |
2824 | # | |
9e1ba4cc OW |
2825 | ## |
2826 | { 'command': 'query-migrate-cache-size', 'returns': 'int' } | |
2827 | ||
b4b12c62 | 2828 | ## |
d03ee401 | 2829 | # @ObjectPropertyInfo: |
b4b12c62 AL |
2830 | # |
2831 | # @name: the name of the property | |
2832 | # | |
2833 | # @type: the type of the property. This will typically come in one of four | |
2834 | # forms: | |
2835 | # | |
2836 | # 1) A primitive type such as 'u8', 'u16', 'bool', 'str', or 'double'. | |
2837 | # These types are mapped to the appropriate JSON type. | |
2838 | # | |
33b23b4b | 2839 | # 2) A child type in the form 'child<subtype>' where subtype is a qdev |
b4b12c62 AL |
2840 | # device type name. Child properties create the composition tree. |
2841 | # | |
33b23b4b | 2842 | # 3) A link type in the form 'link<subtype>' where subtype is a qdev |
b4b12c62 AL |
2843 | # device type name. Link properties form the device model graph. |
2844 | # | |
51920820 | 2845 | # Since: 1.2 |
b4b12c62 | 2846 | ## |
895a2a80 | 2847 | { 'struct': 'ObjectPropertyInfo', |
b4b12c62 AL |
2848 | 'data': { 'name': 'str', 'type': 'str' } } |
2849 | ||
2850 | ## | |
2851 | # @qom-list: | |
2852 | # | |
57c9fafe | 2853 | # This command will list any properties of a object given a path in the object |
b4b12c62 AL |
2854 | # model. |
2855 | # | |
57c9fafe | 2856 | # @path: the path within the object model. See @qom-get for a description of |
b4b12c62 AL |
2857 | # this parameter. |
2858 | # | |
57c9fafe AL |
2859 | # Returns: a list of @ObjectPropertyInfo that describe the properties of the |
2860 | # object. | |
b4b12c62 | 2861 | # |
51920820 | 2862 | # Since: 1.2 |
b4b12c62 AL |
2863 | ## |
2864 | { 'command': 'qom-list', | |
2865 | 'data': { 'path': 'str' }, | |
57c9fafe | 2866 | 'returns': [ 'ObjectPropertyInfo' ] } |
eb6e8ea5 AL |
2867 | |
2868 | ## | |
2869 | # @qom-get: | |
2870 | # | |
57c9fafe | 2871 | # This command will get a property from a object model path and return the |
eb6e8ea5 AL |
2872 | # value. |
2873 | # | |
57c9fafe | 2874 | # @path: The path within the object model. There are two forms of supported |
eb6e8ea5 AL |
2875 | # paths--absolute and partial paths. |
2876 | # | |
57c9fafe | 2877 | # Absolute paths are derived from the root object and can follow child<> |
eb6e8ea5 AL |
2878 | # or link<> properties. Since they can follow link<> properties, they |
2879 | # can be arbitrarily long. Absolute paths look like absolute filenames | |
2880 | # and are prefixed with a leading slash. | |
2881 | # | |
2882 | # Partial paths look like relative filenames. They do not begin | |
2883 | # with a prefix. The matching rules for partial paths are subtle but | |
57c9fafe | 2884 | # designed to make specifying objects easy. At each level of the |
eb6e8ea5 AL |
2885 | # composition tree, the partial path is matched as an absolute path. |
2886 | # The first match is not returned. At least two matches are searched | |
2887 | # for. A successful result is only returned if only one match is | |
2888 | # found. If more than one match is found, a flag is return to | |
2889 | # indicate that the match was ambiguous. | |
2890 | # | |
2891 | # @property: The property name to read | |
2892 | # | |
33b23b4b MAL |
2893 | # Returns: The property value. The type depends on the property |
2894 | # type. child<> and link<> properties are returned as #str | |
2895 | # pathnames. All integer property types (u8, u16, etc) are | |
2896 | # returned as #int. | |
eb6e8ea5 | 2897 | # |
51920820 | 2898 | # Since: 1.2 |
eb6e8ea5 AL |
2899 | ## |
2900 | { 'command': 'qom-get', | |
2901 | 'data': { 'path': 'str', 'property': 'str' }, | |
6eb3937e | 2902 | 'returns': 'any' } |
eb6e8ea5 AL |
2903 | |
2904 | ## | |
2905 | # @qom-set: | |
2906 | # | |
57c9fafe | 2907 | # This command will set a property from a object model path. |
eb6e8ea5 AL |
2908 | # |
2909 | # @path: see @qom-get for a description of this parameter | |
2910 | # | |
2911 | # @property: the property name to set | |
2912 | # | |
2913 | # @value: a value who's type is appropriate for the property type. See @qom-get | |
2914 | # for a description of type mapping. | |
2915 | # | |
51920820 | 2916 | # Since: 1.2 |
eb6e8ea5 AL |
2917 | ## |
2918 | { 'command': 'qom-set', | |
6eb3937e | 2919 | 'data': { 'path': 'str', 'property': 'str', 'value': 'any' } } |
fbf796fd LC |
2920 | |
2921 | ## | |
2922 | # @set_password: | |
2923 | # | |
2924 | # Sets the password of a remote display session. | |
2925 | # | |
2926 | # @protocol: `vnc' to modify the VNC server password | |
2927 | # `spice' to modify the Spice server password | |
2928 | # | |
2929 | # @password: the new password | |
2930 | # | |
1d8bda12 | 2931 | # @connected: how to handle existing clients when changing the |
b80e560b | 2932 | # password. If nothing is specified, defaults to `keep' |
fbf796fd LC |
2933 | # `fail' to fail the command if clients are connected |
2934 | # `disconnect' to disconnect existing clients | |
2935 | # `keep' to maintain existing clients | |
2936 | # | |
2937 | # Returns: Nothing on success | |
2938 | # If Spice is not enabled, DeviceNotFound | |
fbf796fd LC |
2939 | # |
2940 | # Since: 0.14.0 | |
4d8a374e MAL |
2941 | # |
2942 | # Example: | |
2943 | # | |
2944 | # -> { "execute": "set_password", "arguments": { "protocol": "vnc", | |
2945 | # "password": "secret" } } | |
2946 | # <- { "return": {} } | |
2947 | # | |
fbf796fd LC |
2948 | ## |
2949 | { 'command': 'set_password', | |
2950 | 'data': {'protocol': 'str', 'password': 'str', '*connected': 'str'} } | |
9ad5372d LC |
2951 | |
2952 | ## | |
2953 | # @expire_password: | |
2954 | # | |
2955 | # Expire the password of a remote display server. | |
2956 | # | |
2957 | # @protocol: the name of the remote display protocol `vnc' or `spice' | |
2958 | # | |
2959 | # @time: when to expire the password. | |
2960 | # `now' to expire the password immediately | |
2961 | # `never' to cancel password expiration | |
2962 | # `+INT' where INT is the number of seconds from now (integer) | |
2963 | # `INT' where INT is the absolute time in seconds | |
2964 | # | |
2965 | # Returns: Nothing on success | |
2966 | # If @protocol is `spice' and Spice is not active, DeviceNotFound | |
9ad5372d LC |
2967 | # |
2968 | # Since: 0.14.0 | |
2969 | # | |
2970 | # Notes: Time is relative to the server and currently there is no way to | |
2971 | # coordinate server time with client time. It is not recommended to | |
2972 | # use the absolute time version of the @time parameter unless you're | |
2973 | # sure you are on the same machine as the QEMU instance. | |
342816b9 MAL |
2974 | # |
2975 | # Example: | |
2976 | # | |
2977 | # -> { "execute": "expire_password", "arguments": { "protocol": "vnc", | |
2978 | # "time": "+60" } } | |
2979 | # <- { "return": {} } | |
2980 | # | |
9ad5372d LC |
2981 | ## |
2982 | { 'command': 'expire_password', 'data': {'protocol': 'str', 'time': 'str'} } | |
c245b6a3 | 2983 | |
270b243f LC |
2984 | ## |
2985 | # @change-vnc-password: | |
2986 | # | |
2987 | # Change the VNC server password. | |
2988 | # | |
1c854067 | 2989 | # @password: the new password to use with VNC authentication |
270b243f LC |
2990 | # |
2991 | # Since: 1.1 | |
2992 | # | |
2993 | # Notes: An empty password in this command will set the password to the empty | |
2994 | # string. Existing clients are unaffected by executing this command. | |
2995 | ## | |
2996 | { 'command': 'change-vnc-password', 'data': {'password': 'str'} } | |
333a96ec LC |
2997 | |
2998 | ## | |
2999 | # @change: | |
3000 | # | |
3001 | # This command is multiple commands multiplexed together. | |
3002 | # | |
3003 | # @device: This is normally the name of a block device but it may also be 'vnc'. | |
3004 | # when it's 'vnc', then sub command depends on @target | |
3005 | # | |
3006 | # @target: If @device is a block device, then this is the new filename. | |
3007 | # If @device is 'vnc', then if the value 'password' selects the vnc | |
3008 | # change password command. Otherwise, this specifies a new server URI | |
3009 | # address to listen to for VNC connections. | |
3010 | # | |
3011 | # @arg: If @device is a block device, then this is an optional format to open | |
3012 | # the device with. | |
3013 | # If @device is 'vnc' and @target is 'password', this is the new VNC | |
6dfe8eab | 3014 | # password to set. See change-vnc-password for additional notes. |
333a96ec LC |
3015 | # |
3016 | # Returns: Nothing on success. | |
3017 | # If @device is not a valid block device, DeviceNotFound | |
333a96ec | 3018 | # |
24fb4133 HR |
3019 | # Notes: This interface is deprecated, and it is strongly recommended that you |
3020 | # avoid using it. For changing block devices, use | |
3021 | # blockdev-change-medium; for changing VNC parameters, use | |
3022 | # change-vnc-password. | |
333a96ec LC |
3023 | # |
3024 | # Since: 0.14.0 | |
01387ae5 MAL |
3025 | # |
3026 | # Example: | |
3027 | # | |
3028 | # 1. Change a removable medium | |
3029 | # | |
3030 | # -> { "execute": "change", | |
3031 | # "arguments": { "device": "ide1-cd0", | |
3032 | # "target": "/srv/images/Fedora-12-x86_64-DVD.iso" } } | |
3033 | # <- { "return": {} } | |
3034 | # | |
3035 | # 2. Change VNC password | |
3036 | # | |
3037 | # -> { "execute": "change", | |
3038 | # "arguments": { "device": "vnc", "target": "password", | |
3039 | # "arg": "foobar1" } } | |
3040 | # <- { "return": {} } | |
3041 | # | |
333a96ec LC |
3042 | ## |
3043 | { 'command': 'change', | |
3044 | 'data': {'device': 'str', 'target': 'str', '*arg': 'str'} } | |
80047da5 | 3045 | |
5eeee3fa AL |
3046 | ## |
3047 | # @ObjectTypeInfo: | |
3048 | # | |
3049 | # This structure describes a search result from @qom-list-types | |
3050 | # | |
3051 | # @name: the type name found in the search | |
3052 | # | |
87467eae EH |
3053 | # @abstract: the type is abstract and can't be directly instantiated. |
3054 | # Omitted if false. (since 2.10) | |
3055 | # | |
f86285c5 EH |
3056 | # @parent: Name of parent type, if any (since 2.10) |
3057 | # | |
5eeee3fa | 3058 | # Since: 1.1 |
5eeee3fa | 3059 | ## |
895a2a80 | 3060 | { 'struct': 'ObjectTypeInfo', |
f86285c5 | 3061 | 'data': { 'name': 'str', '*abstract': 'bool', '*parent': 'str' } } |
5eeee3fa AL |
3062 | |
3063 | ## | |
3064 | # @qom-list-types: | |
3065 | # | |
3066 | # This command will return a list of types given search parameters | |
3067 | # | |
3068 | # @implements: if specified, only return types that implement this type name | |
3069 | # | |
3070 | # @abstract: if true, include abstract types in the results | |
3071 | # | |
3072 | # Returns: a list of @ObjectTypeInfo or an empty list if no results are found | |
3073 | # | |
3074 | # Since: 1.1 | |
5eeee3fa AL |
3075 | ## |
3076 | { 'command': 'qom-list-types', | |
3077 | 'data': { '*implements': 'str', '*abstract': 'bool' }, | |
3078 | 'returns': [ 'ObjectTypeInfo' ] } | |
e1c37d0e | 3079 | |
1daa31b9 AL |
3080 | ## |
3081 | # @DevicePropertyInfo: | |
3082 | # | |
3083 | # Information about device properties. | |
3084 | # | |
3085 | # @name: the name of the property | |
3086 | # @type: the typename of the property | |
1d8bda12 | 3087 | # @description: if specified, the description of the property. |
07d09c58 | 3088 | # (since 2.2) |
1daa31b9 AL |
3089 | # |
3090 | # Since: 1.2 | |
3091 | ## | |
895a2a80 | 3092 | { 'struct': 'DevicePropertyInfo', |
07d09c58 | 3093 | 'data': { 'name': 'str', 'type': 'str', '*description': 'str' } } |
1daa31b9 AL |
3094 | |
3095 | ## | |
3096 | # @device-list-properties: | |
3097 | # | |
3098 | # List properties associated with a device. | |
3099 | # | |
3100 | # @typename: the type name of a device | |
3101 | # | |
3102 | # Returns: a list of DevicePropertyInfo describing a devices properties | |
3103 | # | |
3104 | # Since: 1.2 | |
3105 | ## | |
3106 | { 'command': 'device-list-properties', | |
3107 | 'data': { 'typename': 'str'}, | |
3108 | 'returns': [ 'DevicePropertyInfo' ] } | |
3109 | ||
e1c37d0e | 3110 | ## |
5072f7b3 | 3111 | # @migrate: |
e1c37d0e LC |
3112 | # |
3113 | # Migrates the current running guest to another Virtual Machine. | |
3114 | # | |
3115 | # @uri: the Uniform Resource Identifier of the destination VM | |
3116 | # | |
1d8bda12 | 3117 | # @blk: do block migration (full disk copy) |
e1c37d0e | 3118 | # |
1d8bda12 | 3119 | # @inc: incremental disk copy migration |
e1c37d0e LC |
3120 | # |
3121 | # @detach: this argument exists only for compatibility reasons and | |
3122 | # is ignored by QEMU | |
3123 | # | |
3124 | # Returns: nothing on success | |
3125 | # | |
3126 | # Since: 0.14.0 | |
b3ac5a0d MAL |
3127 | # |
3128 | # Notes: | |
3129 | # | |
3130 | # 1. The 'query-migrate' command should be used to check migration's progress | |
3131 | # and final result (this information is provided by the 'status' member) | |
3132 | # | |
3133 | # 2. All boolean arguments default to false | |
3134 | # | |
3135 | # 3. The user Monitor's "detach" argument is invalid in QMP and should not | |
3136 | # be used | |
3137 | # | |
3138 | # Example: | |
3139 | # | |
3140 | # -> { "execute": "migrate", "arguments": { "uri": "tcp:0:4446" } } | |
3141 | # <- { "return": {} } | |
3142 | # | |
e1c37d0e LC |
3143 | ## |
3144 | { 'command': 'migrate', | |
3145 | 'data': {'uri': 'str', '*blk': 'bool', '*inc': 'bool', '*detach': 'bool' } } | |
33cf629a | 3146 | |
bf1ae1f4 | 3147 | ## |
5072f7b3 | 3148 | # @migrate-incoming: |
bf1ae1f4 DDAG |
3149 | # |
3150 | # Start an incoming migration, the qemu must have been started | |
3151 | # with -incoming defer | |
3152 | # | |
3153 | # @uri: The Uniform Resource Identifier identifying the source or | |
3154 | # address to listen on | |
3155 | # | |
3156 | # Returns: nothing on success | |
3157 | # | |
3158 | # Since: 2.3 | |
dbdbddb9 MAL |
3159 | # |
3160 | # Notes: | |
3161 | # | |
3162 | # 1. It's a bad idea to use a string for the uri, but it needs to stay | |
3163 | # compatible with -incoming and the format of the uri is already exposed | |
3164 | # above libvirt. | |
3165 | # | |
3166 | # 2. QEMU must be started with -incoming defer to allow migrate-incoming to | |
3167 | # be used. | |
3168 | # | |
3169 | # 3. The uri format is the same as for -incoming | |
3170 | # | |
3171 | # Example: | |
3172 | # | |
3173 | # -> { "execute": "migrate-incoming", | |
3174 | # "arguments": { "uri": "tcp::4446" } } | |
3175 | # <- { "return": {} } | |
3176 | # | |
bf1ae1f4 DDAG |
3177 | ## |
3178 | { 'command': 'migrate-incoming', 'data': {'uri': 'str' } } | |
3179 | ||
49687ace | 3180 | ## |
a7ae8355 SS |
3181 | # @xen-save-devices-state: |
3182 | # | |
3183 | # Save the state of all devices to file. The RAM and the block devices | |
3184 | # of the VM are not saved by this command. | |
3185 | # | |
3186 | # @filename: the file to save the state of the devices to as binary | |
3187 | # data. See xen-save-devices-state.txt for a description of the binary | |
3188 | # format. | |
3189 | # | |
3190 | # Returns: Nothing on success | |
a7ae8355 SS |
3191 | # |
3192 | # Since: 1.1 | |
2ea72beb MAL |
3193 | # |
3194 | # Example: | |
3195 | # | |
3196 | # -> { "execute": "xen-save-devices-state", | |
3197 | # "arguments": { "filename": "/tmp/save" } } | |
3198 | # <- { "return": {} } | |
3199 | # | |
a7ae8355 SS |
3200 | ## |
3201 | { 'command': 'xen-save-devices-state', 'data': {'filename': 'str'} } | |
a15fef21 | 3202 | |
39f42439 | 3203 | ## |
5072f7b3 | 3204 | # @xen-set-global-dirty-log: |
39f42439 AP |
3205 | # |
3206 | # Enable or disable the global dirty log mode. | |
3207 | # | |
3208 | # @enable: true to enable, false to disable. | |
3209 | # | |
3210 | # Returns: nothing | |
3211 | # | |
3212 | # Since: 1.3 | |
a4df6eff MAL |
3213 | # |
3214 | # Example: | |
3215 | # | |
3216 | # -> { "execute": "xen-set-global-dirty-log", | |
3217 | # "arguments": { "enable": true } } | |
3218 | # <- { "return": {} } | |
3219 | # | |
39f42439 AP |
3220 | ## |
3221 | { 'command': 'xen-set-global-dirty-log', 'data': { 'enable': 'bool' } } | |
3222 | ||
94cfd07f MAL |
3223 | ## |
3224 | # @device_add: | |
3225 | # | |
3226 | # @driver: the name of the new device's driver | |
3227 | # | |
1d8bda12 | 3228 | # @bus: the device's parent bus (device tree path) |
94cfd07f | 3229 | # |
1d8bda12 | 3230 | # @id: the device's ID, must be unique |
94cfd07f MAL |
3231 | # |
3232 | # Additional arguments depend on the type. | |
3233 | # | |
3234 | # Add a device. | |
3235 | # | |
3236 | # Notes: | |
3237 | # 1. For detailed information about this command, please refer to the | |
3238 | # 'docs/qdev-device-use.txt' file. | |
3239 | # | |
3240 | # 2. It's possible to list device properties by running QEMU with the | |
3241 | # "-device DEVICE,help" command-line argument, where DEVICE is the | |
3242 | # device's name | |
3243 | # | |
3244 | # Example: | |
3245 | # | |
3246 | # -> { "execute": "device_add", | |
3247 | # "arguments": { "driver": "e1000", "id": "net1", | |
3248 | # "bus": "pci.0", | |
3249 | # "mac": "52:54:00:12:34:56" } } | |
3250 | # <- { "return": {} } | |
3251 | # | |
e22da431 | 3252 | # TODO: This command effectively bypasses QAPI completely due to its |
94cfd07f MAL |
3253 | # "additional arguments" business. It shouldn't have been added to |
3254 | # the schema in this form. It should be qapified properly, or | |
3255 | # replaced by a properly qapified command. | |
3256 | # | |
3257 | # Since: 0.13 | |
3258 | ## | |
3259 | { 'command': 'device_add', | |
b780e9c3 | 3260 | 'data': {'driver': 'str', '*bus': 'str', '*id': 'str'}, |
94cfd07f MAL |
3261 | 'gen': false } # so we can get the additional arguments |
3262 | ||
a15fef21 LC |
3263 | ## |
3264 | # @device_del: | |
3265 | # | |
3266 | # Remove a device from a guest | |
3267 | # | |
e389c004 | 3268 | # @id: the device's ID or QOM path |
a15fef21 LC |
3269 | # |
3270 | # Returns: Nothing on success | |
3271 | # If @id is not a valid device, DeviceNotFound | |
a15fef21 LC |
3272 | # |
3273 | # Notes: When this command completes, the device may not be removed from the | |
3274 | # guest. Hot removal is an operation that requires guest cooperation. | |
3275 | # This command merely requests that the guest begin the hot removal | |
0402a5d6 MT |
3276 | # process. Completion of the device removal process is signaled with a |
3277 | # DEVICE_DELETED event. Guest reset will automatically complete removal | |
3278 | # for all devices. | |
a15fef21 LC |
3279 | # |
3280 | # Since: 0.14.0 | |
e389c004 MAL |
3281 | # |
3282 | # Example: | |
3283 | # | |
3284 | # -> { "execute": "device_del", | |
3285 | # "arguments": { "id": "net1" } } | |
3286 | # <- { "return": {} } | |
3287 | # | |
3288 | # -> { "execute": "device_del", | |
3289 | # "arguments": { "id": "/machine/peripheral-anon/device[0]" } } | |
3290 | # <- { "return": {} } | |
3291 | # | |
a15fef21 LC |
3292 | ## |
3293 | { 'command': 'device_del', 'data': {'id': 'str'} } | |
783e9b48 | 3294 | |
b53ccc30 QN |
3295 | ## |
3296 | # @DumpGuestMemoryFormat: | |
3297 | # | |
3298 | # An enumeration of guest-memory-dump's format. | |
3299 | # | |
3300 | # @elf: elf format | |
3301 | # | |
3302 | # @kdump-zlib: kdump-compressed format with zlib-compressed | |
3303 | # | |
3304 | # @kdump-lzo: kdump-compressed format with lzo-compressed | |
3305 | # | |
3306 | # @kdump-snappy: kdump-compressed format with snappy-compressed | |
3307 | # | |
3308 | # Since: 2.0 | |
3309 | ## | |
3310 | { 'enum': 'DumpGuestMemoryFormat', | |
3311 | 'data': [ 'elf', 'kdump-zlib', 'kdump-lzo', 'kdump-snappy' ] } | |
3312 | ||
783e9b48 | 3313 | ## |
5072f7b3 | 3314 | # @dump-guest-memory: |
783e9b48 WC |
3315 | # |
3316 | # Dump guest's memory to vmcore. It is a synchronous operation that can take | |
f1cd4830 | 3317 | # very long depending on the amount of guest memory. |
f5b0d93b LC |
3318 | # |
3319 | # @paging: if true, do paging to get guest's memory mapping. This allows | |
d691180e | 3320 | # using gdb to process the core file. |
f5b0d93b | 3321 | # |
d691180e LC |
3322 | # IMPORTANT: this option can make QEMU allocate several gigabytes |
3323 | # of RAM. This can happen for a large guest, or a | |
3324 | # malicious guest pretending to be large. | |
3325 | # | |
3326 | # Also, paging=true has the following limitations: | |
3327 | # | |
3328 | # 1. The guest may be in a catastrophic state or can have corrupted | |
3329 | # memory, which cannot be trusted | |
3330 | # 2. The guest can be in real-mode even if paging is enabled. For | |
3331 | # example, the guest uses ACPI to sleep, and ACPI sleep state | |
3332 | # goes in real-mode | |
f1cd4830 | 3333 | # 3. Currently only supported on i386 and x86_64. |
f5b0d93b | 3334 | # |
783e9b48 | 3335 | # @protocol: the filename or file descriptor of the vmcore. The supported |
d691180e | 3336 | # protocols are: |
f5b0d93b | 3337 | # |
d691180e LC |
3338 | # 1. file: the protocol starts with "file:", and the following |
3339 | # string is the file's path. | |
3340 | # 2. fd: the protocol starts with "fd:", and the following string | |
3341 | # is the fd's name. | |
f5b0d93b | 3342 | # |
1d8bda12 | 3343 | # @detach: if true, QMP will return immediately rather than |
39ba2ea6 PX |
3344 | # waiting for the dump to finish. The user can track progress |
3345 | # using "query-dump". (since 2.6). | |
228de9cf | 3346 | # |
1d8bda12 | 3347 | # @begin: if specified, the starting physical address. |
f5b0d93b | 3348 | # |
1d8bda12 | 3349 | # @length: if specified, the memory size, in bytes. If you don't |
d691180e LC |
3350 | # want to dump all guest's memory, please specify the start @begin |
3351 | # and @length | |
783e9b48 | 3352 | # |
1d8bda12 | 3353 | # @format: if specified, the format of guest memory dump. But non-elf |
b53ccc30 QN |
3354 | # format is conflict with paging and filter, ie. @paging, @begin and |
3355 | # @length is not allowed to be specified with non-elf @format at the | |
3356 | # same time (since 2.0) | |
3357 | # | |
58e4300a MAL |
3358 | # Note: All boolean arguments default to false |
3359 | # | |
783e9b48 | 3360 | # Returns: nothing on success |
783e9b48 WC |
3361 | # |
3362 | # Since: 1.2 | |
58e4300a MAL |
3363 | # |
3364 | # Example: | |
3365 | # | |
3366 | # -> { "execute": "dump-guest-memory", | |
3367 | # "arguments": { "protocol": "fd:dump" } } | |
3368 | # <- { "return": {} } | |
3369 | # | |
783e9b48 WC |
3370 | ## |
3371 | { 'command': 'dump-guest-memory', | |
228de9cf PX |
3372 | 'data': { 'paging': 'bool', 'protocol': 'str', '*detach': 'bool', |
3373 | '*begin': 'int', '*length': 'int', | |
3374 | '*format': 'DumpGuestMemoryFormat'} } | |
d691180e | 3375 | |
baf28f57 | 3376 | ## |
5072f7b3 | 3377 | # @DumpStatus: |
baf28f57 PX |
3378 | # |
3379 | # Describe the status of a long-running background guest memory dump. | |
3380 | # | |
3381 | # @none: no dump-guest-memory has started yet. | |
3382 | # | |
3383 | # @active: there is one dump running in background. | |
3384 | # | |
3385 | # @completed: the last dump has finished successfully. | |
3386 | # | |
3387 | # @failed: the last dump has failed. | |
3388 | # | |
5072f7b3 | 3389 | # Since: 2.6 |
baf28f57 PX |
3390 | ## |
3391 | { 'enum': 'DumpStatus', | |
3392 | 'data': [ 'none', 'active', 'completed', 'failed' ] } | |
3393 | ||
39ba2ea6 | 3394 | ## |
5072f7b3 | 3395 | # @DumpQueryResult: |
39ba2ea6 PX |
3396 | # |
3397 | # The result format for 'query-dump'. | |
3398 | # | |
3399 | # @status: enum of @DumpStatus, which shows current dump status | |
3400 | # | |
3401 | # @completed: bytes written in latest dump (uncompressed) | |
3402 | # | |
3403 | # @total: total bytes to be written in latest dump (uncompressed) | |
3404 | # | |
5072f7b3 | 3405 | # Since: 2.6 |
39ba2ea6 PX |
3406 | ## |
3407 | { 'struct': 'DumpQueryResult', | |
3408 | 'data': { 'status': 'DumpStatus', | |
3409 | 'completed': 'int', | |
3410 | 'total': 'int' } } | |
3411 | ||
3412 | ## | |
5072f7b3 | 3413 | # @query-dump: |
39ba2ea6 PX |
3414 | # |
3415 | # Query latest dump status. | |
3416 | # | |
3417 | # Returns: A @DumpStatus object showing the dump status. | |
3418 | # | |
3419 | # Since: 2.6 | |
926dce5c MAL |
3420 | # |
3421 | # Example: | |
3422 | # | |
3423 | # -> { "execute": "query-dump" } | |
3424 | # <- { "return": { "status": "active", "completed": 1024000, | |
3425 | # "total": 2048000 } } | |
3426 | # | |
39ba2ea6 PX |
3427 | ## |
3428 | { 'command': 'query-dump', 'returns': 'DumpQueryResult' } | |
3429 | ||
7d6dc7f3 QN |
3430 | ## |
3431 | # @DumpGuestMemoryCapability: | |
3432 | # | |
3433 | # A list of the available formats for dump-guest-memory | |
3434 | # | |
3435 | # Since: 2.0 | |
3436 | ## | |
895a2a80 | 3437 | { 'struct': 'DumpGuestMemoryCapability', |
7d6dc7f3 QN |
3438 | 'data': { |
3439 | 'formats': ['DumpGuestMemoryFormat'] } } | |
3440 | ||
3441 | ## | |
3442 | # @query-dump-guest-memory-capability: | |
3443 | # | |
3444 | # Returns the available formats for dump-guest-memory | |
3445 | # | |
3446 | # Returns: A @DumpGuestMemoryCapability object listing available formats for | |
3447 | # dump-guest-memory | |
3448 | # | |
3449 | # Since: 2.0 | |
2ccb9803 MAL |
3450 | # |
3451 | # Example: | |
3452 | # | |
3453 | # -> { "execute": "query-dump-guest-memory-capability" } | |
3454 | # <- { "return": { "formats": | |
3455 | # ["elf", "kdump-zlib", "kdump-lzo", "kdump-snappy"] } | |
3456 | # | |
7d6dc7f3 QN |
3457 | ## |
3458 | { 'command': 'query-dump-guest-memory-capability', | |
3459 | 'returns': 'DumpGuestMemoryCapability' } | |
d691180e | 3460 | |
7ee0c3e3 | 3461 | ## |
5072f7b3 | 3462 | # @dump-skeys: |
7ee0c3e3 JH |
3463 | # |
3464 | # Dump guest's storage keys | |
3465 | # | |
3466 | # @filename: the path to the file to dump to | |
3467 | # | |
3468 | # This command is only supported on s390 architecture. | |
3469 | # | |
3470 | # Since: 2.5 | |
ee332b51 MAL |
3471 | # |
3472 | # Example: | |
3473 | # | |
3474 | # -> { "execute": "dump-skeys", | |
3475 | # "arguments": { "filename": "/tmp/skeys" } } | |
3476 | # <- { "return": {} } | |
3477 | # | |
7ee0c3e3 JH |
3478 | ## |
3479 | { 'command': 'dump-skeys', | |
3480 | 'data': { 'filename': 'str' } } | |
3481 | ||
928059a3 LC |
3482 | ## |
3483 | # @netdev_add: | |
3484 | # | |
3485 | # Add a network backend. | |
3486 | # | |
3487 | # @type: the type of network backend. Current valid values are 'user', 'tap', | |
3488 | # 'vde', 'socket', 'dump' and 'bridge' | |
3489 | # | |
3490 | # @id: the name of the new network backend | |
3491 | # | |
b8a98326 | 3492 | # Additional arguments depend on the type. |
928059a3 | 3493 | # |
e22da431 | 3494 | # TODO: This command effectively bypasses QAPI completely due to its |
b8a98326 MA |
3495 | # "additional arguments" business. It shouldn't have been added to |
3496 | # the schema in this form. It should be qapified properly, or | |
3497 | # replaced by a properly qapified command. | |
928059a3 LC |
3498 | # |
3499 | # Since: 0.14.0 | |
3500 | # | |
3501 | # Returns: Nothing on success | |
3502 | # If @type is not a valid network backend, DeviceNotFound | |
aa72941b MAL |
3503 | # |
3504 | # Example: | |
3505 | # | |
3506 | # -> { "execute": "netdev_add", | |
3507 | # "arguments": { "type": "user", "id": "netdev1", | |
3508 | # "dnssearch": "example.org" } } | |
3509 | # <- { "return": {} } | |
3510 | # | |
928059a3 LC |
3511 | ## |
3512 | { 'command': 'netdev_add', | |
b8a98326 MA |
3513 | 'data': {'type': 'str', 'id': 'str'}, |
3514 | 'gen': false } # so we can get the additional arguments | |
5f964155 LC |
3515 | |
3516 | ## | |
3517 | # @netdev_del: | |
3518 | # | |
3519 | # Remove a network backend. | |
3520 | # | |
3521 | # @id: the name of the network backend to remove | |
3522 | # | |
3523 | # Returns: Nothing on success | |
3524 | # If @id is not a valid network backend, DeviceNotFound | |
3525 | # | |
3526 | # Since: 0.14.0 | |
d071f6be MAL |
3527 | # |
3528 | # Example: | |
3529 | # | |
3530 | # -> { "execute": "netdev_del", "arguments": { "id": "netdev1" } } | |
3531 | # <- { "return": {} } | |
3532 | # | |
5f964155 LC |
3533 | ## |
3534 | { 'command': 'netdev_del', 'data': {'id': 'str'} } | |
208c9d1b | 3535 | |
cff8b2c6 PB |
3536 | ## |
3537 | # @object-add: | |
3538 | # | |
3539 | # Create a QOM object. | |
3540 | # | |
3541 | # @qom-type: the class name for the object to be created | |
3542 | # | |
3543 | # @id: the name of the new object | |
3544 | # | |
1d8bda12 | 3545 | # @props: a dictionary of properties to be passed to the backend |
cff8b2c6 PB |
3546 | # |
3547 | # Returns: Nothing on success | |
3548 | # Error if @qom-type is not a valid class name | |
3549 | # | |
3550 | # Since: 2.0 | |
6517192b MAL |
3551 | # |
3552 | # Example: | |
3553 | # | |
3554 | # -> { "execute": "object-add", | |
3555 | # "arguments": { "qom-type": "rng-random", "id": "rng1", | |
3556 | # "props": { "filename": "/dev/hwrng" } } } | |
3557 | # <- { "return": {} } | |
3558 | # | |
cff8b2c6 PB |
3559 | ## |
3560 | { 'command': 'object-add', | |
6eb3937e | 3561 | 'data': {'qom-type': 'str', 'id': 'str', '*props': 'any'} } |
cff8b2c6 | 3562 | |
ab2d0531 PB |
3563 | ## |
3564 | # @object-del: | |
3565 | # | |
3566 | # Remove a QOM object. | |
3567 | # | |
3568 | # @id: the name of the QOM object to remove | |
3569 | # | |
3570 | # Returns: Nothing on success | |
3571 | # Error if @id is not a valid id for a QOM object | |
3572 | # | |
3573 | # Since: 2.0 | |
de0ba662 MAL |
3574 | # |
3575 | # Example: | |
3576 | # | |
3577 | # -> { "execute": "object-del", "arguments": { "id": "rng1" } } | |
3578 | # <- { "return": {} } | |
3579 | # | |
ab2d0531 PB |
3580 | ## |
3581 | { 'command': 'object-del', 'data': {'id': 'str'} } | |
3582 | ||
14aa0c2d | 3583 | ## |
5072f7b3 | 3584 | # @NetdevNoneOptions: |
14aa0c2d LE |
3585 | # |
3586 | # Use it alone to have zero network devices. | |
3587 | # | |
5072f7b3 | 3588 | # Since: 1.2 |
14aa0c2d | 3589 | ## |
895a2a80 | 3590 | { 'struct': 'NetdevNoneOptions', |
14aa0c2d LE |
3591 | 'data': { } } |
3592 | ||
3593 | ## | |
5072f7b3 | 3594 | # @NetLegacyNicOptions: |
14aa0c2d LE |
3595 | # |
3596 | # Create a new Network Interface Card. | |
3597 | # | |
1d8bda12 | 3598 | # @netdev: id of -netdev to connect to |
14aa0c2d | 3599 | # |
1d8bda12 | 3600 | # @macaddr: MAC address |
14aa0c2d | 3601 | # |
1d8bda12 | 3602 | # @model: device model (e1000, rtl8139, virtio etc.) |
14aa0c2d | 3603 | # |
1d8bda12 | 3604 | # @addr: PCI device address |
14aa0c2d | 3605 | # |
1d8bda12 | 3606 | # @vectors: number of MSI-x vectors, 0 to disable MSI-X |
14aa0c2d | 3607 | # |
5072f7b3 | 3608 | # Since: 1.2 |
14aa0c2d | 3609 | ## |
895a2a80 | 3610 | { 'struct': 'NetLegacyNicOptions', |
14aa0c2d LE |
3611 | 'data': { |
3612 | '*netdev': 'str', | |
3613 | '*macaddr': 'str', | |
3614 | '*model': 'str', | |
3615 | '*addr': 'str', | |
3616 | '*vectors': 'uint32' } } | |
3617 | ||
3618 | ## | |
5072f7b3 | 3619 | # @String: |
14aa0c2d LE |
3620 | # |
3621 | # A fat type wrapping 'str', to be embedded in lists. | |
3622 | # | |
5072f7b3 | 3623 | # Since: 1.2 |
14aa0c2d | 3624 | ## |
895a2a80 | 3625 | { 'struct': 'String', |
14aa0c2d LE |
3626 | 'data': { |
3627 | 'str': 'str' } } | |
3628 | ||
3629 | ## | |
5072f7b3 | 3630 | # @NetdevUserOptions: |
14aa0c2d LE |
3631 | # |
3632 | # Use the user mode network stack which requires no administrator privilege to | |
3633 | # run. | |
3634 | # | |
1d8bda12 | 3635 | # @hostname: client hostname reported by the builtin DHCP server |
14aa0c2d | 3636 | # |
1d8bda12 | 3637 | # @restrict: isolate the guest from the host |
14aa0c2d | 3638 | # |
1d8bda12 | 3639 | # @ipv4: whether to support IPv4, default true for enabled |
0b11c036 ST |
3640 | # (since 2.6) |
3641 | # | |
1d8bda12 | 3642 | # @ipv6: whether to support IPv6, default true for enabled |
0b11c036 ST |
3643 | # (since 2.6) |
3644 | # | |
1d8bda12 | 3645 | # @ip: legacy parameter, use net= instead |
14aa0c2d | 3646 | # |
1d8bda12 | 3647 | # @net: IP network address that the guest will see, in the |
d8eb3864 ST |
3648 | # form addr[/netmask] The netmask is optional, and can be |
3649 | # either in the form a.b.c.d or as a number of valid top-most | |
3650 | # bits. Default is 10.0.2.0/24. | |
14aa0c2d | 3651 | # |
1d8bda12 | 3652 | # @host: guest-visible address of the host |
14aa0c2d | 3653 | # |
1d8bda12 | 3654 | # @tftp: root directory of the built-in TFTP server |
14aa0c2d | 3655 | # |
1d8bda12 | 3656 | # @bootfile: BOOTP filename, for use with tftp= |
14aa0c2d | 3657 | # |
1d8bda12 | 3658 | # @dhcpstart: the first of the 16 IPs the built-in DHCP server can |
14aa0c2d LE |
3659 | # assign |
3660 | # | |
1d8bda12 | 3661 | # @dns: guest-visible address of the virtual nameserver |
14aa0c2d | 3662 | # |
1d8bda12 | 3663 | # @dnssearch: list of DNS suffixes to search, passed as DHCP option |
63d2960b KS |
3664 | # to the guest |
3665 | # | |
1d8bda12 | 3666 | # @ipv6-prefix: IPv6 network prefix (default is fec0::) (since |
d8eb3864 ST |
3667 | # 2.6). The network prefix is given in the usual |
3668 | # hexadecimal IPv6 address notation. | |
7aac531e | 3669 | # |
1d8bda12 | 3670 | # @ipv6-prefixlen: IPv6 network prefix length (default is 64) |
d8eb3864 | 3671 | # (since 2.6) |
7aac531e | 3672 | # |
1d8bda12 | 3673 | # @ipv6-host: guest-visible IPv6 address of the host (since 2.6) |
7aac531e | 3674 | # |
1d8bda12 | 3675 | # @ipv6-dns: guest-visible IPv6 address of the virtual |
d8eb3864 | 3676 | # nameserver (since 2.6) |
7aac531e | 3677 | # |
1d8bda12 | 3678 | # @smb: root directory of the built-in SMB server |
14aa0c2d | 3679 | # |
1d8bda12 | 3680 | # @smbserver: IP address of the built-in SMB server |
14aa0c2d | 3681 | # |
1d8bda12 | 3682 | # @hostfwd: redirect incoming TCP or UDP host connections to guest |
14aa0c2d LE |
3683 | # endpoints |
3684 | # | |
1d8bda12 | 3685 | # @guestfwd: forward guest TCP connections |
14aa0c2d | 3686 | # |
5072f7b3 | 3687 | # Since: 1.2 |
14aa0c2d | 3688 | ## |
895a2a80 | 3689 | { 'struct': 'NetdevUserOptions', |
14aa0c2d LE |
3690 | 'data': { |
3691 | '*hostname': 'str', | |
3692 | '*restrict': 'bool', | |
0b11c036 ST |
3693 | '*ipv4': 'bool', |
3694 | '*ipv6': 'bool', | |
14aa0c2d LE |
3695 | '*ip': 'str', |
3696 | '*net': 'str', | |
3697 | '*host': 'str', | |
3698 | '*tftp': 'str', | |
3699 | '*bootfile': 'str', | |
3700 | '*dhcpstart': 'str', | |
3701 | '*dns': 'str', | |
63d2960b | 3702 | '*dnssearch': ['String'], |
d8eb3864 ST |
3703 | '*ipv6-prefix': 'str', |
3704 | '*ipv6-prefixlen': 'int', | |
3705 | '*ipv6-host': 'str', | |
3706 | '*ipv6-dns': 'str', | |
14aa0c2d LE |
3707 | '*smb': 'str', |
3708 | '*smbserver': 'str', | |
3709 | '*hostfwd': ['String'], | |
3710 | '*guestfwd': ['String'] } } | |
3711 | ||
3712 | ## | |
5072f7b3 | 3713 | # @NetdevTapOptions: |
14aa0c2d LE |
3714 | # |
3715 | # Connect the host TAP network interface name to the VLAN. | |
3716 | # | |
1d8bda12 | 3717 | # @ifname: interface name |
14aa0c2d | 3718 | # |
1d8bda12 | 3719 | # @fd: file descriptor of an already opened tap |
14aa0c2d | 3720 | # |
1d8bda12 | 3721 | # @fds: multiple file descriptors of already opened multiqueue capable |
2ca81baa JW |
3722 | # tap |
3723 | # | |
1d8bda12 | 3724 | # @script: script to initialize the interface |
14aa0c2d | 3725 | # |
1d8bda12 | 3726 | # @downscript: script to shut down the interface |
14aa0c2d | 3727 | # |
1d8bda12 | 3728 | # @br: bridge name (since 2.8) |
584613ea | 3729 | # |
1d8bda12 | 3730 | # @helper: command to execute to configure bridge |
14aa0c2d | 3731 | # |
1d8bda12 | 3732 | # @sndbuf: send buffer limit. Understands [TGMKkb] suffixes. |
14aa0c2d | 3733 | # |
1d8bda12 | 3734 | # @vnet_hdr: enable the IFF_VNET_HDR flag on the tap interface |
14aa0c2d | 3735 | # |
1d8bda12 | 3736 | # @vhost: enable vhost-net network accelerator |
14aa0c2d | 3737 | # |
1d8bda12 | 3738 | # @vhostfd: file descriptor of an already opened vhost net device |
14aa0c2d | 3739 | # |
1d8bda12 | 3740 | # @vhostfds: file descriptors of multiple already opened vhost net |
2ca81baa JW |
3741 | # devices |
3742 | # | |
1d8bda12 | 3743 | # @vhostforce: vhost on for non-MSIX virtio guests |
14aa0c2d | 3744 | # |
1d8bda12 | 3745 | # @queues: number of queues to be created for multiqueue capable tap |
ec396014 | 3746 | # |
1d8bda12 | 3747 | # @poll-us: maximum number of microseconds that could |
69e87b32 JW |
3748 | # be spent on busy polling for tap (since 2.7) |
3749 | # | |
5072f7b3 | 3750 | # Since: 1.2 |
14aa0c2d | 3751 | ## |
895a2a80 | 3752 | { 'struct': 'NetdevTapOptions', |
14aa0c2d LE |
3753 | 'data': { |
3754 | '*ifname': 'str', | |
3755 | '*fd': 'str', | |
264986e2 | 3756 | '*fds': 'str', |
14aa0c2d LE |
3757 | '*script': 'str', |
3758 | '*downscript': 'str', | |
584613ea | 3759 | '*br': 'str', |
14aa0c2d LE |
3760 | '*helper': 'str', |
3761 | '*sndbuf': 'size', | |
3762 | '*vnet_hdr': 'bool', | |
3763 | '*vhost': 'bool', | |
3764 | '*vhostfd': 'str', | |
264986e2 JW |
3765 | '*vhostfds': 'str', |
3766 | '*vhostforce': 'bool', | |
69e87b32 JW |
3767 | '*queues': 'uint32', |
3768 | '*poll-us': 'uint32'} } | |
14aa0c2d LE |
3769 | |
3770 | ## | |
5072f7b3 | 3771 | # @NetdevSocketOptions: |
14aa0c2d LE |
3772 | # |
3773 | # Connect the VLAN to a remote VLAN in another QEMU virtual machine using a TCP | |
3774 | # socket connection. | |
3775 | # | |
1d8bda12 | 3776 | # @fd: file descriptor of an already opened socket |
14aa0c2d | 3777 | # |
1d8bda12 | 3778 | # @listen: port number, and optional hostname, to listen on |
14aa0c2d | 3779 | # |
1d8bda12 | 3780 | # @connect: port number, and optional hostname, to connect to |
14aa0c2d | 3781 | # |
1d8bda12 | 3782 | # @mcast: UDP multicast address and port number |
14aa0c2d | 3783 | # |
1d8bda12 | 3784 | # @localaddr: source address and port for multicast and udp packets |
14aa0c2d | 3785 | # |
1d8bda12 | 3786 | # @udp: UDP unicast address and port number |
14aa0c2d | 3787 | # |
5072f7b3 | 3788 | # Since: 1.2 |
14aa0c2d | 3789 | ## |
895a2a80 | 3790 | { 'struct': 'NetdevSocketOptions', |
14aa0c2d LE |
3791 | 'data': { |
3792 | '*fd': 'str', | |
3793 | '*listen': 'str', | |
3794 | '*connect': 'str', | |
3795 | '*mcast': 'str', | |
3796 | '*localaddr': 'str', | |
3797 | '*udp': 'str' } } | |
3798 | ||
3fb69aa1 | 3799 | ## |
5072f7b3 | 3800 | # @NetdevL2TPv3Options: |
3fb69aa1 AI |
3801 | # |
3802 | # Connect the VLAN to Ethernet over L2TPv3 Static tunnel | |
3803 | # | |
3804 | # @src: source address | |
3805 | # | |
3806 | # @dst: destination address | |
3807 | # | |
1d8bda12 | 3808 | # @srcport: source port - mandatory for udp, optional for ip |
3fb69aa1 | 3809 | # |
1d8bda12 | 3810 | # @dstport: destination port - mandatory for udp, optional for ip |
3fb69aa1 | 3811 | # |
1d8bda12 | 3812 | # @ipv6: force the use of ipv6 |
3fb69aa1 | 3813 | # |
1d8bda12 | 3814 | # @udp: use the udp version of l2tpv3 encapsulation |
3fb69aa1 | 3815 | # |
1d8bda12 | 3816 | # @cookie64: use 64 bit coookies |
3fb69aa1 | 3817 | # |
1d8bda12 | 3818 | # @counter: have sequence counter |
3fb69aa1 | 3819 | # |
1d8bda12 | 3820 | # @pincounter: pin sequence counter to zero - |
3fb69aa1 AI |
3821 | # workaround for buggy implementations or |
3822 | # networks with packet reorder | |
3823 | # | |
1d8bda12 | 3824 | # @txcookie: 32 or 64 bit transmit cookie |
3fb69aa1 | 3825 | # |
1d8bda12 | 3826 | # @rxcookie: 32 or 64 bit receive cookie |
3fb69aa1 AI |
3827 | # |
3828 | # @txsession: 32 bit transmit session | |
3829 | # | |
1d8bda12 | 3830 | # @rxsession: 32 bit receive session - if not specified |
3fb69aa1 AI |
3831 | # set to the same value as transmit |
3832 | # | |
1d8bda12 | 3833 | # @offset: additional offset - allows the insertion of |
3fb69aa1 AI |
3834 | # additional application-specific data before the packet payload |
3835 | # | |
5072f7b3 | 3836 | # Since: 2.1 |
3fb69aa1 | 3837 | ## |
895a2a80 | 3838 | { 'struct': 'NetdevL2TPv3Options', |
3fb69aa1 AI |
3839 | 'data': { |
3840 | 'src': 'str', | |
3841 | 'dst': 'str', | |
3842 | '*srcport': 'str', | |
3843 | '*dstport': 'str', | |
3844 | '*ipv6': 'bool', | |
3845 | '*udp': 'bool', | |
3846 | '*cookie64': 'bool', | |
3847 | '*counter': 'bool', | |
3848 | '*pincounter': 'bool', | |
3849 | '*txcookie': 'uint64', | |
3850 | '*rxcookie': 'uint64', | |
3851 | 'txsession': 'uint32', | |
3852 | '*rxsession': 'uint32', | |
3853 | '*offset': 'uint32' } } | |
3854 | ||
14aa0c2d | 3855 | ## |
5072f7b3 | 3856 | # @NetdevVdeOptions: |
14aa0c2d LE |
3857 | # |
3858 | # Connect the VLAN to a vde switch running on the host. | |
3859 | # | |
1d8bda12 | 3860 | # @sock: socket path |
14aa0c2d | 3861 | # |
1d8bda12 | 3862 | # @port: port number |
14aa0c2d | 3863 | # |
1d8bda12 | 3864 | # @group: group owner of socket |
14aa0c2d | 3865 | # |
1d8bda12 | 3866 | # @mode: permissions for socket |
14aa0c2d | 3867 | # |
5072f7b3 | 3868 | # Since: 1.2 |
14aa0c2d | 3869 | ## |
895a2a80 | 3870 | { 'struct': 'NetdevVdeOptions', |
14aa0c2d LE |
3871 | 'data': { |
3872 | '*sock': 'str', | |
3873 | '*port': 'uint16', | |
3874 | '*group': 'str', | |
3875 | '*mode': 'uint16' } } | |
3876 | ||
3877 | ## | |
5072f7b3 | 3878 | # @NetdevDumpOptions: |
14aa0c2d LE |
3879 | # |
3880 | # Dump VLAN network traffic to a file. | |
3881 | # | |
1d8bda12 | 3882 | # @len: per-packet size limit (64k default). Understands [TGMKkb] |
14aa0c2d LE |
3883 | # suffixes. |
3884 | # | |
1d8bda12 | 3885 | # @file: dump file path (default is qemu-vlan0.pcap) |
14aa0c2d | 3886 | # |
5072f7b3 | 3887 | # Since: 1.2 |
14aa0c2d | 3888 | ## |
895a2a80 | 3889 | { 'struct': 'NetdevDumpOptions', |
14aa0c2d LE |
3890 | 'data': { |
3891 | '*len': 'size', | |
3892 | '*file': 'str' } } | |
3893 | ||
3894 | ## | |
5072f7b3 | 3895 | # @NetdevBridgeOptions: |
14aa0c2d LE |
3896 | # |
3897 | # Connect a host TAP network interface to a host bridge device. | |
3898 | # | |
1d8bda12 | 3899 | # @br: bridge name |
14aa0c2d | 3900 | # |
1d8bda12 | 3901 | # @helper: command to execute to configure bridge |
14aa0c2d | 3902 | # |
5072f7b3 | 3903 | # Since: 1.2 |
14aa0c2d | 3904 | ## |
895a2a80 | 3905 | { 'struct': 'NetdevBridgeOptions', |
14aa0c2d LE |
3906 | 'data': { |
3907 | '*br': 'str', | |
3908 | '*helper': 'str' } } | |
3909 | ||
f6c874e3 | 3910 | ## |
5072f7b3 | 3911 | # @NetdevHubPortOptions: |
f6c874e3 SH |
3912 | # |
3913 | # Connect two or more net clients through a software hub. | |
3914 | # | |
3915 | # @hubid: hub identifier number | |
3916 | # | |
5072f7b3 | 3917 | # Since: 1.2 |
f6c874e3 | 3918 | ## |
895a2a80 | 3919 | { 'struct': 'NetdevHubPortOptions', |
f6c874e3 SH |
3920 | 'data': { |
3921 | 'hubid': 'int32' } } | |
3922 | ||
58952137 | 3923 | ## |
5072f7b3 | 3924 | # @NetdevNetmapOptions: |
58952137 VM |
3925 | # |
3926 | # Connect a client to a netmap-enabled NIC or to a VALE switch port | |
3927 | # | |
3928 | # @ifname: Either the name of an existing network interface supported by | |
3929 | # netmap, or the name of a VALE port (created on the fly). | |
3930 | # A VALE port name is in the form 'valeXXX:YYY', where XXX and | |
3931 | # YYY are non-negative integers. XXX identifies a switch and | |
3932 | # YYY identifies a port of the switch. VALE ports having the | |
3933 | # same XXX are therefore connected to the same switch. | |
3934 | # | |
1d8bda12 | 3935 | # @devname: path of the netmap device (default: '/dev/netmap'). |
58952137 | 3936 | # |
5072f7b3 | 3937 | # Since: 2.0 |
58952137 | 3938 | ## |
895a2a80 | 3939 | { 'struct': 'NetdevNetmapOptions', |
58952137 VM |
3940 | 'data': { |
3941 | 'ifname': 'str', | |
3942 | '*devname': 'str' } } | |
3943 | ||
03ce5744 | 3944 | ## |
5072f7b3 | 3945 | # @NetdevVhostUserOptions: |
03ce5744 NN |
3946 | # |
3947 | # Vhost-user network backend | |
3948 | # | |
3949 | # @chardev: name of a unix socket chardev | |
3950 | # | |
1d8bda12 | 3951 | # @vhostforce: vhost on for non-MSIX virtio guests (default: false). |
03ce5744 | 3952 | # |
1d8bda12 | 3953 | # @queues: number of queues to be created for multiqueue vhost-user |
b931bfbf CO |
3954 | # (default: 1) (Since 2.5) |
3955 | # | |
5072f7b3 | 3956 | # Since: 2.1 |
03ce5744 | 3957 | ## |
895a2a80 | 3958 | { 'struct': 'NetdevVhostUserOptions', |
03ce5744 NN |
3959 | 'data': { |
3960 | 'chardev': 'str', | |
b931bfbf CO |
3961 | '*vhostforce': 'bool', |
3962 | '*queues': 'int' } } | |
03ce5744 | 3963 | |
14aa0c2d | 3964 | ## |
5072f7b3 | 3965 | # @NetClientDriver: |
14aa0c2d | 3966 | # |
f394b2e2 EB |
3967 | # Available netdev drivers. |
3968 | # | |
5072f7b3 | 3969 | # Since: 2.7 |
f394b2e2 EB |
3970 | ## |
3971 | { 'enum': 'NetClientDriver', | |
3972 | 'data': [ 'none', 'nic', 'user', 'tap', 'l2tpv3', 'socket', 'vde', 'dump', | |
3973 | 'bridge', 'hubport', 'netmap', 'vhost-user' ] } | |
3974 | ||
3975 | ## | |
5072f7b3 | 3976 | # @Netdev: |
f394b2e2 EB |
3977 | # |
3978 | # Captures the configuration of a network device. | |
3979 | # | |
3980 | # @id: identifier for monitor commands. | |
3981 | # | |
3982 | # @type: Specify the driver used for interpreting remaining arguments. | |
14aa0c2d | 3983 | # |
5072f7b3 | 3984 | # Since: 1.2 |
3fb69aa1 AI |
3985 | # |
3986 | # 'l2tpv3' - since 2.1 | |
14aa0c2d | 3987 | ## |
f394b2e2 EB |
3988 | { 'union': 'Netdev', |
3989 | 'base': { 'id': 'str', 'type': 'NetClientDriver' }, | |
3990 | 'discriminator': 'type', | |
14aa0c2d | 3991 | 'data': { |
f6c874e3 SH |
3992 | 'none': 'NetdevNoneOptions', |
3993 | 'nic': 'NetLegacyNicOptions', | |
3994 | 'user': 'NetdevUserOptions', | |
3995 | 'tap': 'NetdevTapOptions', | |
3fb69aa1 | 3996 | 'l2tpv3': 'NetdevL2TPv3Options', |
f6c874e3 SH |
3997 | 'socket': 'NetdevSocketOptions', |
3998 | 'vde': 'NetdevVdeOptions', | |
3999 | 'dump': 'NetdevDumpOptions', | |
4000 | 'bridge': 'NetdevBridgeOptions', | |
58952137 | 4001 | 'hubport': 'NetdevHubPortOptions', |
03ce5744 NN |
4002 | 'netmap': 'NetdevNetmapOptions', |
4003 | 'vhost-user': 'NetdevVhostUserOptions' } } | |
14aa0c2d LE |
4004 | |
4005 | ## | |
5072f7b3 | 4006 | # @NetLegacy: |
14aa0c2d LE |
4007 | # |
4008 | # Captures the configuration of a network device; legacy. | |
4009 | # | |
1d8bda12 | 4010 | # @vlan: vlan number |
14aa0c2d | 4011 | # |
1d8bda12 | 4012 | # @id: identifier for monitor commands |
14aa0c2d | 4013 | # |
1d8bda12 | 4014 | # @name: identifier for monitor commands, ignored if @id is present |
14aa0c2d LE |
4015 | # |
4016 | # @opts: device type specific properties (legacy) | |
4017 | # | |
5072f7b3 | 4018 | # Since: 1.2 |
14aa0c2d | 4019 | ## |
895a2a80 | 4020 | { 'struct': 'NetLegacy', |
14aa0c2d LE |
4021 | 'data': { |
4022 | '*vlan': 'int32', | |
4023 | '*id': 'str', | |
4024 | '*name': 'str', | |
f394b2e2 | 4025 | 'opts': 'NetLegacyOptions' } } |
14aa0c2d | 4026 | |
d3be4b57 MA |
4027 | ## |
4028 | # @NetLegacyOptionsType: | |
4029 | # | |
4030 | # Since: 1.2 | |
4031 | ## | |
4032 | { 'enum': 'NetLegacyOptionsType', | |
4033 | 'data': ['none', 'nic', 'user', 'tap', 'l2tpv3', 'socket', 'vde', | |
4034 | 'dump', 'bridge', 'netmap', 'vhost-user'] } | |
4035 | ||
14aa0c2d | 4036 | ## |
5072f7b3 | 4037 | # @NetLegacyOptions: |
14aa0c2d | 4038 | # |
f394b2e2 | 4039 | # Like Netdev, but for use only by the legacy command line options |
14aa0c2d | 4040 | # |
5072f7b3 | 4041 | # Since: 1.2 |
14aa0c2d | 4042 | ## |
f394b2e2 | 4043 | { 'union': 'NetLegacyOptions', |
d3be4b57 MA |
4044 | 'base': { 'type': 'NetLegacyOptionsType' }, |
4045 | 'discriminator': 'type', | |
14aa0c2d | 4046 | 'data': { |
f394b2e2 EB |
4047 | 'none': 'NetdevNoneOptions', |
4048 | 'nic': 'NetLegacyNicOptions', | |
4049 | 'user': 'NetdevUserOptions', | |
4050 | 'tap': 'NetdevTapOptions', | |
4051 | 'l2tpv3': 'NetdevL2TPv3Options', | |
4052 | 'socket': 'NetdevSocketOptions', | |
4053 | 'vde': 'NetdevVdeOptions', | |
4054 | 'dump': 'NetdevDumpOptions', | |
4055 | 'bridge': 'NetdevBridgeOptions', | |
4056 | 'netmap': 'NetdevNetmapOptions', | |
4057 | 'vhost-user': 'NetdevVhostUserOptions' } } | |
14aa0c2d | 4058 | |
fdccce45 | 4059 | ## |
5072f7b3 | 4060 | # @NetFilterDirection: |
fdccce45 YH |
4061 | # |
4062 | # Indicates whether a netfilter is attached to a netdev's transmit queue or | |
4063 | # receive queue or both. | |
4064 | # | |
4065 | # @all: the filter is attached both to the receive and the transmit | |
4066 | # queue of the netdev (default). | |
4067 | # | |
4068 | # @rx: the filter is attached to the receive queue of the netdev, | |
4069 | # where it will receive packets sent to the netdev. | |
4070 | # | |
4071 | # @tx: the filter is attached to the transmit queue of the netdev, | |
4072 | # where it will receive packets sent by the netdev. | |
4073 | # | |
5072f7b3 | 4074 | # Since: 2.5 |
fdccce45 YH |
4075 | ## |
4076 | { 'enum': 'NetFilterDirection', | |
4077 | 'data': [ 'all', 'rx', 'tx' ] } | |
4078 | ||
5be8c759 | 4079 | ## |
eb87203b | 4080 | # @InetSocketAddressBase: |
5be8c759 PB |
4081 | # |
4082 | # @host: host part of the address | |
eb87203b MA |
4083 | # @port: port part of the address |
4084 | ## | |
4085 | { 'struct': 'InetSocketAddressBase', | |
4086 | 'data': { | |
4087 | 'host': 'str', | |
4088 | 'port': 'str' } } | |
4089 | ||
4090 | ## | |
4091 | # @InetSocketAddress: | |
5be8c759 | 4092 | # |
eb87203b | 4093 | # Captures a socket address or address range in the Internet namespace. |
5be8c759 | 4094 | # |
1d8bda12 | 4095 | # @numeric: true if the host/port are guaranteed to be numeric, |
6979a813 DB |
4096 | # false if name resolution should be attempted. Defaults to false. |
4097 | # (Since 2.9) | |
4098 | # | |
eb87203b MA |
4099 | # @to: If present, this is range of possible addresses, with port |
4100 | # between @port and @to. | |
5be8c759 PB |
4101 | # |
4102 | # @ipv4: whether to accept IPv4 addresses, default try both IPv4 and IPv6 | |
5be8c759 PB |
4103 | # |
4104 | # @ipv6: whether to accept IPv6 addresses, default try both IPv4 and IPv6 | |
5be8c759 | 4105 | # |
5072f7b3 | 4106 | # Since: 1.3 |
5be8c759 | 4107 | ## |
895a2a80 | 4108 | { 'struct': 'InetSocketAddress', |
eb87203b | 4109 | 'base': 'InetSocketAddressBase', |
5be8c759 | 4110 | 'data': { |
6979a813 | 4111 | '*numeric': 'bool', |
5be8c759 PB |
4112 | '*to': 'uint16', |
4113 | '*ipv4': 'bool', | |
4114 | '*ipv6': 'bool' } } | |
4115 | ||
4116 | ## | |
5072f7b3 | 4117 | # @UnixSocketAddress: |
5be8c759 PB |
4118 | # |
4119 | # Captures a socket address in the local ("Unix socket") namespace. | |
4120 | # | |
4121 | # @path: filesystem path to use | |
4122 | # | |
5072f7b3 | 4123 | # Since: 1.3 |
5be8c759 | 4124 | ## |
895a2a80 | 4125 | { 'struct': 'UnixSocketAddress', |
5be8c759 PB |
4126 | 'data': { |
4127 | 'path': 'str' } } | |
4128 | ||
6a02c806 | 4129 | ## |
5072f7b3 | 4130 | # @VsockSocketAddress: |
6a02c806 SH |
4131 | # |
4132 | # Captures a socket address in the vsock namespace. | |
4133 | # | |
4134 | # @cid: unique host identifier | |
4135 | # @port: port | |
4136 | # | |
5072f7b3 | 4137 | # Note: string types are used to allow for possible future hostname or |
6a02c806 SH |
4138 | # service resolution support. |
4139 | # | |
5072f7b3 | 4140 | # Since: 2.8 |
6a02c806 SH |
4141 | ## |
4142 | { 'struct': 'VsockSocketAddress', | |
4143 | 'data': { | |
4144 | 'cid': 'str', | |
4145 | 'port': 'str' } } | |
4146 | ||
5be8c759 | 4147 | ## |
dfd100f2 | 4148 | # @SocketAddressLegacy: |
5be8c759 PB |
4149 | # |
4150 | # Captures the address of a socket, which could also be a named file descriptor | |
4151 | # | |
bd269ebc MA |
4152 | # Note: This type is deprecated in favor of SocketAddress. The |
4153 | # difference between SocketAddressLegacy and SocketAddress is that the | |
4154 | # latter is a flat union rather than a simple union. Flat is nicer | |
4155 | # because it avoids nesting on the wire, i.e. that form has fewer {}. | |
4156 | ||
dfd100f2 | 4157 | # |
5072f7b3 | 4158 | # Since: 1.3 |
5be8c759 | 4159 | ## |
dfd100f2 | 4160 | { 'union': 'SocketAddressLegacy', |
5be8c759 PB |
4161 | 'data': { |
4162 | 'inet': 'InetSocketAddress', | |
4163 | 'unix': 'UnixSocketAddress', | |
6a02c806 | 4164 | 'vsock': 'VsockSocketAddress', |
5be8c759 PB |
4165 | 'fd': 'String' } } |
4166 | ||
2b733709 | 4167 | ## |
62cf396b | 4168 | # @SocketAddressType: |
2b733709 | 4169 | # |
62cf396b | 4170 | # Available SocketAddress types |
2b733709 | 4171 | # |
c5f1ae3a | 4172 | # @inet: Internet address |
2b733709 MA |
4173 | # |
4174 | # @unix: Unix domain socket | |
4175 | # | |
4176 | # Since: 2.9 | |
4177 | ## | |
62cf396b | 4178 | { 'enum': 'SocketAddressType', |
8bc0673f | 4179 | 'data': [ 'inet', 'unix', 'vsock', 'fd' ] } |
2b733709 MA |
4180 | |
4181 | ## | |
62cf396b | 4182 | # @SocketAddress: |
2b733709 | 4183 | # |
bd269ebc MA |
4184 | # Captures the address of a socket, which could also be a named file |
4185 | # descriptor | |
2b733709 MA |
4186 | # |
4187 | # @type: Transport type | |
4188 | # | |
2b733709 MA |
4189 | # Since: 2.9 |
4190 | ## | |
62cf396b MA |
4191 | { 'union': 'SocketAddress', |
4192 | 'base': { 'type': 'SocketAddressType' }, | |
2b733709 | 4193 | 'discriminator': 'type', |
8bc0673f MA |
4194 | 'data': { 'inet': 'InetSocketAddress', |
4195 | 'unix': 'UnixSocketAddress', | |
4196 | 'vsock': 'VsockSocketAddress', | |
4197 | 'fd': 'String' } } | |
2b733709 | 4198 | |
208c9d1b CB |
4199 | ## |
4200 | # @getfd: | |
4201 | # | |
4202 | # Receive a file descriptor via SCM rights and assign it a name | |
4203 | # | |
4204 | # @fdname: file descriptor name | |
4205 | # | |
4206 | # Returns: Nothing on success | |
208c9d1b CB |
4207 | # |
4208 | # Since: 0.14.0 | |
4209 | # | |
4210 | # Notes: If @fdname already exists, the file descriptor assigned to | |
4211 | # it will be closed and replaced by the received file | |
4212 | # descriptor. | |
179bf59a | 4213 | # |
208c9d1b CB |
4214 | # The 'closefd' command can be used to explicitly close the |
4215 | # file descriptor when it is no longer needed. | |
179bf59a MAL |
4216 | # |
4217 | # Example: | |
4218 | # | |
4219 | # -> { "execute": "getfd", "arguments": { "fdname": "fd1" } } | |
4220 | # <- { "return": {} } | |
4221 | # | |
208c9d1b CB |
4222 | ## |
4223 | { 'command': 'getfd', 'data': {'fdname': 'str'} } | |
4224 | ||
4225 | ## | |
4226 | # @closefd: | |
4227 | # | |
4228 | # Close a file descriptor previously passed via SCM rights | |
4229 | # | |
4230 | # @fdname: file descriptor name | |
4231 | # | |
4232 | # Returns: Nothing on success | |
208c9d1b CB |
4233 | # |
4234 | # Since: 0.14.0 | |
f5ad8e87 MAL |
4235 | # |
4236 | # Example: | |
4237 | # | |
4238 | # -> { "execute": "closefd", "arguments": { "fdname": "fd1" } } | |
4239 | # <- { "return": {} } | |
4240 | # | |
208c9d1b CB |
4241 | ## |
4242 | { 'command': 'closefd', 'data': {'fdname': 'str'} } | |
01d3c80d AL |
4243 | |
4244 | ## | |
4245 | # @MachineInfo: | |
4246 | # | |
4247 | # Information describing a machine. | |
4248 | # | |
4249 | # @name: the name of the machine | |
4250 | # | |
1d8bda12 | 4251 | # @alias: an alias for the machine name |
01d3c80d | 4252 | # |
1d8bda12 | 4253 | # @is-default: whether the machine is default |
01d3c80d | 4254 | # |
c72e7688 MN |
4255 | # @cpu-max: maximum number of CPUs supported by the machine type |
4256 | # (since 1.5.0) | |
4257 | # | |
62c9467d PK |
4258 | # @hotpluggable-cpus: cpu hotplug via -device is supported (since 2.7.0) |
4259 | # | |
01d3c80d AL |
4260 | # Since: 1.2.0 |
4261 | ## | |
895a2a80 | 4262 | { 'struct': 'MachineInfo', |
01d3c80d | 4263 | 'data': { 'name': 'str', '*alias': 'str', |
62c9467d PK |
4264 | '*is-default': 'bool', 'cpu-max': 'int', |
4265 | 'hotpluggable-cpus': 'bool'} } | |
01d3c80d AL |
4266 | |
4267 | ## | |
4268 | # @query-machines: | |
4269 | # | |
4270 | # Return a list of supported machines | |
4271 | # | |
4272 | # Returns: a list of MachineInfo | |
4273 | # | |
4274 | # Since: 1.2.0 | |
4275 | ## | |
4276 | { 'command': 'query-machines', 'returns': ['MachineInfo'] } | |
e4e31c63 AL |
4277 | |
4278 | ## | |
4279 | # @CpuDefinitionInfo: | |
4280 | # | |
4281 | # Virtual CPU definition. | |
4282 | # | |
4283 | # @name: the name of the CPU definition | |
4284 | # | |
1d8bda12 | 4285 | # @migration-safe: whether a CPU definition can be safely used for |
fc4b84b1 DH |
4286 | # migration in combination with a QEMU compatibility machine |
4287 | # when migrating between different QMU versions and between | |
4288 | # hosts with different sets of (hardware or software) | |
4289 | # capabilities. If not provided, information is not available | |
4290 | # and callers should not assume the CPU definition to be | |
4291 | # migration-safe. (since 2.8) | |
4292 | # | |
4293 | # @static: whether a CPU definition is static and will not change depending on | |
4294 | # QEMU version, machine type, machine options and accelerator options. | |
4295 | # A static model is always migration-safe. (since 2.8) | |
4296 | # | |
1d8bda12 | 4297 | # @unavailable-features: List of properties that prevent |
9504e710 EH |
4298 | # the CPU model from running in the current |
4299 | # host. (since 2.8) | |
8ed877b7 EH |
4300 | # @typename: Type name that can be used as argument to @device-list-properties, |
4301 | # to introspect properties configurable using -cpu or -global. | |
4302 | # (since 2.9) | |
9504e710 EH |
4303 | # |
4304 | # @unavailable-features is a list of QOM property names that | |
4305 | # represent CPU model attributes that prevent the CPU from running. | |
4306 | # If the QOM property is read-only, that means there's no known | |
4307 | # way to make the CPU model run in the current host. Implementations | |
4308 | # that choose not to provide specific information return the | |
4309 | # property name "type". | |
4310 | # If the property is read-write, it means that it MAY be possible | |
4311 | # to run the CPU model in the current host if that property is | |
4312 | # changed. Management software can use it as hints to suggest or | |
4313 | # choose an alternative for the user, or just to generate meaningful | |
4314 | # error messages explaining why the CPU model can't be used. | |
4315 | # If @unavailable-features is an empty list, the CPU model is | |
4316 | # runnable using the current host and machine-type. | |
4317 | # If @unavailable-features is not present, runnability | |
4318 | # information for the CPU is not available. | |
4319 | # | |
e4e31c63 AL |
4320 | # Since: 1.2.0 |
4321 | ## | |
895a2a80 | 4322 | { 'struct': 'CpuDefinitionInfo', |
9504e710 | 4323 | 'data': { 'name': 'str', '*migration-safe': 'bool', 'static': 'bool', |
8ed877b7 | 4324 | '*unavailable-features': [ 'str' ], 'typename': 'str' } } |
e4e31c63 AL |
4325 | |
4326 | ## | |
4327 | # @query-cpu-definitions: | |
4328 | # | |
4329 | # Return a list of supported virtual CPU definitions | |
4330 | # | |
4331 | # Returns: a list of CpuDefInfo | |
4332 | # | |
4333 | # Since: 1.2.0 | |
4334 | ## | |
4335 | { 'command': 'query-cpu-definitions', 'returns': ['CpuDefinitionInfo'] } | |
ba1c048a | 4336 | |
e09484ef DH |
4337 | ## |
4338 | # @CpuModelInfo: | |
4339 | # | |
4340 | # Virtual CPU model. | |
4341 | # | |
4342 | # A CPU model consists of the name of a CPU definition, to which | |
4343 | # delta changes are applied (e.g. features added/removed). Most magic values | |
4344 | # that an architecture might require should be hidden behind the name. | |
4345 | # However, if required, architectures can expose relevant properties. | |
4346 | # | |
4347 | # @name: the name of the CPU definition the model is based on | |
1d8bda12 | 4348 | # @props: a dictionary of QOM properties to be applied |
e09484ef DH |
4349 | # |
4350 | # Since: 2.8.0 | |
4351 | ## | |
4352 | { 'struct': 'CpuModelInfo', | |
4353 | 'data': { 'name': 'str', | |
4354 | '*props': 'any' } } | |
4355 | ||
4356 | ## | |
5072f7b3 | 4357 | # @CpuModelExpansionType: |
e09484ef DH |
4358 | # |
4359 | # An enumeration of CPU model expansion types. | |
4360 | # | |
4361 | # @static: Expand to a static CPU model, a combination of a static base | |
4362 | # model name and property delta changes. As the static base model will | |
4363 | # never change, the expanded CPU model will be the same, independant of | |
4364 | # independent of QEMU version, machine type, machine options, and | |
4365 | # accelerator options. Therefore, the resulting model can be used by | |
4366 | # tooling without having to specify a compatibility machine - e.g. when | |
4367 | # displaying the "host" model. static CPU models are migration-safe. | |
4368 | # | |
4369 | # @full: Expand all properties. The produced model is not guaranteed to be | |
4370 | # migration-safe, but allows tooling to get an insight and work with | |
4371 | # model details. | |
4372 | # | |
a357a65b EH |
4373 | # Note: When a non-migration-safe CPU model is expanded in static mode, some |
4374 | # features enabled by the CPU model may be omitted, because they can't be | |
4375 | # implemented by a static CPU model definition (e.g. cache info passthrough and | |
4376 | # PMU passthrough in x86). If you need an accurate representation of the | |
4377 | # features enabled by a non-migration-safe CPU model, use @full. If you need a | |
4378 | # static representation that will keep ABI compatibility even when changing QEMU | |
4379 | # version or machine-type, use @static (but keep in mind that some features may | |
4380 | # be omitted). | |
4381 | # | |
e09484ef DH |
4382 | # Since: 2.8.0 |
4383 | ## | |
4384 | { 'enum': 'CpuModelExpansionType', | |
4385 | 'data': [ 'static', 'full' ] } | |
4386 | ||
4387 | ||
4388 | ## | |
5072f7b3 | 4389 | # @CpuModelExpansionInfo: |
e09484ef DH |
4390 | # |
4391 | # The result of a cpu model expansion. | |
4392 | # | |
4393 | # @model: the expanded CpuModelInfo. | |
4394 | # | |
4395 | # Since: 2.8.0 | |
4396 | ## | |
4397 | { 'struct': 'CpuModelExpansionInfo', | |
4398 | 'data': { 'model': 'CpuModelInfo' } } | |
4399 | ||
4400 | ||
4401 | ## | |
4402 | # @query-cpu-model-expansion: | |
4403 | # | |
4404 | # Expands a given CPU model (or a combination of CPU model + additional options) | |
4405 | # to different granularities, allowing tooling to get an understanding what a | |
4406 | # specific CPU model looks like in QEMU under a certain configuration. | |
4407 | # | |
4408 | # This interface can be used to query the "host" CPU model. | |
4409 | # | |
4410 | # The data returned by this command may be affected by: | |
4411 | # | |
4412 | # * QEMU version: CPU models may look different depending on the QEMU version. | |
4413 | # (Except for CPU models reported as "static" in query-cpu-definitions.) | |
4414 | # * machine-type: CPU model may look different depending on the machine-type. | |
4415 | # (Except for CPU models reported as "static" in query-cpu-definitions.) | |
4416 | # * machine options (including accelerator): in some architectures, CPU models | |
4417 | # may look different depending on machine and accelerator options. (Except for | |
4418 | # CPU models reported as "static" in query-cpu-definitions.) | |
4419 | # * "-cpu" arguments and global properties: arguments to the -cpu option and | |
4420 | # global properties may affect expansion of CPU models. Using | |
4421 | # query-cpu-model-expansion while using these is not advised. | |
4422 | # | |
137974ce DH |
4423 | # Some architectures may not support all expansion types. s390x supports |
4424 | # "full" and "static". | |
e09484ef DH |
4425 | # |
4426 | # Returns: a CpuModelExpansionInfo. Returns an error if expanding CPU models is | |
4427 | # not supported, if the model cannot be expanded, if the model contains | |
4428 | # an unknown CPU definition name, unknown properties or properties | |
4429 | # with a wrong type. Also returns an error if an expansion type is | |
4430 | # not supported. | |
4431 | # | |
4432 | # Since: 2.8.0 | |
4433 | ## | |
4434 | { 'command': 'query-cpu-model-expansion', | |
4435 | 'data': { 'type': 'CpuModelExpansionType', | |
4436 | 'model': 'CpuModelInfo' }, | |
4437 | 'returns': 'CpuModelExpansionInfo' } | |
4438 | ||
0031e0d6 DH |
4439 | ## |
4440 | # @CpuModelCompareResult: | |
4441 | # | |
4442 | # An enumeration of CPU model comparation results. The result is usually | |
4d4ccabd | 4443 | # calculated using e.g. CPU features or CPU generations. |
0031e0d6 DH |
4444 | # |
4445 | # @incompatible: If model A is incompatible to model B, model A is not | |
4446 | # guaranteed to run where model B runs and the other way around. | |
4447 | # | |
4448 | # @identical: If model A is identical to model B, model A is guaranteed to run | |
4449 | # where model B runs and the other way around. | |
4450 | # | |
4451 | # @superset: If model A is a superset of model B, model B is guaranteed to run | |
4452 | # where model A runs. There are no guarantees about the other way. | |
4453 | # | |
4454 | # @subset: If model A is a subset of model B, model A is guaranteed to run | |
4455 | # where model B runs. There are no guarantees about the other way. | |
4456 | # | |
4457 | # Since: 2.8.0 | |
4458 | ## | |
4459 | { 'enum': 'CpuModelCompareResult', | |
4460 | 'data': [ 'incompatible', 'identical', 'superset', 'subset' ] } | |
4461 | ||
4462 | ## | |
5072f7b3 | 4463 | # @CpuModelCompareInfo: |
0031e0d6 DH |
4464 | # |
4465 | # The result of a CPU model comparison. | |
4466 | # | |
4467 | # @result: The result of the compare operation. | |
4468 | # @responsible-properties: List of properties that led to the comparison result | |
4469 | # not being identical. | |
4470 | # | |
4471 | # @responsible-properties is a list of QOM property names that led to | |
4472 | # both CPUs not being detected as identical. For identical models, this | |
4473 | # list is empty. | |
4474 | # If a QOM property is read-only, that means there's no known way to make the | |
4475 | # CPU models identical. If the special property name "type" is included, the | |
4476 | # models are by definition not identical and cannot be made identical. | |
4477 | # | |
4478 | # Since: 2.8.0 | |
4479 | ## | |
4480 | { 'struct': 'CpuModelCompareInfo', | |
4481 | 'data': {'result': 'CpuModelCompareResult', | |
4482 | 'responsible-properties': ['str'] | |
4483 | } | |
4484 | } | |
4485 | ||
4486 | ## | |
4487 | # @query-cpu-model-comparison: | |
4488 | # | |
4489 | # Compares two CPU models, returning how they compare in a specific | |
4490 | # configuration. The results indicates how both models compare regarding | |
4491 | # runnability. This result can be used by tooling to make decisions if a | |
4492 | # certain CPU model will run in a certain configuration or if a compatible | |
4493 | # CPU model has to be created by baselining. | |
4494 | # | |
4495 | # Usually, a CPU model is compared against the maximum possible CPU model | |
4d4ccabd | 4496 | # of a certain configuration (e.g. the "host" model for KVM). If that CPU |
0031e0d6 DH |
4497 | # model is identical or a subset, it will run in that configuration. |
4498 | # | |
4499 | # The result returned by this command may be affected by: | |
4500 | # | |
4501 | # * QEMU version: CPU models may look different depending on the QEMU version. | |
4502 | # (Except for CPU models reported as "static" in query-cpu-definitions.) | |
4d4ccabd | 4503 | # * machine-type: CPU model may look different depending on the machine-type. |
0031e0d6 DH |
4504 | # (Except for CPU models reported as "static" in query-cpu-definitions.) |
4505 | # * machine options (including accelerator): in some architectures, CPU models | |
4506 | # may look different depending on machine and accelerator options. (Except for | |
4507 | # CPU models reported as "static" in query-cpu-definitions.) | |
4508 | # * "-cpu" arguments and global properties: arguments to the -cpu option and | |
4509 | # global properties may affect expansion of CPU models. Using | |
4510 | # query-cpu-model-expansion while using these is not advised. | |
4511 | # | |
4e82ef05 DH |
4512 | # Some architectures may not support comparing CPU models. s390x supports |
4513 | # comparing CPU models. | |
0031e0d6 DH |
4514 | # |
4515 | # Returns: a CpuModelBaselineInfo. Returns an error if comparing CPU models is | |
4516 | # not supported, if a model cannot be used, if a model contains | |
4517 | # an unknown cpu definition name, unknown properties or properties | |
4518 | # with wrong types. | |
4519 | # | |
4520 | # Since: 2.8.0 | |
4521 | ## | |
4522 | { 'command': 'query-cpu-model-comparison', | |
4523 | 'data': { 'modela': 'CpuModelInfo', 'modelb': 'CpuModelInfo' }, | |
4524 | 'returns': 'CpuModelCompareInfo' } | |
4525 | ||
b18b6043 | 4526 | ## |
5072f7b3 | 4527 | # @CpuModelBaselineInfo: |
b18b6043 DH |
4528 | # |
4529 | # The result of a CPU model baseline. | |
4530 | # | |
4531 | # @model: the baselined CpuModelInfo. | |
4532 | # | |
4533 | # Since: 2.8.0 | |
4534 | ## | |
4535 | { 'struct': 'CpuModelBaselineInfo', | |
4536 | 'data': { 'model': 'CpuModelInfo' } } | |
4537 | ||
4538 | ## | |
4539 | # @query-cpu-model-baseline: | |
4540 | # | |
4541 | # Baseline two CPU models, creating a compatible third model. The created | |
4542 | # model will always be a static, migration-safe CPU model (see "static" | |
4543 | # CPU model expansion for details). | |
4544 | # | |
4545 | # This interface can be used by tooling to create a compatible CPU model out | |
4546 | # two CPU models. The created CPU model will be identical to or a subset of | |
4547 | # both CPU models when comparing them. Therefore, the created CPU model is | |
4548 | # guaranteed to run where the given CPU models run. | |
4549 | # | |
4550 | # The result returned by this command may be affected by: | |
4551 | # | |
4552 | # * QEMU version: CPU models may look different depending on the QEMU version. | |
4553 | # (Except for CPU models reported as "static" in query-cpu-definitions.) | |
4d4ccabd | 4554 | # * machine-type: CPU model may look different depending on the machine-type. |
b18b6043 DH |
4555 | # (Except for CPU models reported as "static" in query-cpu-definitions.) |
4556 | # * machine options (including accelerator): in some architectures, CPU models | |
4557 | # may look different depending on machine and accelerator options. (Except for | |
4558 | # CPU models reported as "static" in query-cpu-definitions.) | |
4559 | # * "-cpu" arguments and global properties: arguments to the -cpu option and | |
4560 | # global properties may affect expansion of CPU models. Using | |
4561 | # query-cpu-model-expansion while using these is not advised. | |
4562 | # | |
f1a47d08 DH |
4563 | # Some architectures may not support baselining CPU models. s390x supports |
4564 | # baselining CPU models. | |
b18b6043 DH |
4565 | # |
4566 | # Returns: a CpuModelBaselineInfo. Returns an error if baselining CPU models is | |
4567 | # not supported, if a model cannot be used, if a model contains | |
4568 | # an unknown cpu definition name, unknown properties or properties | |
4569 | # with wrong types. | |
4570 | # | |
4571 | # Since: 2.8.0 | |
4572 | ## | |
4573 | { 'command': 'query-cpu-model-baseline', | |
4574 | 'data': { 'modela': 'CpuModelInfo', | |
4575 | 'modelb': 'CpuModelInfo' }, | |
4576 | 'returns': 'CpuModelBaselineInfo' } | |
4577 | ||
49687ace | 4578 | ## |
ba1c048a CB |
4579 | # @AddfdInfo: |
4580 | # | |
4581 | # Information about a file descriptor that was added to an fd set. | |
4582 | # | |
4583 | # @fdset-id: The ID of the fd set that @fd was added to. | |
4584 | # | |
4585 | # @fd: The file descriptor that was received via SCM rights and | |
4586 | # added to the fd set. | |
4587 | # | |
4588 | # Since: 1.2.0 | |
4589 | ## | |
895a2a80 | 4590 | { 'struct': 'AddfdInfo', 'data': {'fdset-id': 'int', 'fd': 'int'} } |
ba1c048a CB |
4591 | |
4592 | ## | |
4593 | # @add-fd: | |
4594 | # | |
4595 | # Add a file descriptor, that was passed via SCM rights, to an fd set. | |
4596 | # | |
1d8bda12 | 4597 | # @fdset-id: The ID of the fd set to add the file descriptor to. |
ba1c048a | 4598 | # |
1d8bda12 | 4599 | # @opaque: A free-form string that can be used to describe the fd. |
ba1c048a CB |
4600 | # |
4601 | # Returns: @AddfdInfo on success | |
43fef34a | 4602 | # |
ba1c048a | 4603 | # If file descriptor was not received, FdNotSupplied |
43fef34a | 4604 | # |
9ac54af0 | 4605 | # If @fdset-id is a negative value, InvalidParameterValue |
ba1c048a CB |
4606 | # |
4607 | # Notes: The list of fd sets is shared by all monitor connections. | |
4608 | # | |
4609 | # If @fdset-id is not specified, a new fd set will be created. | |
4610 | # | |
4611 | # Since: 1.2.0 | |
43fef34a MAL |
4612 | # |
4613 | # Example: | |
4614 | # | |
4615 | # -> { "execute": "add-fd", "arguments": { "fdset-id": 1 } } | |
4616 | # <- { "return": { "fdset-id": 1, "fd": 3 } } | |
4617 | # | |
ba1c048a CB |
4618 | ## |
4619 | { 'command': 'add-fd', 'data': {'*fdset-id': 'int', '*opaque': 'str'}, | |
4620 | 'returns': 'AddfdInfo' } | |
4621 | ||
4622 | ## | |
4623 | # @remove-fd: | |
4624 | # | |
4625 | # Remove a file descriptor from an fd set. | |
4626 | # | |
4627 | # @fdset-id: The ID of the fd set that the file descriptor belongs to. | |
4628 | # | |
1d8bda12 | 4629 | # @fd: The file descriptor that is to be removed. |
ba1c048a CB |
4630 | # |
4631 | # Returns: Nothing on success | |
4632 | # If @fdset-id or @fd is not found, FdNotFound | |
4633 | # | |
4634 | # Since: 1.2.0 | |
4635 | # | |
4636 | # Notes: The list of fd sets is shared by all monitor connections. | |
4637 | # | |
4638 | # If @fd is not specified, all file descriptors in @fdset-id | |
4639 | # will be removed. | |
4503e4b3 MAL |
4640 | # |
4641 | # Example: | |
4642 | # | |
4643 | # -> { "execute": "remove-fd", "arguments": { "fdset-id": 1, "fd": 3 } } | |
4644 | # <- { "return": {} } | |
4645 | # | |
ba1c048a CB |
4646 | ## |
4647 | { 'command': 'remove-fd', 'data': {'fdset-id': 'int', '*fd': 'int'} } | |
4648 | ||
4649 | ## | |
4650 | # @FdsetFdInfo: | |
4651 | # | |
4652 | # Information about a file descriptor that belongs to an fd set. | |
4653 | # | |
4654 | # @fd: The file descriptor value. | |
4655 | # | |
1d8bda12 | 4656 | # @opaque: A free-form string that can be used to describe the fd. |
ba1c048a CB |
4657 | # |
4658 | # Since: 1.2.0 | |
4659 | ## | |
895a2a80 | 4660 | { 'struct': 'FdsetFdInfo', |
ba1c048a CB |
4661 | 'data': {'fd': 'int', '*opaque': 'str'} } |
4662 | ||
4663 | ## | |
4664 | # @FdsetInfo: | |
4665 | # | |
4666 | # Information about an fd set. | |
4667 | # | |
4668 | # @fdset-id: The ID of the fd set. | |
4669 | # | |
4670 | # @fds: A list of file descriptors that belong to this fd set. | |
4671 | # | |
4672 | # Since: 1.2.0 | |
4673 | ## | |
895a2a80 | 4674 | { 'struct': 'FdsetInfo', |
ba1c048a CB |
4675 | 'data': {'fdset-id': 'int', 'fds': ['FdsetFdInfo']} } |
4676 | ||
4677 | ## | |
4678 | # @query-fdsets: | |
4679 | # | |
4680 | # Return information describing all fd sets. | |
4681 | # | |
4682 | # Returns: A list of @FdsetInfo | |
4683 | # | |
4684 | # Since: 1.2.0 | |
4685 | # | |
4686 | # Note: The list of fd sets is shared by all monitor connections. | |
4687 | # | |
d71ca35d MAL |
4688 | # Example: |
4689 | # | |
4690 | # -> { "execute": "query-fdsets" } | |
4691 | # <- { "return": [ | |
4692 | # { | |
4693 | # "fds": [ | |
4694 | # { | |
4695 | # "fd": 30, | |
4696 | # "opaque": "rdonly:/path/to/file" | |
4697 | # }, | |
4698 | # { | |
4699 | # "fd": 24, | |
4700 | # "opaque": "rdwr:/path/to/file" | |
4701 | # } | |
4702 | # ], | |
4703 | # "fdset-id": 1 | |
4704 | # }, | |
4705 | # { | |
4706 | # "fds": [ | |
4707 | # { | |
4708 | # "fd": 28 | |
4709 | # }, | |
4710 | # { | |
4711 | # "fd": 29 | |
4712 | # } | |
4713 | # ], | |
4714 | # "fdset-id": 0 | |
4715 | # } | |
4716 | # ] | |
4717 | # } | |
4718 | # | |
ba1c048a CB |
4719 | ## |
4720 | { 'command': 'query-fdsets', 'returns': ['FdsetInfo'] } | |
99afc91d | 4721 | |
99afc91d DB |
4722 | ## |
4723 | # @TargetInfo: | |
4724 | # | |
4725 | # Information describing the QEMU target. | |
4726 | # | |
4727 | # @arch: the target architecture (eg "x86_64", "i386", etc) | |
4728 | # | |
4729 | # Since: 1.2.0 | |
4730 | ## | |
895a2a80 | 4731 | { 'struct': 'TargetInfo', |
c02a9552 | 4732 | 'data': { 'arch': 'str' } } |
99afc91d DB |
4733 | |
4734 | ## | |
4735 | # @query-target: | |
4736 | # | |
4737 | # Return information about the target for this QEMU | |
4738 | # | |
4739 | # Returns: TargetInfo | |
4740 | # | |
4741 | # Since: 1.2.0 | |
4742 | ## | |
4743 | { 'command': 'query-target', 'returns': 'TargetInfo' } | |
411656f4 AK |
4744 | |
4745 | ## | |
4746 | # @QKeyCode: | |
4747 | # | |
515b17c2 MAL |
4748 | # An enumeration of key name. |
4749 | # | |
4750 | # This is used by the @send-key command. | |
4751 | # | |
9f2a70e4 MAL |
4752 | # @unmapped: since 2.0 |
4753 | # @pause: since 2.0 | |
4754 | # @ro: since 2.4 | |
4755 | # @kp_comma: since 2.4 | |
4756 | # @kp_equals: since 2.6 | |
4757 | # @power: since 2.6 | |
e9346441 OH |
4758 | # @hiragana: since 2.9 |
4759 | # @henkan: since 2.9 | |
4760 | # @yen: since 2.9 | |
9f2a70e4 | 4761 | # |
411656f4 | 4762 | # Since: 1.3.0 |
bbd1b1cc | 4763 | # |
411656f4 AK |
4764 | ## |
4765 | { 'enum': 'QKeyCode', | |
bbd1b1cc GH |
4766 | 'data': [ 'unmapped', |
4767 | 'shift', 'shift_r', 'alt', 'alt_r', 'altgr', 'altgr_r', 'ctrl', | |
411656f4 AK |
4768 | 'ctrl_r', 'menu', 'esc', '1', '2', '3', '4', '5', '6', '7', '8', |
4769 | '9', '0', 'minus', 'equal', 'backspace', 'tab', 'q', 'w', 'e', | |
4770 | 'r', 't', 'y', 'u', 'i', 'o', 'p', 'bracket_left', 'bracket_right', | |
4771 | 'ret', 'a', 's', 'd', 'f', 'g', 'h', 'j', 'k', 'l', 'semicolon', | |
4772 | 'apostrophe', 'grave_accent', 'backslash', 'z', 'x', 'c', 'v', 'b', | |
4773 | 'n', 'm', 'comma', 'dot', 'slash', 'asterisk', 'spc', 'caps_lock', | |
4774 | 'f1', 'f2', 'f3', 'f4', 'f5', 'f6', 'f7', 'f8', 'f9', 'f10', | |
4775 | 'num_lock', 'scroll_lock', 'kp_divide', 'kp_multiply', | |
4776 | 'kp_subtract', 'kp_add', 'kp_enter', 'kp_decimal', 'sysrq', 'kp_0', | |
4777 | 'kp_1', 'kp_2', 'kp_3', 'kp_4', 'kp_5', 'kp_6', 'kp_7', 'kp_8', | |
4778 | 'kp_9', 'less', 'f11', 'f12', 'print', 'home', 'pgup', 'pgdn', 'end', | |
4779 | 'left', 'up', 'down', 'right', 'insert', 'delete', 'stop', 'again', | |
4780 | 'props', 'undo', 'front', 'copy', 'open', 'paste', 'find', 'cut', | |
e9346441 OH |
4781 | 'lf', 'help', 'meta_l', 'meta_r', 'compose', 'pause', |
4782 | 'ro', 'hiragana', 'henkan', 'yen', | |
a3541278 | 4783 | 'kp_comma', 'kp_equals', 'power' ] } |
e4c8f004 | 4784 | |
9f328977 | 4785 | ## |
5072f7b3 | 4786 | # @KeyValue: |
9f328977 LC |
4787 | # |
4788 | # Represents a keyboard key. | |
4789 | # | |
4790 | # Since: 1.3.0 | |
4791 | ## | |
4792 | { 'union': 'KeyValue', | |
4793 | 'data': { | |
4794 | 'number': 'int', | |
4795 | 'qcode': 'QKeyCode' } } | |
4796 | ||
e4c8f004 AK |
4797 | ## |
4798 | # @send-key: | |
4799 | # | |
4800 | # Send keys to guest. | |
4801 | # | |
9f328977 LC |
4802 | # @keys: An array of @KeyValue elements. All @KeyValues in this array are |
4803 | # simultaneously sent to the guest. A @KeyValue.number value is sent | |
4804 | # directly to the guest, while @KeyValue.qcode must be a valid | |
4805 | # @QKeyCode value | |
e4c8f004 | 4806 | # |
1d8bda12 | 4807 | # @hold-time: time to delay key up events, milliseconds. Defaults |
e4c8f004 AK |
4808 | # to 100 |
4809 | # | |
4810 | # Returns: Nothing on success | |
4811 | # If key is unknown or redundant, InvalidParameter | |
4812 | # | |
4813 | # Since: 1.3.0 | |
4814 | # | |
f45fd52c MAL |
4815 | # Example: |
4816 | # | |
4817 | # -> { "execute": "send-key", | |
4818 | # "arguments": { "keys": [ { "type": "qcode", "data": "ctrl" }, | |
4819 | # { "type": "qcode", "data": "alt" }, | |
4820 | # { "type": "qcode", "data": "delete" } ] } } | |
4821 | # <- { "return": {} } | |
4822 | # | |
e4c8f004 AK |
4823 | ## |
4824 | { 'command': 'send-key', | |
9f328977 | 4825 | 'data': { 'keys': ['KeyValue'], '*hold-time': 'int' } } |
ad39cf6d LC |
4826 | |
4827 | ## | |
4828 | # @screendump: | |
4829 | # | |
4830 | # Write a PPM of the VGA screen to a file. | |
4831 | # | |
4832 | # @filename: the path of a new PPM file to store the image | |
4833 | # | |
4834 | # Returns: Nothing on success | |
4835 | # | |
4836 | # Since: 0.14.0 | |
77b6681e MAL |
4837 | # |
4838 | # Example: | |
4839 | # | |
4840 | # -> { "execute": "screendump", | |
4841 | # "arguments": { "filename": "/tmp/image" } } | |
4842 | # <- { "return": {} } | |
4843 | # | |
ad39cf6d LC |
4844 | ## |
4845 | { 'command': 'screendump', 'data': {'filename': 'str'} } | |
6dd844db | 4846 | |
d0d7708b DB |
4847 | |
4848 | ## | |
4849 | # @ChardevCommon: | |
4850 | # | |
4851 | # Configuration shared across all chardev backends | |
4852 | # | |
1d8bda12 MA |
4853 | # @logfile: The name of a logfile to save output |
4854 | # @logappend: true to append instead of truncate | |
d0d7708b DB |
4855 | # (default to false to truncate) |
4856 | # | |
4857 | # Since: 2.6 | |
4858 | ## | |
4859 | { 'struct': 'ChardevCommon', 'data': { '*logfile': 'str', | |
4860 | '*logappend': 'bool' } } | |
4861 | ||
ffbdbe59 GH |
4862 | ## |
4863 | # @ChardevFile: | |
4864 | # | |
4865 | # Configuration info for file chardevs. | |
4866 | # | |
1d8bda12 | 4867 | # @in: The name of the input file |
ffbdbe59 | 4868 | # @out: The name of the output file |
1d8bda12 | 4869 | # @append: Open the file in append mode (default false to |
31e38a22 | 4870 | # truncate) (Since 2.6) |
ffbdbe59 GH |
4871 | # |
4872 | # Since: 1.4 | |
4873 | ## | |
895a2a80 | 4874 | { 'struct': 'ChardevFile', 'data': { '*in' : 'str', |
31e38a22 | 4875 | 'out' : 'str', |
d0d7708b DB |
4876 | '*append': 'bool' }, |
4877 | 'base': 'ChardevCommon' } | |
ffbdbe59 | 4878 | |
d59044ef | 4879 | ## |
d36b2b90 | 4880 | # @ChardevHostdev: |
d59044ef | 4881 | # |
548cbb36 | 4882 | # Configuration info for device and pipe chardevs. |
d59044ef GH |
4883 | # |
4884 | # @device: The name of the special file for the device, | |
4885 | # i.e. /dev/ttyS0 on Unix or COM1: on Windows | |
d59044ef GH |
4886 | # |
4887 | # Since: 1.4 | |
4888 | ## | |
d0d7708b DB |
4889 | { 'struct': 'ChardevHostdev', 'data': { 'device' : 'str' }, |
4890 | 'base': 'ChardevCommon' } | |
d59044ef | 4891 | |
f6bd5d6e GH |
4892 | ## |
4893 | # @ChardevSocket: | |
4894 | # | |
3ecc059d | 4895 | # Configuration info for (stream) socket chardevs. |
f6bd5d6e GH |
4896 | # |
4897 | # @addr: socket address to listen on (server=true) | |
4898 | # or connect to (server=false) | |
1d8bda12 MA |
4899 | # @tls-creds: the ID of the TLS credentials object (since 2.6) |
4900 | # @server: create server socket (default: true) | |
4901 | # @wait: wait for incoming connection on server | |
ef993ba7 | 4902 | # sockets (default: false). |
1d8bda12 MA |
4903 | # @nodelay: set TCP_NODELAY socket option (default: false) |
4904 | # @telnet: enable telnet protocol on server | |
ef993ba7 | 4905 | # sockets (default: false) |
ae92cbd5 JL |
4906 | # @tn3270: enable tn3270 protocol on server |
4907 | # sockets (default: false) (Since: 2.10) | |
1d8bda12 | 4908 | # @reconnect: For a client socket, if a socket is disconnected, |
5dd1f02b CM |
4909 | # then attempt a reconnect after the given number of seconds. |
4910 | # Setting this to zero disables this function. (default: 0) | |
4911 | # (Since: 2.2) | |
f6bd5d6e GH |
4912 | # |
4913 | # Since: 1.4 | |
4914 | ## | |
dfd100f2 | 4915 | { 'struct': 'ChardevSocket', 'data': { 'addr' : 'SocketAddressLegacy', |
a8fb5427 | 4916 | '*tls-creds' : 'str', |
5dd1f02b CM |
4917 | '*server' : 'bool', |
4918 | '*wait' : 'bool', | |
4919 | '*nodelay' : 'bool', | |
4920 | '*telnet' : 'bool', | |
ae92cbd5 | 4921 | '*tn3270' : 'bool', |
d0d7708b DB |
4922 | '*reconnect' : 'int' }, |
4923 | 'base': 'ChardevCommon' } | |
f6bd5d6e | 4924 | |
3ecc059d | 4925 | ## |
08d0ab3f | 4926 | # @ChardevUdp: |
3ecc059d GH |
4927 | # |
4928 | # Configuration info for datagram socket chardevs. | |
4929 | # | |
4930 | # @remote: remote address | |
1d8bda12 | 4931 | # @local: local address |
3ecc059d GH |
4932 | # |
4933 | # Since: 1.5 | |
4934 | ## | |
dfd100f2 MA |
4935 | { 'struct': 'ChardevUdp', 'data': { 'remote' : 'SocketAddressLegacy', |
4936 | '*local' : 'SocketAddressLegacy' }, | |
d0d7708b | 4937 | 'base': 'ChardevCommon' } |
3ecc059d | 4938 | |
edb2fb3c GH |
4939 | ## |
4940 | # @ChardevMux: | |
4941 | # | |
4942 | # Configuration info for mux chardevs. | |
4943 | # | |
4944 | # @chardev: name of the base chardev. | |
4945 | # | |
4946 | # Since: 1.5 | |
4947 | ## | |
d0d7708b DB |
4948 | { 'struct': 'ChardevMux', 'data': { 'chardev' : 'str' }, |
4949 | 'base': 'ChardevCommon' } | |
edb2fb3c | 4950 | |
7c358031 GH |
4951 | ## |
4952 | # @ChardevStdio: | |
4953 | # | |
4954 | # Configuration info for stdio chardevs. | |
4955 | # | |
1d8bda12 | 4956 | # @signal: Allow signals (such as SIGINT triggered by ^C) |
7c358031 GH |
4957 | # be delivered to qemu. Default: true in -nographic mode, |
4958 | # false otherwise. | |
4959 | # | |
4960 | # Since: 1.5 | |
4961 | ## | |
d0d7708b DB |
4962 | { 'struct': 'ChardevStdio', 'data': { '*signal' : 'bool' }, |
4963 | 'base': 'ChardevCommon' } | |
4964 | ||
7c358031 | 4965 | |
cd153e2a GH |
4966 | ## |
4967 | # @ChardevSpiceChannel: | |
4968 | # | |
4969 | # Configuration info for spice vm channel chardevs. | |
4970 | # | |
4971 | # @type: kind of channel (for example vdagent). | |
4972 | # | |
4973 | # Since: 1.5 | |
4974 | ## | |
d0d7708b DB |
4975 | { 'struct': 'ChardevSpiceChannel', 'data': { 'type' : 'str' }, |
4976 | 'base': 'ChardevCommon' } | |
cd153e2a GH |
4977 | |
4978 | ## | |
4979 | # @ChardevSpicePort: | |
4980 | # | |
4981 | # Configuration info for spice port chardevs. | |
4982 | # | |
4983 | # @fqdn: name of the channel (see docs/spice-port-fqdn.txt) | |
4984 | # | |
4985 | # Since: 1.5 | |
4986 | ## | |
d0d7708b DB |
4987 | { 'struct': 'ChardevSpicePort', 'data': { 'fqdn' : 'str' }, |
4988 | 'base': 'ChardevCommon' } | |
cd153e2a | 4989 | |
702ec69c GH |
4990 | ## |
4991 | # @ChardevVC: | |
4992 | # | |
4993 | # Configuration info for virtual console chardevs. | |
4994 | # | |
4995 | # @width: console width, in pixels | |
4996 | # @height: console height, in pixels | |
4997 | # @cols: console width, in chars | |
4998 | # @rows: console height, in chars | |
4999 | # | |
5000 | # Since: 1.5 | |
5001 | ## | |
895a2a80 | 5002 | { 'struct': 'ChardevVC', 'data': { '*width' : 'int', |
702ec69c GH |
5003 | '*height' : 'int', |
5004 | '*cols' : 'int', | |
d0d7708b DB |
5005 | '*rows' : 'int' }, |
5006 | 'base': 'ChardevCommon' } | |
702ec69c | 5007 | |
1da48c65 | 5008 | ## |
4f57378f | 5009 | # @ChardevRingbuf: |
1da48c65 | 5010 | # |
3a1da42e | 5011 | # Configuration info for ring buffer chardevs. |
1da48c65 | 5012 | # |
1d8bda12 | 5013 | # @size: ring buffer size, must be power of two, default is 65536 |
1da48c65 GH |
5014 | # |
5015 | # Since: 1.5 | |
5016 | ## | |
d0d7708b DB |
5017 | { 'struct': 'ChardevRingbuf', 'data': { '*size' : 'int' }, |
5018 | 'base': 'ChardevCommon' } | |
1da48c65 | 5019 | |
f1a1a356 GH |
5020 | ## |
5021 | # @ChardevBackend: | |
5022 | # | |
5023 | # Configuration info for the new chardev backend. | |
5024 | # | |
378af961 | 5025 | # Since: 1.4 (testdev since 2.2, wctablet since 2.9) |
f1a1a356 | 5026 | ## |
f6bd5d6e | 5027 | { 'union': 'ChardevBackend', 'data': { 'file' : 'ChardevFile', |
d36b2b90 MA |
5028 | 'serial' : 'ChardevHostdev', |
5029 | 'parallel': 'ChardevHostdev', | |
548cbb36 | 5030 | 'pipe' : 'ChardevHostdev', |
f6bd5d6e | 5031 | 'socket' : 'ChardevSocket', |
08d0ab3f | 5032 | 'udp' : 'ChardevUdp', |
b1918fbb EB |
5033 | 'pty' : 'ChardevCommon', |
5034 | 'null' : 'ChardevCommon', | |
f5a51cab | 5035 | 'mux' : 'ChardevMux', |
b1918fbb | 5036 | 'msmouse': 'ChardevCommon', |
378af961 | 5037 | 'wctablet' : 'ChardevCommon', |
b1918fbb EB |
5038 | 'braille': 'ChardevCommon', |
5039 | 'testdev': 'ChardevCommon', | |
d9ac374f | 5040 | 'stdio' : 'ChardevStdio', |
b1918fbb | 5041 | 'console': 'ChardevCommon', |
cd153e2a | 5042 | 'spicevmc' : 'ChardevSpiceChannel', |
702ec69c | 5043 | 'spiceport' : 'ChardevSpicePort', |
1da48c65 | 5044 | 'vc' : 'ChardevVC', |
3a1da42e MA |
5045 | 'ringbuf': 'ChardevRingbuf', |
5046 | # next one is just for compatibility | |
4f57378f | 5047 | 'memory' : 'ChardevRingbuf' } } |
f1a1a356 GH |
5048 | |
5049 | ## | |
5050 | # @ChardevReturn: | |
5051 | # | |
5052 | # Return info about the chardev backend just created. | |
5053 | # | |
1d8bda12 | 5054 | # @pty: name of the slave pseudoterminal device, present if |
58fa4325 MA |
5055 | # and only if a chardev of type 'pty' was created |
5056 | # | |
f1a1a356 GH |
5057 | # Since: 1.4 |
5058 | ## | |
895a2a80 | 5059 | { 'struct' : 'ChardevReturn', 'data': { '*pty' : 'str' } } |
f1a1a356 GH |
5060 | |
5061 | ## | |
5062 | # @chardev-add: | |
5063 | # | |
58fa4325 | 5064 | # Add a character device backend |
f1a1a356 GH |
5065 | # |
5066 | # @id: the chardev's ID, must be unique | |
5067 | # @backend: backend type and parameters | |
5068 | # | |
58fa4325 | 5069 | # Returns: ChardevReturn. |
f1a1a356 GH |
5070 | # |
5071 | # Since: 1.4 | |
2212092e MAL |
5072 | # |
5073 | # Example: | |
5074 | # | |
5075 | # -> { "execute" : "chardev-add", | |
5076 | # "arguments" : { "id" : "foo", | |
5077 | # "backend" : { "type" : "null", "data" : {} } } } | |
5078 | # <- { "return": {} } | |
5079 | # | |
5080 | # -> { "execute" : "chardev-add", | |
5081 | # "arguments" : { "id" : "bar", | |
5082 | # "backend" : { "type" : "file", | |
5083 | # "data" : { "out" : "/tmp/bar.log" } } } } | |
5084 | # <- { "return": {} } | |
5085 | # | |
5086 | # -> { "execute" : "chardev-add", | |
5087 | # "arguments" : { "id" : "baz", | |
5088 | # "backend" : { "type" : "pty", "data" : {} } } } | |
5089 | # <- { "return": { "pty" : "/dev/pty/42" } } | |
5090 | # | |
f1a1a356 GH |
5091 | ## |
5092 | { 'command': 'chardev-add', 'data': {'id' : 'str', | |
5093 | 'backend' : 'ChardevBackend' }, | |
5094 | 'returns': 'ChardevReturn' } | |
5095 | ||
7bb86085 AN |
5096 | ## |
5097 | # @chardev-change: | |
5098 | # | |
5099 | # Change a character device backend | |
5100 | # | |
5101 | # @id: the chardev's ID, must exist | |
5102 | # @backend: new backend type and parameters | |
5103 | # | |
5104 | # Returns: ChardevReturn. | |
5105 | # | |
5106 | # Since: 2.10 | |
5107 | # | |
5108 | # Example: | |
5109 | # | |
5110 | # -> { "execute" : "chardev-change", | |
5111 | # "arguments" : { "id" : "baz", | |
5112 | # "backend" : { "type" : "pty", "data" : {} } } } | |
5113 | # <- { "return": { "pty" : "/dev/pty/42" } } | |
5114 | # | |
5115 | # -> {"execute" : "chardev-change", | |
5116 | # "arguments" : { | |
5117 | # "id" : "charchannel2", | |
5118 | # "backend" : { | |
5119 | # "type" : "socket", | |
5120 | # "data" : { | |
5121 | # "addr" : { | |
5122 | # "type" : "unix" , | |
5123 | # "data" : { | |
5124 | # "path" : "/tmp/charchannel2.socket" | |
5125 | # } | |
5126 | # }, | |
5127 | # "server" : true, | |
5128 | # "wait" : false }}}} | |
5129 | # <- {"return": {}} | |
5130 | # | |
5131 | ## | |
5132 | { 'command': 'chardev-change', 'data': {'id' : 'str', | |
5133 | 'backend' : 'ChardevBackend' }, | |
5134 | 'returns': 'ChardevReturn' } | |
5135 | ||
f1a1a356 GH |
5136 | ## |
5137 | # @chardev-remove: | |
5138 | # | |
58fa4325 | 5139 | # Remove a character device backend |
f1a1a356 GH |
5140 | # |
5141 | # @id: the chardev's ID, must exist and not be in use | |
5142 | # | |
5143 | # Returns: Nothing on success | |
5144 | # | |
5145 | # Since: 1.4 | |
7cfee8d9 MAL |
5146 | # |
5147 | # Example: | |
5148 | # | |
5149 | # -> { "execute": "chardev-remove", "arguments": { "id" : "foo" } } | |
5150 | # <- { "return": {} } | |
5151 | # | |
f1a1a356 GH |
5152 | ## |
5153 | { 'command': 'chardev-remove', 'data': {'id': 'str'} } | |
d1a0cf73 | 5154 | |
bd1d5ad9 SF |
5155 | ## |
5156 | # @chardev-send-break: | |
5157 | # | |
5158 | # Send a break to a character device | |
5159 | # | |
5160 | # @id: the chardev's ID, must exist | |
5161 | # | |
5162 | # Returns: Nothing on success | |
5163 | # | |
5164 | # Since: 2.10 | |
5165 | # | |
5166 | # Example: | |
5167 | # | |
5168 | # -> { "execute": "chardev-send-break", "arguments": { "id" : "foo" } } | |
5169 | # <- { "return": {} } | |
5170 | # | |
5171 | ## | |
5172 | { 'command': 'chardev-send-break', 'data': {'id': 'str'} } | |
5173 | ||
5174 | ||
d1a0cf73 SB |
5175 | ## |
5176 | # @TpmModel: | |
5177 | # | |
5178 | # An enumeration of TPM models | |
5179 | # | |
5180 | # @tpm-tis: TPM TIS model | |
5181 | # | |
5182 | # Since: 1.5 | |
5183 | ## | |
5184 | { 'enum': 'TpmModel', 'data': [ 'tpm-tis' ] } | |
5185 | ||
5186 | ## | |
5187 | # @query-tpm-models: | |
5188 | # | |
5189 | # Return a list of supported TPM models | |
5190 | # | |
5191 | # Returns: a list of TpmModel | |
5192 | # | |
5193 | # Since: 1.5 | |
b7c7941b MAL |
5194 | # |
5195 | # Example: | |
5196 | # | |
5197 | # -> { "execute": "query-tpm-models" } | |
5198 | # <- { "return": [ "tpm-tis" ] } | |
5199 | # | |
d1a0cf73 SB |
5200 | ## |
5201 | { 'command': 'query-tpm-models', 'returns': ['TpmModel'] } | |
5202 | ||
5203 | ## | |
5204 | # @TpmType: | |
5205 | # | |
5206 | # An enumeration of TPM types | |
5207 | # | |
5208 | # @passthrough: TPM passthrough type | |
5209 | # | |
5210 | # Since: 1.5 | |
5211 | ## | |
5212 | { 'enum': 'TpmType', 'data': [ 'passthrough' ] } | |
5213 | ||
5214 | ## | |
5215 | # @query-tpm-types: | |
5216 | # | |
5217 | # Return a list of supported TPM types | |
5218 | # | |
5219 | # Returns: a list of TpmType | |
5220 | # | |
5221 | # Since: 1.5 | |
5a4c0316 MAL |
5222 | # |
5223 | # Example: | |
5224 | # | |
5225 | # -> { "execute": "query-tpm-types" } | |
5226 | # <- { "return": [ "passthrough" ] } | |
5227 | # | |
d1a0cf73 SB |
5228 | ## |
5229 | { 'command': 'query-tpm-types', 'returns': ['TpmType'] } | |
5230 | ||
5231 | ## | |
5232 | # @TPMPassthroughOptions: | |
5233 | # | |
5234 | # Information about the TPM passthrough type | |
5235 | # | |
1d8bda12 | 5236 | # @path: string describing the path used for accessing the TPM device |
d1a0cf73 | 5237 | # |
1d8bda12 | 5238 | # @cancel-path: string showing the TPM's sysfs cancel file |
d1a0cf73 SB |
5239 | # for cancellation of TPM commands while they are executing |
5240 | # | |
5241 | # Since: 1.5 | |
5242 | ## | |
895a2a80 | 5243 | { 'struct': 'TPMPassthroughOptions', 'data': { '*path' : 'str', |
d1a0cf73 SB |
5244 | '*cancel-path' : 'str'} } |
5245 | ||
5246 | ## | |
5247 | # @TpmTypeOptions: | |
5248 | # | |
5249 | # A union referencing different TPM backend types' configuration options | |
5250 | # | |
4d5c8bc4 | 5251 | # @type: 'passthrough' The configuration options for the TPM passthrough type |
d1a0cf73 SB |
5252 | # |
5253 | # Since: 1.5 | |
5254 | ## | |
5255 | { 'union': 'TpmTypeOptions', | |
88ca7bcf | 5256 | 'data': { 'passthrough' : 'TPMPassthroughOptions' } } |
d1a0cf73 SB |
5257 | |
5258 | ## | |
4d5c8bc4 | 5259 | # @TPMInfo: |
d1a0cf73 SB |
5260 | # |
5261 | # Information about the TPM | |
5262 | # | |
5263 | # @id: The Id of the TPM | |
5264 | # | |
5265 | # @model: The TPM frontend model | |
5266 | # | |
88ca7bcf | 5267 | # @options: The TPM (backend) type configuration options |
d1a0cf73 SB |
5268 | # |
5269 | # Since: 1.5 | |
5270 | ## | |
895a2a80 | 5271 | { 'struct': 'TPMInfo', |
d1a0cf73 SB |
5272 | 'data': {'id': 'str', |
5273 | 'model': 'TpmModel', | |
88ca7bcf | 5274 | 'options': 'TpmTypeOptions' } } |
d1a0cf73 SB |
5275 | |
5276 | ## | |
5277 | # @query-tpm: | |
5278 | # | |
5279 | # Return information about the TPM device | |
5280 | # | |
5281 | # Returns: @TPMInfo on success | |
5282 | # | |
5283 | # Since: 1.5 | |
4e022d01 MAL |
5284 | # |
5285 | # Example: | |
5286 | # | |
5287 | # -> { "execute": "query-tpm" } | |
5288 | # <- { "return": | |
5289 | # [ | |
5290 | # { "model": "tpm-tis", | |
5291 | # "options": | |
5292 | # { "type": "passthrough", | |
5293 | # "data": | |
5294 | # { "cancel-path": "/sys/class/misc/tpm0/device/cancel", | |
5295 | # "path": "/dev/tpm0" | |
5296 | # } | |
5297 | # }, | |
5298 | # "id": "tpm0" | |
5299 | # } | |
5300 | # ] | |
5301 | # } | |
5302 | # | |
d1a0cf73 SB |
5303 | ## |
5304 | { 'command': 'query-tpm', 'returns': ['TPMInfo'] } | |
8ccbad5c LE |
5305 | |
5306 | ## | |
5072f7b3 | 5307 | # @AcpiTableOptions: |
8ccbad5c LE |
5308 | # |
5309 | # Specify an ACPI table on the command line to load. | |
5310 | # | |
5311 | # At most one of @file and @data can be specified. The list of files specified | |
5312 | # by any one of them is loaded and concatenated in order. If both are omitted, | |
5313 | # @data is implied. | |
5314 | # | |
5315 | # Other fields / optargs can be used to override fields of the generic ACPI | |
5316 | # table header; refer to the ACPI specification 5.0, section 5.2.6 System | |
5317 | # Description Table Header. If a header field is not overridden, then the | |
5318 | # corresponding value from the concatenated blob is used (in case of @file), or | |
5319 | # it is filled in with a hard-coded value (in case of @data). | |
5320 | # | |
5321 | # String fields are copied into the matching ACPI member from lowest address | |
5322 | # upwards, and silently truncated / NUL-padded to length. | |
5323 | # | |
1d8bda12 | 5324 | # @sig: table signature / identifier (4 bytes) |
8ccbad5c | 5325 | # |
1d8bda12 | 5326 | # @rev: table revision number (dependent on signature, 1 byte) |
8ccbad5c | 5327 | # |
1d8bda12 | 5328 | # @oem_id: OEM identifier (6 bytes) |
8ccbad5c | 5329 | # |
1d8bda12 | 5330 | # @oem_table_id: OEM table identifier (8 bytes) |
8ccbad5c | 5331 | # |
1d8bda12 | 5332 | # @oem_rev: OEM-supplied revision number (4 bytes) |
8ccbad5c | 5333 | # |
1d8bda12 | 5334 | # @asl_compiler_id: identifier of the utility that created the table |
8ccbad5c LE |
5335 | # (4 bytes) |
5336 | # | |
1d8bda12 | 5337 | # @asl_compiler_rev: revision number of the utility that created the |
8ccbad5c LE |
5338 | # table (4 bytes) |
5339 | # | |
1d8bda12 | 5340 | # @file: colon (:) separated list of pathnames to load and |
8ccbad5c LE |
5341 | # concatenate as table data. The resultant binary blob is expected to |
5342 | # have an ACPI table header. At least one file is required. This field | |
5343 | # excludes @data. | |
5344 | # | |
1d8bda12 | 5345 | # @data: colon (:) separated list of pathnames to load and |
8ccbad5c LE |
5346 | # concatenate as table data. The resultant binary blob must not have an |
5347 | # ACPI table header. At least one file is required. This field excludes | |
5348 | # @file. | |
5349 | # | |
5072f7b3 | 5350 | # Since: 1.5 |
8ccbad5c | 5351 | ## |
895a2a80 | 5352 | { 'struct': 'AcpiTableOptions', |
8ccbad5c LE |
5353 | 'data': { |
5354 | '*sig': 'str', | |
5355 | '*rev': 'uint8', | |
5356 | '*oem_id': 'str', | |
5357 | '*oem_table_id': 'str', | |
5358 | '*oem_rev': 'uint32', | |
5359 | '*asl_compiler_id': 'str', | |
5360 | '*asl_compiler_rev': 'uint32', | |
5361 | '*file': 'str', | |
5362 | '*data': 'str' }} | |
1f8f987d AK |
5363 | |
5364 | ## | |
5365 | # @CommandLineParameterType: | |
5366 | # | |
5367 | # Possible types for an option parameter. | |
5368 | # | |
5369 | # @string: accepts a character string | |
5370 | # | |
5371 | # @boolean: accepts "on" or "off" | |
5372 | # | |
5373 | # @number: accepts a number | |
5374 | # | |
5375 | # @size: accepts a number followed by an optional suffix (K)ilo, | |
5376 | # (M)ega, (G)iga, (T)era | |
5377 | # | |
5072f7b3 | 5378 | # Since: 1.5 |
1f8f987d AK |
5379 | ## |
5380 | { 'enum': 'CommandLineParameterType', | |
5381 | 'data': ['string', 'boolean', 'number', 'size'] } | |
5382 | ||
5383 | ## | |
5384 | # @CommandLineParameterInfo: | |
5385 | # | |
5386 | # Details about a single parameter of a command line option. | |
5387 | # | |
5388 | # @name: parameter name | |
5389 | # | |
5390 | # @type: parameter @CommandLineParameterType | |
5391 | # | |
1d8bda12 | 5392 | # @help: human readable text string, not suitable for parsing. |
1f8f987d | 5393 | # |
1d8bda12 | 5394 | # @default: default value string (since 2.1) |
e36af94f | 5395 | # |
5072f7b3 | 5396 | # Since: 1.5 |
1f8f987d | 5397 | ## |
895a2a80 | 5398 | { 'struct': 'CommandLineParameterInfo', |
1f8f987d AK |
5399 | 'data': { 'name': 'str', |
5400 | 'type': 'CommandLineParameterType', | |
e36af94f CL |
5401 | '*help': 'str', |
5402 | '*default': 'str' } } | |
1f8f987d AK |
5403 | |
5404 | ## | |
5405 | # @CommandLineOptionInfo: | |
5406 | # | |
5407 | # Details about a command line option, including its list of parameter details | |
5408 | # | |
5409 | # @option: option name | |
5410 | # | |
5411 | # @parameters: an array of @CommandLineParameterInfo | |
5412 | # | |
5072f7b3 | 5413 | # Since: 1.5 |
1f8f987d | 5414 | ## |
895a2a80 | 5415 | { 'struct': 'CommandLineOptionInfo', |
1f8f987d AK |
5416 | 'data': { 'option': 'str', 'parameters': ['CommandLineParameterInfo'] } } |
5417 | ||
5418 | ## | |
5419 | # @query-command-line-options: | |
5420 | # | |
5421 | # Query command line option schema. | |
5422 | # | |
1d8bda12 | 5423 | # @option: option name |
1f8f987d AK |
5424 | # |
5425 | # Returns: list of @CommandLineOptionInfo for all options (or for the given | |
5426 | # @option). Returns an error if the given @option doesn't exist. | |
5427 | # | |
5072f7b3 | 5428 | # Since: 1.5 |
e26a0d00 MAL |
5429 | # |
5430 | # Example: | |
5431 | # | |
5432 | # -> { "execute": "query-command-line-options", | |
5433 | # "arguments": { "option": "option-rom" } } | |
5434 | # <- { "return": [ | |
5435 | # { | |
5436 | # "parameters": [ | |
5437 | # { | |
5438 | # "name": "romfile", | |
5439 | # "type": "string" | |
5440 | # }, | |
5441 | # { | |
5442 | # "name": "bootindex", | |
5443 | # "type": "number" | |
5444 | # } | |
5445 | # ], | |
5446 | # "option": "option-rom" | |
5447 | # } | |
5448 | # ] | |
5449 | # } | |
5450 | # | |
1f8f987d AK |
5451 | ## |
5452 | {'command': 'query-command-line-options', 'data': { '*option': 'str' }, | |
5453 | 'returns': ['CommandLineOptionInfo'] } | |
8e8aba50 EH |
5454 | |
5455 | ## | |
5072f7b3 | 5456 | # @X86CPURegister32: |
8e8aba50 EH |
5457 | # |
5458 | # A X86 32-bit register | |
5459 | # | |
5460 | # Since: 1.5 | |
5461 | ## | |
5462 | { 'enum': 'X86CPURegister32', | |
5463 | 'data': [ 'EAX', 'EBX', 'ECX', 'EDX', 'ESP', 'EBP', 'ESI', 'EDI' ] } | |
5464 | ||
5465 | ## | |
5072f7b3 | 5466 | # @X86CPUFeatureWordInfo: |
8e8aba50 EH |
5467 | # |
5468 | # Information about a X86 CPU feature word | |
5469 | # | |
5470 | # @cpuid-input-eax: Input EAX value for CPUID instruction for that feature word | |
5471 | # | |
1d8bda12 | 5472 | # @cpuid-input-ecx: Input ECX value for CPUID instruction for that |
8e8aba50 EH |
5473 | # feature word |
5474 | # | |
5475 | # @cpuid-register: Output register containing the feature bits | |
5476 | # | |
5477 | # @features: value of output register, containing the feature bits | |
5478 | # | |
5479 | # Since: 1.5 | |
5480 | ## | |
895a2a80 | 5481 | { 'struct': 'X86CPUFeatureWordInfo', |
8e8aba50 EH |
5482 | 'data': { 'cpuid-input-eax': 'int', |
5483 | '*cpuid-input-ecx': 'int', | |
5484 | 'cpuid-register': 'X86CPURegister32', | |
5485 | 'features': 'int' } } | |
b1be4280 | 5486 | |
9f08c8ec | 5487 | ## |
5072f7b3 | 5488 | # @DummyForceArrays: |
9f08c8ec EB |
5489 | # |
5490 | # Not used by QMP; hack to let us use X86CPUFeatureWordInfoList internally | |
5491 | # | |
5072f7b3 | 5492 | # Since: 2.5 |
9f08c8ec EB |
5493 | ## |
5494 | { 'struct': 'DummyForceArrays', | |
5495 | 'data': { 'unused': ['X86CPUFeatureWordInfo'] } } | |
5496 | ||
5497 | ||
b1be4280 AK |
5498 | ## |
5499 | # @RxState: | |
5500 | # | |
5501 | # Packets receiving state | |
5502 | # | |
5503 | # @normal: filter assigned packets according to the mac-table | |
5504 | # | |
5505 | # @none: don't receive any assigned packet | |
5506 | # | |
5507 | # @all: receive all assigned packets | |
5508 | # | |
5509 | # Since: 1.6 | |
5510 | ## | |
5511 | { 'enum': 'RxState', 'data': [ 'normal', 'none', 'all' ] } | |
5512 | ||
5513 | ## | |
5514 | # @RxFilterInfo: | |
5515 | # | |
5516 | # Rx-filter information for a NIC. | |
5517 | # | |
5518 | # @name: net client name | |
5519 | # | |
5520 | # @promiscuous: whether promiscuous mode is enabled | |
5521 | # | |
5522 | # @multicast: multicast receive state | |
5523 | # | |
5524 | # @unicast: unicast receive state | |
5525 | # | |
f7bc8ef8 AK |
5526 | # @vlan: vlan receive state (Since 2.0) |
5527 | # | |
b1be4280 AK |
5528 | # @broadcast-allowed: whether to receive broadcast |
5529 | # | |
5530 | # @multicast-overflow: multicast table is overflowed or not | |
5531 | # | |
5532 | # @unicast-overflow: unicast table is overflowed or not | |
5533 | # | |
5534 | # @main-mac: the main macaddr string | |
5535 | # | |
5536 | # @vlan-table: a list of active vlan id | |
5537 | # | |
5538 | # @unicast-table: a list of unicast macaddr string | |
5539 | # | |
5540 | # @multicast-table: a list of multicast macaddr string | |
5541 | # | |
5072f7b3 | 5542 | # Since: 1.6 |
b1be4280 | 5543 | ## |
895a2a80 | 5544 | { 'struct': 'RxFilterInfo', |
b1be4280 AK |
5545 | 'data': { |
5546 | 'name': 'str', | |
5547 | 'promiscuous': 'bool', | |
5548 | 'multicast': 'RxState', | |
5549 | 'unicast': 'RxState', | |
f7bc8ef8 | 5550 | 'vlan': 'RxState', |
b1be4280 AK |
5551 | 'broadcast-allowed': 'bool', |
5552 | 'multicast-overflow': 'bool', | |
5553 | 'unicast-overflow': 'bool', | |
5554 | 'main-mac': 'str', | |
5555 | 'vlan-table': ['int'], | |
5556 | 'unicast-table': ['str'], | |
5557 | 'multicast-table': ['str'] }} | |
5558 | ||
5559 | ## | |
5560 | # @query-rx-filter: | |
5561 | # | |
5562 | # Return rx-filter information for all NICs (or for the given NIC). | |
5563 | # | |
1d8bda12 | 5564 | # @name: net client name |
b1be4280 AK |
5565 | # |
5566 | # Returns: list of @RxFilterInfo for all NICs (or for the given NIC). | |
5567 | # Returns an error if the given @name doesn't exist, or given | |
5568 | # NIC doesn't support rx-filter querying, or given net client | |
5569 | # isn't a NIC. | |
5570 | # | |
5571 | # Since: 1.6 | |
043ea312 MAL |
5572 | # |
5573 | # Example: | |
5574 | # | |
5575 | # -> { "execute": "query-rx-filter", "arguments": { "name": "vnet0" } } | |
5576 | # <- { "return": [ | |
5577 | # { | |
5578 | # "promiscuous": true, | |
5579 | # "name": "vnet0", | |
5580 | # "main-mac": "52:54:00:12:34:56", | |
5581 | # "unicast": "normal", | |
5582 | # "vlan": "normal", | |
5583 | # "vlan-table": [ | |
5584 | # 4, | |
5585 | # 0 | |
5586 | # ], | |
5587 | # "unicast-table": [ | |
5588 | # ], | |
5589 | # "multicast": "normal", | |
5590 | # "multicast-overflow": false, | |
5591 | # "unicast-overflow": false, | |
5592 | # "multicast-table": [ | |
5593 | # "01:00:5e:00:00:01", | |
5594 | # "33:33:00:00:00:01", | |
5595 | # "33:33:ff:12:34:56" | |
5596 | # ], | |
5597 | # "broadcast-allowed": false | |
5598 | # } | |
5599 | # ] | |
5600 | # } | |
5601 | # | |
b1be4280 AK |
5602 | ## |
5603 | { 'command': 'query-rx-filter', 'data': { '*name': 'str' }, | |
5604 | 'returns': ['RxFilterInfo'] } | |
d26c9a15 | 5605 | |
031fa964 | 5606 | ## |
5072f7b3 | 5607 | # @InputButton: |
031fa964 GH |
5608 | # |
5609 | # Button of a pointer input device (mouse, tablet). | |
5610 | # | |
0095cc62 FL |
5611 | # @side: front side button of a 5-button mouse (since 2.9) |
5612 | # | |
5613 | # @extra: rear side button of a 5-button mouse (since 2.9) | |
5614 | # | |
031fa964 GH |
5615 | # Since: 2.0 |
5616 | ## | |
5617 | { 'enum' : 'InputButton', | |
0095cc62 FL |
5618 | 'data' : [ 'left', 'middle', 'right', 'wheel-up', 'wheel-down', 'side', |
5619 | 'extra' ] } | |
031fa964 GH |
5620 | |
5621 | ## | |
5072f7b3 | 5622 | # @InputAxis: |
031fa964 GH |
5623 | # |
5624 | # Position axis of a pointer input device (mouse, tablet). | |
5625 | # | |
5626 | # Since: 2.0 | |
5627 | ## | |
5628 | { 'enum' : 'InputAxis', | |
01df5143 | 5629 | 'data' : [ 'x', 'y' ] } |
031fa964 GH |
5630 | |
5631 | ## | |
5072f7b3 | 5632 | # @InputKeyEvent: |
031fa964 GH |
5633 | # |
5634 | # Keyboard input event. | |
5635 | # | |
5636 | # @key: Which key this event is for. | |
5637 | # @down: True for key-down and false for key-up events. | |
5638 | # | |
5639 | # Since: 2.0 | |
5640 | ## | |
895a2a80 | 5641 | { 'struct' : 'InputKeyEvent', |
031fa964 GH |
5642 | 'data' : { 'key' : 'KeyValue', |
5643 | 'down' : 'bool' } } | |
5644 | ||
5645 | ## | |
5072f7b3 | 5646 | # @InputBtnEvent: |
031fa964 GH |
5647 | # |
5648 | # Pointer button input event. | |
5649 | # | |
5650 | # @button: Which button this event is for. | |
5651 | # @down: True for key-down and false for key-up events. | |
5652 | # | |
5653 | # Since: 2.0 | |
5654 | ## | |
895a2a80 | 5655 | { 'struct' : 'InputBtnEvent', |
031fa964 GH |
5656 | 'data' : { 'button' : 'InputButton', |
5657 | 'down' : 'bool' } } | |
5658 | ||
5659 | ## | |
5072f7b3 | 5660 | # @InputMoveEvent: |
031fa964 GH |
5661 | # |
5662 | # Pointer motion input event. | |
5663 | # | |
5664 | # @axis: Which axis is referenced by @value. | |
5665 | # @value: Pointer position. For absolute coordinates the | |
5666 | # valid range is 0 -> 0x7ffff | |
5667 | # | |
5668 | # Since: 2.0 | |
5669 | ## | |
895a2a80 | 5670 | { 'struct' : 'InputMoveEvent', |
031fa964 GH |
5671 | 'data' : { 'axis' : 'InputAxis', |
5672 | 'value' : 'int' } } | |
5673 | ||
5674 | ## | |
5072f7b3 | 5675 | # @InputEvent: |
031fa964 GH |
5676 | # |
5677 | # Input event union. | |
5678 | # | |
4d5c8bc4 MAL |
5679 | # @type: the input type, one of: |
5680 | # - 'key': Input event of Keyboard | |
5681 | # - 'btn': Input event of pointer buttons | |
5682 | # - 'rel': Input event of relative pointer motion | |
5683 | # - 'abs': Input event of absolute pointer motion | |
935fb915 | 5684 | # |
031fa964 GH |
5685 | # Since: 2.0 |
5686 | ## | |
5687 | { 'union' : 'InputEvent', | |
5688 | 'data' : { 'key' : 'InputKeyEvent', | |
5689 | 'btn' : 'InputBtnEvent', | |
5690 | 'rel' : 'InputMoveEvent', | |
5691 | 'abs' : 'InputMoveEvent' } } | |
0042109a | 5692 | |
50c6617f | 5693 | ## |
5072f7b3 | 5694 | # @input-send-event: |
50c6617f MT |
5695 | # |
5696 | # Send input event(s) to guest. | |
5697 | # | |
1d8bda12 MA |
5698 | # @device: display device to send event(s) to. |
5699 | # @head: head to send event(s) to, in case the | |
b98d26e3 | 5700 | # display device supports multiple scanouts. |
50c6617f MT |
5701 | # @events: List of InputEvent union. |
5702 | # | |
5703 | # Returns: Nothing on success. | |
5704 | # | |
70d5b0c2 MAL |
5705 | # The @device and @head parameters can be used to send the input event |
5706 | # to specific input devices in case (a) multiple input devices of the | |
5707 | # same kind are added to the virtual machine and (b) you have | |
b98d26e3 GH |
5708 | # configured input routing (see docs/multiseat.txt) for those input |
5709 | # devices. The parameters work exactly like the device and head | |
5710 | # properties of input devices. If @device is missing, only devices | |
5711 | # that have no input routing config are admissible. If @device is | |
5712 | # specified, both input devices with and without input routing config | |
5713 | # are admissible, but devices with input routing config take | |
5714 | # precedence. | |
df5b2adb | 5715 | # |
6575ccdd | 5716 | # Since: 2.6 |
70d5b0c2 MAL |
5717 | # |
5718 | # Note: The consoles are visible in the qom tree, under | |
5719 | # /backend/console[$index]. They have a device link and head property, | |
5720 | # so it is possible to map which console belongs to which device and | |
5721 | # display. | |
5722 | # | |
5723 | # Example: | |
5724 | # | |
5725 | # 1. Press left mouse button. | |
5726 | # | |
5727 | # -> { "execute": "input-send-event", | |
5728 | # "arguments": { "device": "video0", | |
5729 | # "events": [ { "type": "btn", | |
5730 | # "data" : { "down": true, "button": "left" } } ] } } | |
5731 | # <- { "return": {} } | |
5732 | # | |
5733 | # -> { "execute": "input-send-event", | |
5734 | # "arguments": { "device": "video0", | |
5735 | # "events": [ { "type": "btn", | |
5736 | # "data" : { "down": false, "button": "left" } } ] } } | |
5737 | # <- { "return": {} } | |
5738 | # | |
5739 | # 2. Press ctrl-alt-del. | |
5740 | # | |
5741 | # -> { "execute": "input-send-event", | |
5742 | # "arguments": { "events": [ | |
5743 | # { "type": "key", "data" : { "down": true, | |
5744 | # "key": {"type": "qcode", "data": "ctrl" } } }, | |
5745 | # { "type": "key", "data" : { "down": true, | |
5746 | # "key": {"type": "qcode", "data": "alt" } } }, | |
5747 | # { "type": "key", "data" : { "down": true, | |
5748 | # "key": {"type": "qcode", "data": "delete" } } } ] } } | |
5749 | # <- { "return": {} } | |
5750 | # | |
5751 | # 3. Move mouse pointer to absolute coordinates (20000, 400). | |
5752 | # | |
5753 | # -> { "execute": "input-send-event" , | |
5754 | # "arguments": { "events": [ | |
5755 | # { "type": "abs", "data" : { "axis": "x", "value" : 20000 } }, | |
5756 | # { "type": "abs", "data" : { "axis": "y", "value" : 400 } } ] } } | |
5757 | # <- { "return": {} } | |
5758 | # | |
50c6617f | 5759 | ## |
6575ccdd | 5760 | { 'command': 'input-send-event', |
b98d26e3 GH |
5761 | 'data': { '*device': 'str', |
5762 | '*head' : 'int', | |
5763 | 'events' : [ 'InputEvent' ] } } | |
50c6617f | 5764 | |
d081a49a MA |
5765 | ## |
5766 | # @NumaOptionsType: | |
5767 | # | |
0f203430 HC |
5768 | # @node: NUMA nodes configuration |
5769 | # | |
5770 | # @dist: NUMA distance configuration (since 2.10) | |
5771 | # | |
419fcdec IM |
5772 | # @cpu: property based CPU(s) to node mapping (Since: 2.10) |
5773 | # | |
d081a49a MA |
5774 | # Since: 2.1 |
5775 | ## | |
5776 | { 'enum': 'NumaOptionsType', | |
419fcdec | 5777 | 'data': [ 'node', 'dist', 'cpu' ] } |
d081a49a | 5778 | |
0042109a | 5779 | ## |
5072f7b3 | 5780 | # @NumaOptions: |
0042109a WG |
5781 | # |
5782 | # A discriminated record of NUMA options. (for OptsVisitor) | |
5783 | # | |
5072f7b3 | 5784 | # Since: 2.1 |
0042109a WG |
5785 | ## |
5786 | { 'union': 'NumaOptions', | |
d081a49a MA |
5787 | 'base': { 'type': 'NumaOptionsType' }, |
5788 | 'discriminator': 'type', | |
0042109a | 5789 | 'data': { |
0f203430 | 5790 | 'node': 'NumaNodeOptions', |
419fcdec IM |
5791 | 'dist': 'NumaDistOptions', |
5792 | 'cpu': 'NumaCpuOptions' }} | |
0042109a WG |
5793 | |
5794 | ## | |
5072f7b3 | 5795 | # @NumaNodeOptions: |
0042109a WG |
5796 | # |
5797 | # Create a guest NUMA node. (for OptsVisitor) | |
5798 | # | |
1d8bda12 | 5799 | # @nodeid: NUMA node ID (increase by 1 from 0 if omitted) |
0042109a | 5800 | # |
1d8bda12 | 5801 | # @cpus: VCPUs belonging to this node (assign VCPUS round-robin |
0042109a WG |
5802 | # if omitted) |
5803 | # | |
1d8bda12 | 5804 | # @mem: memory size of this node; mutually exclusive with @memdev. |
7febe36f PB |
5805 | # Equally divide total memory among nodes if both @mem and @memdev are |
5806 | # omitted. | |
5807 | # | |
1d8bda12 | 5808 | # @memdev: memory backend object. If specified for one node, |
7febe36f | 5809 | # it must be specified for all nodes. |
0042109a WG |
5810 | # |
5811 | # Since: 2.1 | |
5812 | ## | |
895a2a80 | 5813 | { 'struct': 'NumaNodeOptions', |
0042109a WG |
5814 | 'data': { |
5815 | '*nodeid': 'uint16', | |
5816 | '*cpus': ['uint16'], | |
7febe36f PB |
5817 | '*mem': 'size', |
5818 | '*memdev': 'str' }} | |
4cf1b76b | 5819 | |
0f203430 HC |
5820 | ## |
5821 | # @NumaDistOptions: | |
5822 | # | |
5823 | # Set the distance between 2 NUMA nodes. | |
5824 | # | |
5825 | # @src: source NUMA node. | |
5826 | # | |
5827 | # @dst: destination NUMA node. | |
5828 | # | |
5829 | # @val: NUMA distance from source node to destination node. | |
5830 | # When a node is unreachable from another node, set the distance | |
5831 | # between them to 255. | |
5832 | # | |
5833 | # Since: 2.10 | |
5834 | ## | |
5835 | { 'struct': 'NumaDistOptions', | |
5836 | 'data': { | |
5837 | 'src': 'uint16', | |
5838 | 'dst': 'uint16', | |
5839 | 'val': 'uint8' }} | |
5840 | ||
419fcdec IM |
5841 | ## |
5842 | # @NumaCpuOptions: | |
5843 | # | |
5844 | # Option "-numa cpu" overrides default cpu to node mapping. | |
5845 | # It accepts the same set of cpu properties as returned by | |
5846 | # query-hotpluggable-cpus[].props, where node-id could be used to | |
5847 | # override default node mapping. | |
5848 | # | |
5849 | # Since: 2.10 | |
5850 | ## | |
5851 | { 'struct': 'NumaCpuOptions', | |
5852 | 'base': 'CpuInstanceProperties', | |
5853 | 'data' : {} } | |
5854 | ||
4cf1b76b | 5855 | ## |
5072f7b3 | 5856 | # @HostMemPolicy: |
4cf1b76b HT |
5857 | # |
5858 | # Host memory policy types | |
5859 | # | |
5860 | # @default: restore default policy, remove any nondefault policy | |
5861 | # | |
5862 | # @preferred: set the preferred host nodes for allocation | |
5863 | # | |
5864 | # @bind: a strict policy that restricts memory allocation to the | |
5865 | # host nodes specified | |
5866 | # | |
5867 | # @interleave: memory allocations are interleaved across the set | |
5868 | # of host nodes specified | |
5869 | # | |
5072f7b3 | 5870 | # Since: 2.1 |
4cf1b76b HT |
5871 | ## |
5872 | { 'enum': 'HostMemPolicy', | |
5873 | 'data': [ 'default', 'preferred', 'bind', 'interleave' ] } | |
76b5d850 HT |
5874 | |
5875 | ## | |
5876 | # @Memdev: | |
5877 | # | |
8f4e5ac3 | 5878 | # Information about memory backend |
76b5d850 | 5879 | # |
1d8bda12 | 5880 | # @id: backend's ID if backend has 'id' property (since 2.9) |
e1ff3c67 | 5881 | # |
8f4e5ac3 | 5882 | # @size: memory backend size |
76b5d850 HT |
5883 | # |
5884 | # @merge: enables or disables memory merge support | |
5885 | # | |
8f4e5ac3 | 5886 | # @dump: includes memory backend's memory in a core dump or not |
76b5d850 HT |
5887 | # |
5888 | # @prealloc: enables or disables memory preallocation | |
5889 | # | |
5890 | # @host-nodes: host nodes for its memory policy | |
5891 | # | |
8f4e5ac3 | 5892 | # @policy: memory policy of memory backend |
76b5d850 HT |
5893 | # |
5894 | # Since: 2.1 | |
5895 | ## | |
895a2a80 | 5896 | { 'struct': 'Memdev', |
76b5d850 | 5897 | 'data': { |
e1ff3c67 | 5898 | '*id': 'str', |
76b5d850 HT |
5899 | 'size': 'size', |
5900 | 'merge': 'bool', | |
5901 | 'dump': 'bool', | |
5902 | 'prealloc': 'bool', | |
5903 | 'host-nodes': ['uint16'], | |
5904 | 'policy': 'HostMemPolicy' }} | |
5905 | ||
5906 | ## | |
5907 | # @query-memdev: | |
5908 | # | |
8f4e5ac3 | 5909 | # Returns information for all memory backends. |
76b5d850 HT |
5910 | # |
5911 | # Returns: a list of @Memdev. | |
5912 | # | |
5913 | # Since: 2.1 | |
cfc84c8b MAL |
5914 | # |
5915 | # Example: | |
5916 | # | |
5917 | # -> { "execute": "query-memdev" } | |
5918 | # <- { "return": [ | |
5919 | # { | |
5920 | # "id": "mem1", | |
5921 | # "size": 536870912, | |
5922 | # "merge": false, | |
5923 | # "dump": true, | |
5924 | # "prealloc": false, | |
5925 | # "host-nodes": [0, 1], | |
5926 | # "policy": "bind" | |
5927 | # }, | |
5928 | # { | |
5929 | # "size": 536870912, | |
5930 | # "merge": false, | |
5931 | # "dump": true, | |
5932 | # "prealloc": true, | |
5933 | # "host-nodes": [2, 3], | |
5934 | # "policy": "preferred" | |
5935 | # } | |
5936 | # ] | |
5937 | # } | |
5938 | # | |
76b5d850 HT |
5939 | ## |
5940 | { 'command': 'query-memdev', 'returns': ['Memdev'] } | |
8f4e5ac3 IM |
5941 | |
5942 | ## | |
6f2e2730 IM |
5943 | # @PCDIMMDeviceInfo: |
5944 | # | |
5945 | # PCDIMMDevice state information | |
5946 | # | |
1d8bda12 | 5947 | # @id: device's ID |
6f2e2730 IM |
5948 | # |
5949 | # @addr: physical address, where device is mapped | |
5950 | # | |
5951 | # @size: size of memory that the device provides | |
5952 | # | |
5953 | # @slot: slot number at which device is plugged in | |
5954 | # | |
5955 | # @node: NUMA node number where device is plugged in | |
5956 | # | |
5957 | # @memdev: memory backend linked with device | |
5958 | # | |
5959 | # @hotplugged: true if device was hotplugged | |
5960 | # | |
5961 | # @hotpluggable: true if device if could be added/removed while machine is running | |
5962 | # | |
5963 | # Since: 2.1 | |
5964 | ## | |
895a2a80 | 5965 | { 'struct': 'PCDIMMDeviceInfo', |
6f2e2730 IM |
5966 | 'data': { '*id': 'str', |
5967 | 'addr': 'int', | |
5968 | 'size': 'int', | |
5969 | 'slot': 'int', | |
5970 | 'node': 'int', | |
5971 | 'memdev': 'str', | |
5972 | 'hotplugged': 'bool', | |
5973 | 'hotpluggable': 'bool' | |
5974 | } | |
5975 | } | |
5976 | ||
5977 | ## | |
5978 | # @MemoryDeviceInfo: | |
5979 | # | |
5980 | # Union containing information about a memory device | |
5981 | # | |
5982 | # Since: 2.1 | |
5983 | ## | |
5984 | { 'union': 'MemoryDeviceInfo', 'data': {'dimm': 'PCDIMMDeviceInfo'} } | |
5985 | ||
5986 | ## | |
5072f7b3 | 5987 | # @query-memory-devices: |
6f2e2730 IM |
5988 | # |
5989 | # Lists available memory devices and their state | |
5990 | # | |
5991 | # Since: 2.1 | |
22f9a094 MAL |
5992 | # |
5993 | # Example: | |
5994 | # | |
5995 | # -> { "execute": "query-memory-devices" } | |
5996 | # <- { "return": [ { "data": | |
5997 | # { "addr": 5368709120, | |
5998 | # "hotpluggable": true, | |
5999 | # "hotplugged": true, | |
6000 | # "id": "d1", | |
6001 | # "memdev": "/objects/memX", | |
6002 | # "node": 0, | |
6003 | # "size": 1073741824, | |
6004 | # "slot": 0}, | |
6005 | # "type": "dimm" | |
6006 | # } ] } | |
6007 | # | |
6f2e2730 IM |
6008 | ## |
6009 | { 'command': 'query-memory-devices', 'returns': ['MemoryDeviceInfo'] } | |
521b3673 | 6010 | |
49687ace | 6011 | ## |
5072f7b3 | 6012 | # @ACPISlotType: |
521b3673 IM |
6013 | # |
6014 | # @DIMM: memory slot | |
76623d00 | 6015 | # @CPU: logical CPU slot (since 2.7) |
49687ace | 6016 | ## |
76623d00 | 6017 | { 'enum': 'ACPISlotType', 'data': [ 'DIMM', 'CPU' ] } |
521b3673 | 6018 | |
49687ace | 6019 | ## |
5072f7b3 | 6020 | # @ACPIOSTInfo: |
521b3673 IM |
6021 | # |
6022 | # OSPM Status Indication for a device | |
6023 | # For description of possible values of @source and @status fields | |
6024 | # see "_OST (OSPM Status Indication)" chapter of ACPI5.0 spec. | |
6025 | # | |
1d8bda12 | 6026 | # @device: device ID associated with slot |
521b3673 IM |
6027 | # |
6028 | # @slot: slot ID, unique per slot of a given @slot-type | |
6029 | # | |
6030 | # @slot-type: type of the slot | |
6031 | # | |
6032 | # @source: an integer containing the source event | |
6033 | # | |
6034 | # @status: an integer containing the status code | |
6035 | # | |
6036 | # Since: 2.1 | |
6037 | ## | |
895a2a80 | 6038 | { 'struct': 'ACPIOSTInfo', |
521b3673 IM |
6039 | 'data' : { '*device': 'str', |
6040 | 'slot': 'str', | |
6041 | 'slot-type': 'ACPISlotType', | |
6042 | 'source': 'int', | |
6043 | 'status': 'int' } } | |
02419bcb IM |
6044 | |
6045 | ## | |
5072f7b3 | 6046 | # @query-acpi-ospm-status: |
02419bcb | 6047 | # |
18b43003 MAL |
6048 | # Return a list of ACPIOSTInfo for devices that support status |
6049 | # reporting via ACPI _OST method. | |
02419bcb IM |
6050 | # |
6051 | # Since: 2.1 | |
18b43003 MAL |
6052 | # |
6053 | # Example: | |
6054 | # | |
6055 | # -> { "execute": "query-acpi-ospm-status" } | |
6056 | # <- { "return": [ { "device": "d1", "slot": "0", "slot-type": "DIMM", "source": 1, "status": 0}, | |
6057 | # { "slot": "1", "slot-type": "DIMM", "source": 0, "status": 0}, | |
6058 | # { "slot": "2", "slot-type": "DIMM", "source": 0, "status": 0}, | |
6059 | # { "slot": "3", "slot-type": "DIMM", "source": 0, "status": 0} | |
6060 | # ]} | |
6061 | # | |
02419bcb IM |
6062 | ## |
6063 | { 'command': 'query-acpi-ospm-status', 'returns': ['ACPIOSTInfo'] } | |
f668470f | 6064 | |
99eaf09c | 6065 | ## |
5072f7b3 | 6066 | # @WatchdogExpirationAction: |
99eaf09c WX |
6067 | # |
6068 | # An enumeration of the actions taken when the watchdog device's timer is | |
6069 | # expired | |
6070 | # | |
6071 | # @reset: system resets | |
6072 | # | |
6073 | # @shutdown: system shutdown, note that it is similar to @powerdown, which | |
6074 | # tries to set to system status and notify guest | |
6075 | # | |
6076 | # @poweroff: system poweroff, the emulator program exits | |
6077 | # | |
6078 | # @pause: system pauses, similar to @stop | |
6079 | # | |
6080 | # @debug: system enters debug state | |
6081 | # | |
6082 | # @none: nothing is done | |
6083 | # | |
795dc6e4 MCL |
6084 | # @inject-nmi: a non-maskable interrupt is injected into the first VCPU (all |
6085 | # VCPUS on x86) (since 2.4) | |
6086 | # | |
99eaf09c WX |
6087 | # Since: 2.1 |
6088 | ## | |
6089 | { 'enum': 'WatchdogExpirationAction', | |
795dc6e4 MCL |
6090 | 'data': [ 'reset', 'shutdown', 'poweroff', 'pause', 'debug', 'none', |
6091 | 'inject-nmi' ] } | |
99eaf09c | 6092 | |
5a2d2cbd | 6093 | ## |
5072f7b3 | 6094 | # @IoOperationType: |
5a2d2cbd WX |
6095 | # |
6096 | # An enumeration of the I/O operation types | |
6097 | # | |
6098 | # @read: read operation | |
6099 | # | |
6100 | # @write: write operation | |
6101 | # | |
6102 | # Since: 2.1 | |
6103 | ## | |
6104 | { 'enum': 'IoOperationType', | |
6105 | 'data': [ 'read', 'write' ] } | |
6106 | ||
3a449690 | 6107 | ## |
5072f7b3 | 6108 | # @GuestPanicAction: |
3a449690 WX |
6109 | # |
6110 | # An enumeration of the actions taken when guest OS panic is detected | |
6111 | # | |
6112 | # @pause: system pauses | |
6113 | # | |
864111f4 | 6114 | # Since: 2.1 (poweroff since 2.8) |
3a449690 WX |
6115 | ## |
6116 | { 'enum': 'GuestPanicAction', | |
864111f4 | 6117 | 'data': [ 'pause', 'poweroff' ] } |
f2ae8abf | 6118 | |
e8ed97a6 AN |
6119 | ## |
6120 | # @GuestPanicInformationType: | |
6121 | # | |
6122 | # An enumeration of the guest panic information types | |
6123 | # | |
6124 | # Since: 2.9 | |
6125 | ## | |
6126 | { 'enum': 'GuestPanicInformationType', | |
6127 | 'data': [ 'hyper-v'] } | |
6128 | ||
d187e08d AN |
6129 | ## |
6130 | # @GuestPanicInformation: | |
6131 | # | |
6132 | # Information about a guest panic | |
6133 | # | |
6134 | # Since: 2.9 | |
6135 | ## | |
6136 | {'union': 'GuestPanicInformation', | |
e8ed97a6 AN |
6137 | 'base': {'type': 'GuestPanicInformationType'}, |
6138 | 'discriminator': 'type', | |
d187e08d AN |
6139 | 'data': { 'hyper-v': 'GuestPanicInformationHyperV' } } |
6140 | ||
6141 | ## | |
6142 | # @GuestPanicInformationHyperV: | |
6143 | # | |
6144 | # Hyper-V specific guest panic information (HV crash MSRs) | |
6145 | # | |
6146 | # Since: 2.9 | |
6147 | ## | |
6148 | {'struct': 'GuestPanicInformationHyperV', | |
6149 | 'data': { 'arg1': 'uint64', | |
6150 | 'arg2': 'uint64', | |
6151 | 'arg3': 'uint64', | |
6152 | 'arg4': 'uint64', | |
6153 | 'arg5': 'uint64' } } | |
6154 | ||
f2ae8abf | 6155 | ## |
5072f7b3 | 6156 | # @rtc-reset-reinjection: |
f2ae8abf MT |
6157 | # |
6158 | # This command will reset the RTC interrupt reinjection backlog. | |
6159 | # Can be used if another mechanism to synchronize guest time | |
6160 | # is in effect, for example QEMU guest agent's guest-set-time | |
6161 | # command. | |
6162 | # | |
6163 | # Since: 2.1 | |
5c32b4cc MAL |
6164 | # |
6165 | # Example: | |
6166 | # | |
6167 | # -> { "execute": "rtc-reset-reinjection" } | |
6168 | # <- { "return": {} } | |
6169 | # | |
f2ae8abf MT |
6170 | ## |
6171 | { 'command': 'rtc-reset-reinjection' } | |
fafa4d50 SF |
6172 | |
6173 | # Rocker ethernet network switch | |
6174 | { 'include': 'qapi/rocker.json' } | |
d73abd6d PD |
6175 | |
6176 | ## | |
c5927e7a | 6177 | # @ReplayMode: |
d73abd6d PD |
6178 | # |
6179 | # Mode of the replay subsystem. | |
6180 | # | |
6181 | # @none: normal execution mode. Replay or record are not enabled. | |
6182 | # | |
6183 | # @record: record mode. All non-deterministic data is written into the | |
6184 | # replay log. | |
6185 | # | |
6186 | # @play: replay mode. Non-deterministic data required for system execution | |
6187 | # is read from the log. | |
6188 | # | |
6189 | # Since: 2.5 | |
6190 | ## | |
6191 | { 'enum': 'ReplayMode', | |
6192 | 'data': [ 'none', 'record', 'play' ] } | |
ae50a770 | 6193 | |
88c16567 WC |
6194 | ## |
6195 | # @xen-load-devices-state: | |
6196 | # | |
6197 | # Load the state of all devices from file. The RAM and the block devices | |
6198 | # of the VM are not loaded by this command. | |
6199 | # | |
6200 | # @filename: the file to load the state of the devices from as binary | |
6201 | # data. See xen-save-devices-state.txt for a description of the binary | |
6202 | # format. | |
6203 | # | |
6204 | # Since: 2.7 | |
7d1182d9 MAL |
6205 | # |
6206 | # Example: | |
6207 | # | |
6208 | # -> { "execute": "xen-load-devices-state", | |
6209 | # "arguments": { "filename": "/tmp/resume" } } | |
6210 | # <- { "return": {} } | |
6211 | # | |
88c16567 WC |
6212 | ## |
6213 | { 'command': 'xen-load-devices-state', 'data': {'filename': 'str'} } | |
6214 | ||
2c9639ec ZC |
6215 | ## |
6216 | # @xen-set-replication: | |
6217 | # | |
6218 | # Enable or disable replication. | |
6219 | # | |
6220 | # @enable: true to enable, false to disable. | |
6221 | # | |
6222 | # @primary: true for primary or false for secondary. | |
6223 | # | |
1d8bda12 | 6224 | # @failover: true to do failover, false to stop. but cannot be |
2c9639ec ZC |
6225 | # specified if 'enable' is true. default value is false. |
6226 | # | |
6227 | # Returns: nothing. | |
6228 | # | |
6229 | # Example: | |
6230 | # | |
6231 | # -> { "execute": "xen-set-replication", | |
6232 | # "arguments": {"enable": true, "primary": false} } | |
6233 | # <- { "return": {} } | |
6234 | # | |
6235 | # Since: 2.9 | |
6236 | ## | |
6237 | { 'command': 'xen-set-replication', | |
6238 | 'data': { 'enable': 'bool', 'primary': 'bool', '*failover' : 'bool' } } | |
6239 | ||
daa33c52 ZC |
6240 | ## |
6241 | # @ReplicationStatus: | |
6242 | # | |
6243 | # The result format for 'query-xen-replication-status'. | |
6244 | # | |
6245 | # @error: true if an error happened, false if replication is normal. | |
6246 | # | |
1d8bda12 | 6247 | # @desc: the human readable error description string, when |
daa33c52 ZC |
6248 | # @error is 'true'. |
6249 | # | |
6250 | # Since: 2.9 | |
6251 | ## | |
6252 | { 'struct': 'ReplicationStatus', | |
6253 | 'data': { 'error': 'bool', '*desc': 'str' } } | |
6254 | ||
6255 | ## | |
6256 | # @query-xen-replication-status: | |
6257 | # | |
6258 | # Query replication status while the vm is running. | |
6259 | # | |
6260 | # Returns: A @ReplicationResult object showing the status. | |
6261 | # | |
6262 | # Example: | |
6263 | # | |
6264 | # -> { "execute": "query-xen-replication-status" } | |
6265 | # <- { "return": { "error": false } } | |
6266 | # | |
6267 | # Since: 2.9 | |
6268 | ## | |
6269 | { 'command': 'query-xen-replication-status', | |
6270 | 'returns': 'ReplicationStatus' } | |
6271 | ||
6272 | ## | |
6273 | # @xen-colo-do-checkpoint: | |
6274 | # | |
6275 | # Xen uses this command to notify replication to trigger a checkpoint. | |
6276 | # | |
6277 | # Returns: nothing. | |
6278 | # | |
6279 | # Example: | |
6280 | # | |
6281 | # -> { "execute": "xen-colo-do-checkpoint" } | |
6282 | # <- { "return": {} } | |
6283 | # | |
6284 | # Since: 2.9 | |
6285 | ## | |
6286 | { 'command': 'xen-colo-do-checkpoint' } | |
6287 | ||
ae50a770 PX |
6288 | ## |
6289 | # @GICCapability: | |
6290 | # | |
6291 | # The struct describes capability for a specific GIC (Generic | |
6292 | # Interrupt Controller) version. These bits are not only decided by | |
6293 | # QEMU/KVM software version, but also decided by the hardware that | |
6294 | # the program is running upon. | |
6295 | # | |
6296 | # @version: version of GIC to be described. Currently, only 2 and 3 | |
6297 | # are supported. | |
6298 | # | |
6299 | # @emulated: whether current QEMU/hardware supports emulated GIC | |
6300 | # device in user space. | |
6301 | # | |
6302 | # @kernel: whether current QEMU/hardware supports hardware | |
6303 | # accelerated GIC device in kernel. | |
6304 | # | |
6305 | # Since: 2.6 | |
6306 | ## | |
6307 | { 'struct': 'GICCapability', | |
6308 | 'data': { 'version': 'int', | |
6309 | 'emulated': 'bool', | |
6310 | 'kernel': 'bool' } } | |
6311 | ||
6312 | ## | |
6313 | # @query-gic-capabilities: | |
6314 | # | |
6315 | # This command is ARM-only. It will return a list of GICCapability | |
6316 | # objects that describe its capability bits. | |
6317 | # | |
6318 | # Returns: a list of GICCapability objects. | |
6319 | # | |
6320 | # Since: 2.6 | |
1965e98d MAL |
6321 | # |
6322 | # Example: | |
6323 | # | |
6324 | # -> { "execute": "query-gic-capabilities" } | |
6325 | # <- { "return": [{ "version": 2, "emulated": true, "kernel": false }, | |
6326 | # { "version": 3, "emulated": false, "kernel": true } ] } | |
6327 | # | |
ae50a770 PX |
6328 | ## |
6329 | { 'command': 'query-gic-capabilities', 'returns': ['GICCapability'] } | |
d4633541 IM |
6330 | |
6331 | ## | |
5072f7b3 | 6332 | # @CpuInstanceProperties: |
d4633541 IM |
6333 | # |
6334 | # List of properties to be used for hotplugging a CPU instance, | |
6335 | # it should be passed by management with device_add command when | |
6336 | # a CPU is being hotplugged. | |
6337 | # | |
1d8bda12 MA |
6338 | # @node-id: NUMA node ID the CPU belongs to |
6339 | # @socket-id: socket number within node/board the CPU belongs to | |
6340 | # @core-id: core number within socket the CPU belongs to | |
6341 | # @thread-id: thread number within core the CPU belongs to | |
5807ff88 | 6342 | # |
d4633541 IM |
6343 | # Note: currently there are 4 properties that could be present |
6344 | # but management should be prepared to pass through other | |
6345 | # properties with device_add command to allow for future | |
27393c33 PK |
6346 | # interface extension. This also requires the filed names to be kept in |
6347 | # sync with the properties passed to -device/device_add. | |
d4633541 | 6348 | # |
d4633541 IM |
6349 | # Since: 2.7 |
6350 | ## | |
6351 | { 'struct': 'CpuInstanceProperties', | |
27393c33 PK |
6352 | 'data': { '*node-id': 'int', |
6353 | '*socket-id': 'int', | |
6354 | '*core-id': 'int', | |
6355 | '*thread-id': 'int' | |
d4633541 IM |
6356 | } |
6357 | } | |
6358 | ||
6359 | ## | |
5072f7b3 | 6360 | # @HotpluggableCPU: |
d4633541 IM |
6361 | # |
6362 | # @type: CPU object type for usage with device_add command | |
6363 | # @props: list of properties to be used for hotplugging CPU | |
6364 | # @vcpus-count: number of logical VCPU threads @HotpluggableCPU provides | |
1d8bda12 | 6365 | # @qom-path: link to existing CPU object if CPU is present or |
d4633541 IM |
6366 | # omitted if CPU is not present. |
6367 | # | |
6368 | # Since: 2.7 | |
6369 | ## | |
6370 | { 'struct': 'HotpluggableCPU', | |
6371 | 'data': { 'type': 'str', | |
6372 | 'vcpus-count': 'int', | |
6373 | 'props': 'CpuInstanceProperties', | |
6374 | '*qom-path': 'str' | |
6375 | } | |
6376 | } | |
6377 | ||
6378 | ## | |
5072f7b3 | 6379 | # @query-hotpluggable-cpus: |
d4633541 IM |
6380 | # |
6381 | # Returns: a list of HotpluggableCPU objects. | |
6382 | # | |
6383 | # Since: 2.7 | |
7e31d1ae MAL |
6384 | # |
6385 | # Example: | |
6386 | # | |
6387 | # For pseries machine type started with -smp 2,cores=2,maxcpus=4 -cpu POWER8: | |
6388 | # | |
6389 | # -> { "execute": "query-hotpluggable-cpus" } | |
6390 | # <- {"return": [ | |
6391 | # { "props": { "core": 8 }, "type": "POWER8-spapr-cpu-core", | |
6392 | # "vcpus-count": 1 }, | |
6393 | # { "props": { "core": 0 }, "type": "POWER8-spapr-cpu-core", | |
6394 | # "vcpus-count": 1, "qom-path": "/machine/unattached/device[0]"} | |
6395 | # ]}' | |
6396 | # | |
6397 | # For pc machine type started with -smp 1,maxcpus=2: | |
6398 | # | |
6399 | # -> { "execute": "query-hotpluggable-cpus" } | |
6400 | # <- {"return": [ | |
6401 | # { | |
6402 | # "type": "qemu64-x86_64-cpu", "vcpus-count": 1, | |
6403 | # "props": {"core-id": 0, "socket-id": 1, "thread-id": 0} | |
6404 | # }, | |
6405 | # { | |
6406 | # "qom-path": "/machine/unattached/device[0]", | |
6407 | # "type": "qemu64-x86_64-cpu", "vcpus-count": 1, | |
6408 | # "props": {"core-id": 0, "socket-id": 0, "thread-id": 0} | |
6409 | # } | |
6410 | # ]} | |
6411 | # | |
d4633541 IM |
6412 | ## |
6413 | { 'command': 'query-hotpluggable-cpus', 'returns': ['HotpluggableCPU'] } | |
39164c13 IM |
6414 | |
6415 | ## | |
6416 | # @GuidInfo: | |
6417 | # | |
6418 | # GUID information. | |
6419 | # | |
6420 | # @guid: the globally unique identifier | |
6421 | # | |
6422 | # Since: 2.9 | |
6423 | ## | |
6424 | { 'struct': 'GuidInfo', 'data': {'guid': 'str'} } | |
6425 | ||
6426 | ## | |
6427 | # @query-vm-generation-id: | |
6428 | # | |
6429 | # Show Virtual Machine Generation ID | |
6430 | # | |
6431 | # Since 2.9 | |
6432 | ## | |
6433 | { 'command': 'query-vm-generation-id', 'returns': 'GuidInfo' } |