xref: /openbmc/qemu/qapi/machine.json (revision 53c7c924)
1# -*- Mode: Python -*-
2# vim: filetype=python
3#
4# This work is licensed under the terms of the GNU GPL, version 2 or later.
5# See the COPYING file in the top-level directory.
6
7##
8# = Machines
9##
10
11{ 'include': 'common.json' }
12
13##
14# @SysEmuTarget:
15#
16# The comprehensive enumeration of QEMU system emulation ("softmmu")
17# targets.  Run "./configure --help" in the project root directory,
18# and look for the \*-softmmu targets near the "--target-list" option.
19# The individual target constants are not documented here, for the
20# time being.
21#
22# @rx: since 5.0
23#
24# @avr: since 5.1
25#
26# Notes: The resulting QMP strings can be appended to the
27#     "qemu-system-" prefix to produce the corresponding QEMU
28#     executable name.  This is true even for "qemu-system-x86_64".
29#
30# Since: 3.0
31##
32{ 'enum' : 'SysEmuTarget',
33  'data' : [ 'aarch64', 'alpha', 'arm', 'avr', 'cris', 'hppa', 'i386',
34             'loongarch64', 'm68k', 'microblaze', 'microblazeel', 'mips', 'mips64',
35             'mips64el', 'mipsel', 'nios2', 'or1k', 'ppc',
36             'ppc64', 'riscv32', 'riscv64', 'rx', 's390x', 'sh4',
37             'sh4eb', 'sparc', 'sparc64', 'tricore',
38             'x86_64', 'xtensa', 'xtensaeb' ] }
39
40##
41# @CpuS390State:
42#
43# An enumeration of cpu states that can be assumed by a virtual S390
44# CPU
45#
46# Since: 2.12
47##
48{ 'enum': 'CpuS390State',
49  'prefix': 'S390_CPU_STATE',
50  'data': [ 'uninitialized', 'stopped', 'check-stop', 'operating', 'load' ] }
51
52##
53# @CpuInfoS390:
54#
55# Additional information about a virtual S390 CPU
56#
57# @cpu-state: the virtual CPU's state
58#
59# Since: 2.12
60##
61{ 'struct': 'CpuInfoS390', 'data': { 'cpu-state': 'CpuS390State' } }
62
63##
64# @CpuInfoFast:
65#
66# Information about a virtual CPU
67#
68# @cpu-index: index of the virtual CPU
69#
70# @qom-path: path to the CPU object in the QOM tree
71#
72# @thread-id: ID of the underlying host thread
73#
74# @props: properties describing to which node/socket/core/thread
75#     virtual CPU belongs to, provided if supported by board
76#
77# @target: the QEMU system emulation target, which determines which
78#     additional fields will be listed (since 3.0)
79#
80# Since: 2.12
81##
82{ 'union'         : 'CpuInfoFast',
83  'base'          : { 'cpu-index'    : 'int',
84                      'qom-path'     : 'str',
85                      'thread-id'    : 'int',
86                      '*props'       : 'CpuInstanceProperties',
87                      'target'       : 'SysEmuTarget' },
88  'discriminator' : 'target',
89  'data'          : { 's390x'        : 'CpuInfoS390' } }
90
91##
92# @query-cpus-fast:
93#
94# Returns information about all virtual CPUs.
95#
96# Returns: list of @CpuInfoFast
97#
98# Since: 2.12
99#
100# Example:
101#
102# -> { "execute": "query-cpus-fast" }
103# <- { "return": [
104#         {
105#             "thread-id": 25627,
106#             "props": {
107#                 "core-id": 0,
108#                 "thread-id": 0,
109#                 "socket-id": 0
110#             },
111#             "qom-path": "/machine/unattached/device[0]",
112#             "target":"x86_64",
113#             "cpu-index": 0
114#         },
115#         {
116#             "thread-id": 25628,
117#             "props": {
118#                 "core-id": 0,
119#                 "thread-id": 0,
120#                 "socket-id": 1
121#             },
122#             "qom-path": "/machine/unattached/device[2]",
123#             "target":"x86_64",
124#             "cpu-index": 1
125#         }
126#     ]
127# }
128##
129{ 'command': 'query-cpus-fast', 'returns': [ 'CpuInfoFast' ] }
130
131##
132# @MachineInfo:
133#
134# Information describing a machine.
135#
136# @name: the name of the machine
137#
138# @alias: an alias for the machine name
139#
140# @is-default: whether the machine is default
141#
142# @cpu-max: maximum number of CPUs supported by the machine type
143#     (since 1.5)
144#
145# @hotpluggable-cpus: cpu hotplug via -device is supported (since 2.7)
146#
147# @numa-mem-supported: true if '-numa node,mem' option is supported by
148#     the machine type and false otherwise (since 4.1)
149#
150# @deprecated: if true, the machine type is deprecated and may be
151#     removed in future versions of QEMU according to the QEMU
152#     deprecation policy (since 4.1)
153#
154# @default-cpu-type: default CPU model typename if none is requested
155#     via the -cpu argument.  (since 4.2)
156#
157# @default-ram-id: the default ID of initial RAM memory backend (since
158#     5.2)
159#
160# @acpi: machine type supports ACPI (since 8.0)
161#
162# Since: 1.2
163##
164{ 'struct': 'MachineInfo',
165  'data': { 'name': 'str', '*alias': 'str',
166            '*is-default': 'bool', 'cpu-max': 'int',
167            'hotpluggable-cpus': 'bool',  'numa-mem-supported': 'bool',
168            'deprecated': 'bool', '*default-cpu-type': 'str',
169            '*default-ram-id': 'str', 'acpi': 'bool' } }
170
171##
172# @query-machines:
173#
174# Return a list of supported machines
175#
176# Returns: a list of MachineInfo
177#
178# Since: 1.2
179##
180{ 'command': 'query-machines', 'returns': ['MachineInfo'] }
181
182##
183# @CurrentMachineParams:
184#
185# Information describing the running machine parameters.
186#
187# @wakeup-suspend-support: true if the machine supports wake up from
188#     suspend
189#
190# Since: 4.0
191##
192{ 'struct': 'CurrentMachineParams',
193  'data': { 'wakeup-suspend-support': 'bool'} }
194
195##
196# @query-current-machine:
197#
198# Return information on the current virtual machine.
199#
200# Returns: CurrentMachineParams
201#
202# Since: 4.0
203##
204{ 'command': 'query-current-machine', 'returns': 'CurrentMachineParams' }
205
206##
207# @TargetInfo:
208#
209# Information describing the QEMU target.
210#
211# @arch: the target architecture
212#
213# Since: 1.2
214##
215{ 'struct': 'TargetInfo',
216  'data': { 'arch': 'SysEmuTarget' } }
217
218##
219# @query-target:
220#
221# Return information about the target for this QEMU
222#
223# Returns: TargetInfo
224#
225# Since: 1.2
226##
227{ 'command': 'query-target', 'returns': 'TargetInfo' }
228
229##
230# @UuidInfo:
231#
232# Guest UUID information (Universally Unique Identifier).
233#
234# @UUID: the UUID of the guest
235#
236# Since: 0.14
237#
238# Notes: If no UUID was specified for the guest, a null UUID is
239#     returned.
240##
241{ 'struct': 'UuidInfo', 'data': {'UUID': 'str'} }
242
243##
244# @query-uuid:
245#
246# Query the guest UUID information.
247#
248# Returns: The @UuidInfo for the guest
249#
250# Since: 0.14
251#
252# Example:
253#
254# -> { "execute": "query-uuid" }
255# <- { "return": { "UUID": "550e8400-e29b-41d4-a716-446655440000" } }
256##
257{ 'command': 'query-uuid', 'returns': 'UuidInfo', 'allow-preconfig': true }
258
259##
260# @GuidInfo:
261#
262# GUID information.
263#
264# @guid: the globally unique identifier
265#
266# Since: 2.9
267##
268{ 'struct': 'GuidInfo', 'data': {'guid': 'str'} }
269
270##
271# @query-vm-generation-id:
272#
273# Show Virtual Machine Generation ID
274#
275# Since: 2.9
276##
277{ 'command': 'query-vm-generation-id', 'returns': 'GuidInfo' }
278
279##
280# @system_reset:
281#
282# Performs a hard reset of a guest.
283#
284# Since: 0.14
285#
286# Example:
287#
288# -> { "execute": "system_reset" }
289# <- { "return": {} }
290##
291{ 'command': 'system_reset' }
292
293##
294# @system_powerdown:
295#
296# Requests that a guest perform a powerdown operation.
297#
298# Since: 0.14
299#
300# Notes: A guest may or may not respond to this command.  This command
301#     returning does not indicate that a guest has accepted the
302#     request or that it has shut down.  Many guests will respond to
303#     this command by prompting the user in some way.
304#
305# Example:
306#
307# -> { "execute": "system_powerdown" }
308# <- { "return": {} }
309##
310{ 'command': 'system_powerdown' }
311
312##
313# @system_wakeup:
314#
315# Wake up guest from suspend.  If the guest has wake-up from suspend
316# support enabled (wakeup-suspend-support flag from
317# query-current-machine), wake-up guest from suspend if the guest is
318# in SUSPENDED state.  Return an error otherwise.
319#
320# Since: 1.1
321#
322# Returns: nothing.
323#
324# Note: prior to 4.0, this command does nothing in case the guest
325#     isn't suspended.
326#
327# Example:
328#
329# -> { "execute": "system_wakeup" }
330# <- { "return": {} }
331##
332{ 'command': 'system_wakeup' }
333
334##
335# @LostTickPolicy:
336#
337# Policy for handling lost ticks in timer devices.  Ticks end up
338# getting lost when, for example, the guest is paused.
339#
340# @discard: throw away the missed ticks and continue with future
341#     injection normally.  The guest OS will see the timer jump ahead
342#     by a potentially quite significant amount all at once, as if the
343#     intervening chunk of time had simply not existed; needless to
344#     say, such a sudden jump can easily confuse a guest OS which is
345#     not specifically prepared to deal with it.  Assuming the guest
346#     OS can deal correctly with the time jump, the time in the guest
347#     and in the host should now match.
348#
349# @delay: continue to deliver ticks at the normal rate.  The guest OS
350#     will not notice anything is amiss, as from its point of view
351#     time will have continued to flow normally.  The time in the
352#     guest should now be behind the time in the host by exactly the
353#     amount of time during which ticks have been missed.
354#
355# @slew: deliver ticks at a higher rate to catch up with the missed
356#     ticks.  The guest OS will not notice anything is amiss, as from
357#     its point of view time will have continued to flow normally.
358#     Once the timer has managed to catch up with all the missing
359#     ticks, the time in the guest and in the host should match.
360#
361# Since: 2.0
362##
363{ 'enum': 'LostTickPolicy',
364  'data': ['discard', 'delay', 'slew' ] }
365
366##
367# @inject-nmi:
368#
369# Injects a Non-Maskable Interrupt into the default CPU (x86/s390) or
370# all CPUs (ppc64). The command fails when the guest doesn't support
371# injecting.
372#
373# Returns: If successful, nothing
374#
375# Since: 0.14
376#
377# Note: prior to 2.1, this command was only supported for x86 and s390
378#     VMs
379#
380# Example:
381#
382# -> { "execute": "inject-nmi" }
383# <- { "return": {} }
384##
385{ 'command': 'inject-nmi' }
386
387##
388# @KvmInfo:
389#
390# Information about support for KVM acceleration
391#
392# @enabled: true if KVM acceleration is active
393#
394# @present: true if KVM acceleration is built into this executable
395#
396# Since: 0.14
397##
398{ 'struct': 'KvmInfo', 'data': {'enabled': 'bool', 'present': 'bool'} }
399
400##
401# @query-kvm:
402#
403# Returns information about KVM acceleration
404#
405# Returns: @KvmInfo
406#
407# Since: 0.14
408#
409# Example:
410#
411# -> { "execute": "query-kvm" }
412# <- { "return": { "enabled": true, "present": true } }
413##
414{ 'command': 'query-kvm', 'returns': 'KvmInfo' }
415
416##
417# @NumaOptionsType:
418#
419# @node: NUMA nodes configuration
420#
421# @dist: NUMA distance configuration (since 2.10)
422#
423# @cpu: property based CPU(s) to node mapping (Since: 2.10)
424#
425# @hmat-lb: memory latency and bandwidth information (Since: 5.0)
426#
427# @hmat-cache: memory side cache information (Since: 5.0)
428#
429# Since: 2.1
430##
431{ 'enum': 'NumaOptionsType',
432  'data': [ 'node', 'dist', 'cpu', 'hmat-lb', 'hmat-cache' ] }
433
434##
435# @NumaOptions:
436#
437# A discriminated record of NUMA options.  (for OptsVisitor)
438#
439# Since: 2.1
440##
441{ 'union': 'NumaOptions',
442  'base': { 'type': 'NumaOptionsType' },
443  'discriminator': 'type',
444  'data': {
445    'node': 'NumaNodeOptions',
446    'dist': 'NumaDistOptions',
447    'cpu': 'NumaCpuOptions',
448    'hmat-lb': 'NumaHmatLBOptions',
449    'hmat-cache': 'NumaHmatCacheOptions' }}
450
451##
452# @NumaNodeOptions:
453#
454# Create a guest NUMA node.  (for OptsVisitor)
455#
456# @nodeid: NUMA node ID (increase by 1 from 0 if omitted)
457#
458# @cpus: VCPUs belonging to this node (assign VCPUS round-robin if
459#     omitted)
460#
461# @mem: memory size of this node; mutually exclusive with @memdev.
462#     Equally divide total memory among nodes if both @mem and @memdev
463#     are omitted.
464#
465# @memdev: memory backend object.  If specified for one node, it must
466#     be specified for all nodes.
467#
468# @initiator: defined in ACPI 6.3 Chapter 5.2.27.3 Table 5-145, points
469#     to the nodeid which has the memory controller responsible for
470#     this NUMA node.  This field provides additional information as
471#     to the initiator node that is closest (as in directly attached)
472#     to this node, and therefore has the best performance (since 5.0)
473#
474# Since: 2.1
475##
476{ 'struct': 'NumaNodeOptions',
477  'data': {
478   '*nodeid': 'uint16',
479   '*cpus':   ['uint16'],
480   '*mem':    'size',
481   '*memdev': 'str',
482   '*initiator': 'uint16' }}
483
484##
485# @NumaDistOptions:
486#
487# Set the distance between 2 NUMA nodes.
488#
489# @src: source NUMA node.
490#
491# @dst: destination NUMA node.
492#
493# @val: NUMA distance from source node to destination node.  When a
494#     node is unreachable from another node, set the distance between
495#     them to 255.
496#
497# Since: 2.10
498##
499{ 'struct': 'NumaDistOptions',
500  'data': {
501   'src': 'uint16',
502   'dst': 'uint16',
503   'val': 'uint8' }}
504
505##
506# @CXLFixedMemoryWindowOptions:
507#
508# Create a CXL Fixed Memory Window
509#
510# @size: Size of the Fixed Memory Window in bytes.  Must be a multiple
511#     of 256MiB.
512#
513# @interleave-granularity: Number of contiguous bytes for which
514#     accesses will go to a given interleave target.  Accepted values
515#     [256, 512, 1k, 2k, 4k, 8k, 16k]
516#
517# @targets: Target root bridge IDs from -device ...,id=<ID> for each
518#     root bridge.
519#
520# Since: 7.1
521##
522{ 'struct': 'CXLFixedMemoryWindowOptions',
523  'data': {
524      'size': 'size',
525      '*interleave-granularity': 'size',
526      'targets': ['str'] }}
527
528##
529# @CXLFMWProperties:
530#
531# List of CXL Fixed Memory Windows.
532#
533# @cxl-fmw: List of CXLFixedMemoryWindowOptions
534#
535# Since: 7.1
536##
537{ 'struct' : 'CXLFMWProperties',
538  'data': { 'cxl-fmw': ['CXLFixedMemoryWindowOptions'] }
539}
540
541##
542# @X86CPURegister32:
543#
544# A X86 32-bit register
545#
546# Since: 1.5
547##
548{ 'enum': 'X86CPURegister32',
549  'data': [ 'EAX', 'EBX', 'ECX', 'EDX', 'ESP', 'EBP', 'ESI', 'EDI' ] }
550
551##
552# @X86CPUFeatureWordInfo:
553#
554# Information about a X86 CPU feature word
555#
556# @cpuid-input-eax: Input EAX value for CPUID instruction for that
557#     feature word
558#
559# @cpuid-input-ecx: Input ECX value for CPUID instruction for that
560#     feature word
561#
562# @cpuid-register: Output register containing the feature bits
563#
564# @features: value of output register, containing the feature bits
565#
566# Since: 1.5
567##
568{ 'struct': 'X86CPUFeatureWordInfo',
569  'data': { 'cpuid-input-eax': 'int',
570            '*cpuid-input-ecx': 'int',
571            'cpuid-register': 'X86CPURegister32',
572            'features': 'int' } }
573
574##
575# @DummyForceArrays:
576#
577# Not used by QMP; hack to let us use X86CPUFeatureWordInfoList
578# internally
579#
580# Since: 2.5
581##
582{ 'struct': 'DummyForceArrays',
583  'data': { 'unused': ['X86CPUFeatureWordInfo'] } }
584
585##
586# @NumaCpuOptions:
587#
588# Option "-numa cpu" overrides default cpu to node mapping.  It
589# accepts the same set of cpu properties as returned by
590# query-hotpluggable-cpus[].props, where node-id could be used to
591# override default node mapping.
592#
593# Since: 2.10
594##
595{ 'struct': 'NumaCpuOptions',
596   'base': 'CpuInstanceProperties',
597   'data' : {} }
598
599##
600# @HmatLBMemoryHierarchy:
601#
602# The memory hierarchy in the System Locality Latency and Bandwidth
603# Information Structure of HMAT (Heterogeneous Memory Attribute Table)
604#
605# For more information about @HmatLBMemoryHierarchy, see chapter
606# 5.2.27.4: Table 5-146: Field "Flags" of ACPI 6.3 spec.
607#
608# @memory: the structure represents the memory performance
609#
610# @first-level: first level of memory side cache
611#
612# @second-level: second level of memory side cache
613#
614# @third-level: third level of memory side cache
615#
616# Since: 5.0
617##
618{ 'enum': 'HmatLBMemoryHierarchy',
619  'data': [ 'memory', 'first-level', 'second-level', 'third-level' ] }
620
621##
622# @HmatLBDataType:
623#
624# Data type in the System Locality Latency and Bandwidth Information
625# Structure of HMAT (Heterogeneous Memory Attribute Table)
626#
627# For more information about @HmatLBDataType, see chapter 5.2.27.4:
628# Table 5-146:  Field "Data Type" of ACPI 6.3 spec.
629#
630# @access-latency: access latency (nanoseconds)
631#
632# @read-latency: read latency (nanoseconds)
633#
634# @write-latency: write latency (nanoseconds)
635#
636# @access-bandwidth: access bandwidth (Bytes per second)
637#
638# @read-bandwidth: read bandwidth (Bytes per second)
639#
640# @write-bandwidth: write bandwidth (Bytes per second)
641#
642# Since: 5.0
643##
644{ 'enum': 'HmatLBDataType',
645  'data': [ 'access-latency', 'read-latency', 'write-latency',
646            'access-bandwidth', 'read-bandwidth', 'write-bandwidth' ] }
647
648##
649# @NumaHmatLBOptions:
650#
651# Set the system locality latency and bandwidth information between
652# Initiator and Target proximity Domains.
653#
654# For more information about @NumaHmatLBOptions, see chapter 5.2.27.4:
655# Table 5-146 of ACPI 6.3 spec.
656#
657# @initiator: the Initiator Proximity Domain.
658#
659# @target: the Target Proximity Domain.
660#
661# @hierarchy: the Memory Hierarchy.  Indicates the performance of
662#     memory or side cache.
663#
664# @data-type: presents the type of data, access/read/write latency or
665#     hit latency.
666#
667# @latency: the value of latency from @initiator to @target proximity
668#     domain, the latency unit is "ns(nanosecond)".
669#
670# @bandwidth: the value of bandwidth between @initiator and @target
671#     proximity domain, the bandwidth unit is "Bytes per second".
672#
673# Since: 5.0
674##
675{ 'struct': 'NumaHmatLBOptions',
676    'data': {
677    'initiator': 'uint16',
678    'target': 'uint16',
679    'hierarchy': 'HmatLBMemoryHierarchy',
680    'data-type': 'HmatLBDataType',
681    '*latency': 'uint64',
682    '*bandwidth': 'size' }}
683
684##
685# @HmatCacheAssociativity:
686#
687# Cache associativity in the Memory Side Cache Information Structure
688# of HMAT
689#
690# For more information of @HmatCacheAssociativity, see chapter
691# 5.2.27.5: Table 5-147 of ACPI 6.3 spec.
692#
693# @none: None (no memory side cache in this proximity domain, or cache
694#     associativity unknown)
695#
696# @direct: Direct Mapped
697#
698# @complex: Complex Cache Indexing (implementation specific)
699#
700# Since: 5.0
701##
702{ 'enum': 'HmatCacheAssociativity',
703  'data': [ 'none', 'direct', 'complex' ] }
704
705##
706# @HmatCacheWritePolicy:
707#
708# Cache write policy in the Memory Side Cache Information Structure of
709# HMAT
710#
711# For more information of @HmatCacheWritePolicy, see chapter 5.2.27.5:
712# Table 5-147: Field "Cache Attributes" of ACPI 6.3 spec.
713#
714# @none: None (no memory side cache in this proximity domain, or cache
715#     write policy unknown)
716#
717# @write-back: Write Back (WB)
718#
719# @write-through: Write Through (WT)
720#
721# Since: 5.0
722##
723{ 'enum': 'HmatCacheWritePolicy',
724  'data': [ 'none', 'write-back', 'write-through' ] }
725
726##
727# @NumaHmatCacheOptions:
728#
729# Set the memory side cache information for a given memory domain.
730#
731# For more information of @NumaHmatCacheOptions, see chapter 5.2.27.5:
732# Table 5-147: Field "Cache Attributes" of ACPI 6.3 spec.
733#
734# @node-id: the memory proximity domain to which the memory belongs.
735#
736# @size: the size of memory side cache in bytes.
737#
738# @level: the cache level described in this structure.
739#
740# @associativity: the cache associativity,
741#     none/direct-mapped/complex(complex cache indexing).
742#
743# @policy: the write policy, none/write-back/write-through.
744#
745# @line: the cache Line size in bytes.
746#
747# Since: 5.0
748##
749{ 'struct': 'NumaHmatCacheOptions',
750  'data': {
751   'node-id': 'uint32',
752   'size': 'size',
753   'level': 'uint8',
754   'associativity': 'HmatCacheAssociativity',
755   'policy': 'HmatCacheWritePolicy',
756   'line': 'uint16' }}
757
758##
759# @memsave:
760#
761# Save a portion of guest memory to a file.
762#
763# @val: the virtual address of the guest to start from
764#
765# @size: the size of memory region to save
766#
767# @filename: the file to save the memory to as binary data
768#
769# @cpu-index: the index of the virtual CPU to use for translating the
770#     virtual address (defaults to CPU 0)
771#
772# Returns: Nothing on success
773#
774# Since: 0.14
775#
776# Notes: Errors were not reliably returned until 1.1
777#
778# Example:
779#
780# -> { "execute": "memsave",
781#      "arguments": { "val": 10,
782#                     "size": 100,
783#                     "filename": "/tmp/virtual-mem-dump" } }
784# <- { "return": {} }
785##
786{ 'command': 'memsave',
787  'data': {'val': 'int', 'size': 'int', 'filename': 'str', '*cpu-index': 'int'} }
788
789##
790# @pmemsave:
791#
792# Save a portion of guest physical memory to a file.
793#
794# @val: the physical address of the guest to start from
795#
796# @size: the size of memory region to save
797#
798# @filename: the file to save the memory to as binary data
799#
800# Returns: Nothing on success
801#
802# Since: 0.14
803#
804# Notes: Errors were not reliably returned until 1.1
805#
806# Example:
807#
808# -> { "execute": "pmemsave",
809#      "arguments": { "val": 10,
810#                     "size": 100,
811#                     "filename": "/tmp/physical-mem-dump" } }
812# <- { "return": {} }
813##
814{ 'command': 'pmemsave',
815  'data': {'val': 'int', 'size': 'int', 'filename': 'str'} }
816
817##
818# @Memdev:
819#
820# Information about memory backend
821#
822# @id: backend's ID if backend has 'id' property (since 2.9)
823#
824# @size: memory backend size
825#
826# @merge: whether memory merge support is enabled
827#
828# @dump: whether memory backend's memory is included in a core dump
829#
830# @prealloc: whether memory was preallocated
831#
832# @share: whether memory is private to QEMU or shared (since 6.1)
833#
834# @reserve: whether swap space (or huge pages) was reserved if
835#     applicable.  This corresponds to the user configuration and not
836#     the actual behavior implemented in the OS to perform the
837#     reservation.  For example, Linux will never reserve swap space
838#     for shared file mappings.  (since 6.1)
839#
840# @host-nodes: host nodes for its memory policy
841#
842# @policy: memory policy of memory backend
843#
844# Since: 2.1
845##
846{ 'struct': 'Memdev',
847  'data': {
848    '*id':        'str',
849    'size':       'size',
850    'merge':      'bool',
851    'dump':       'bool',
852    'prealloc':   'bool',
853    'share':      'bool',
854    '*reserve':    'bool',
855    'host-nodes': ['uint16'],
856    'policy':     'HostMemPolicy' }}
857
858##
859# @query-memdev:
860#
861# Returns information for all memory backends.
862#
863# Returns: a list of @Memdev.
864#
865# Since: 2.1
866#
867# Example:
868#
869# -> { "execute": "query-memdev" }
870# <- { "return": [
871#        {
872#          "id": "mem1",
873#          "size": 536870912,
874#          "merge": false,
875#          "dump": true,
876#          "prealloc": false,
877#          "share": false,
878#          "host-nodes": [0, 1],
879#          "policy": "bind"
880#        },
881#        {
882#          "size": 536870912,
883#          "merge": false,
884#          "dump": true,
885#          "prealloc": true,
886#          "share": false,
887#          "host-nodes": [2, 3],
888#          "policy": "preferred"
889#        }
890#      ]
891#    }
892##
893{ 'command': 'query-memdev', 'returns': ['Memdev'], 'allow-preconfig': true }
894
895##
896# @CpuInstanceProperties:
897#
898# List of properties to be used for hotplugging a CPU instance, it
899# should be passed by management with device_add command when a CPU is
900# being hotplugged.
901#
902# @node-id: NUMA node ID the CPU belongs to
903#
904# @socket-id: socket number within node/board the CPU belongs to
905#
906# @die-id: die number within socket the CPU belongs to (since 4.1)
907#
908# @cluster-id: cluster number within die the CPU belongs to (since
909#     7.1)
910#
911# @core-id: core number within cluster the CPU belongs to
912#
913# @thread-id: thread number within core the CPU belongs to
914#
915# Note: currently there are 6 properties that could be present but
916#     management should be prepared to pass through other properties
917#     with device_add command to allow for future interface extension.
918#     This also requires the filed names to be kept in sync with the
919#     properties passed to -device/device_add.
920#
921# Since: 2.7
922##
923{ 'struct': 'CpuInstanceProperties',
924  'data': { '*node-id': 'int',
925            '*socket-id': 'int',
926            '*die-id': 'int',
927            '*cluster-id': 'int',
928            '*core-id': 'int',
929            '*thread-id': 'int'
930  }
931}
932
933##
934# @HotpluggableCPU:
935#
936# @type: CPU object type for usage with device_add command
937#
938# @props: list of properties to be used for hotplugging CPU
939#
940# @vcpus-count: number of logical VCPU threads @HotpluggableCPU
941#     provides
942#
943# @qom-path: link to existing CPU object if CPU is present or omitted
944#     if CPU is not present.
945#
946# Since: 2.7
947##
948{ 'struct': 'HotpluggableCPU',
949  'data': { 'type': 'str',
950            'vcpus-count': 'int',
951            'props': 'CpuInstanceProperties',
952            '*qom-path': 'str'
953          }
954}
955
956##
957# @query-hotpluggable-cpus:
958#
959# TODO: Better documentation; currently there is none.
960#
961# Returns: a list of HotpluggableCPU objects.
962#
963# Since: 2.7
964#
965# Examples:
966#
967# For pseries machine type started with -smp 2,cores=2,maxcpus=4 -cpu
968# POWER8:
969#
970# -> { "execute": "query-hotpluggable-cpus" }
971# <- {"return": [
972#      { "props": { "core-id": 8 }, "type": "POWER8-spapr-cpu-core",
973#        "vcpus-count": 1 },
974#      { "props": { "core-id": 0 }, "type": "POWER8-spapr-cpu-core",
975#        "vcpus-count": 1, "qom-path": "/machine/unattached/device[0]"}
976#    ]}'
977#
978# For pc machine type started with -smp 1,maxcpus=2:
979#
980# -> { "execute": "query-hotpluggable-cpus" }
981# <- {"return": [
982#      {
983#         "type": "qemu64-x86_64-cpu", "vcpus-count": 1,
984#         "props": {"core-id": 0, "socket-id": 1, "thread-id": 0}
985#      },
986#      {
987#         "qom-path": "/machine/unattached/device[0]",
988#         "type": "qemu64-x86_64-cpu", "vcpus-count": 1,
989#         "props": {"core-id": 0, "socket-id": 0, "thread-id": 0}
990#      }
991#    ]}
992#
993# For s390x-virtio-ccw machine type started with -smp 1,maxcpus=2 -cpu
994# qemu (Since: 2.11):
995#
996# -> { "execute": "query-hotpluggable-cpus" }
997# <- {"return": [
998#      {
999#         "type": "qemu-s390x-cpu", "vcpus-count": 1,
1000#         "props": { "core-id": 1 }
1001#      },
1002#      {
1003#         "qom-path": "/machine/unattached/device[0]",
1004#         "type": "qemu-s390x-cpu", "vcpus-count": 1,
1005#         "props": { "core-id": 0 }
1006#      }
1007#    ]}
1008##
1009{ 'command': 'query-hotpluggable-cpus', 'returns': ['HotpluggableCPU'],
1010             'allow-preconfig': true }
1011
1012##
1013# @set-numa-node:
1014#
1015# Runtime equivalent of '-numa' CLI option, available at preconfigure
1016# stage to configure numa mapping before initializing machine.
1017#
1018# Since: 3.0
1019##
1020{ 'command': 'set-numa-node', 'boxed': true,
1021  'data': 'NumaOptions',
1022  'allow-preconfig': true
1023}
1024
1025##
1026# @balloon:
1027#
1028# Request the balloon driver to change its balloon size.
1029#
1030# @value: the target logical size of the VM in bytes.  We can deduce
1031#     the size of the balloon using this formula:
1032#
1033#        logical_vm_size = vm_ram_size - balloon_size
1034#
1035#     From it we have: balloon_size = vm_ram_size - @value
1036#
1037# Returns:
1038# - Nothing on success
1039# - If the balloon driver is enabled but not functional because the
1040#   KVM kernel module cannot support it, KVMMissingCap
1041# - If no balloon device is present, DeviceNotActive
1042#
1043# Notes: This command just issues a request to the guest.  When it
1044#     returns, the balloon size may not have changed.  A guest can
1045#     change the balloon size independent of this command.
1046#
1047# Since: 0.14
1048#
1049# Example:
1050#
1051# -> { "execute": "balloon", "arguments": { "value": 536870912 } }
1052# <- { "return": {} }
1053#
1054# With a 2.5GiB guest this command inflated the ballon to 3GiB.
1055##
1056{ 'command': 'balloon', 'data': {'value': 'int'} }
1057
1058##
1059# @BalloonInfo:
1060#
1061# Information about the guest balloon device.
1062#
1063# @actual: the logical size of the VM in bytes Formula used:
1064#     logical_vm_size = vm_ram_size - balloon_size
1065#
1066# Since: 0.14
1067##
1068{ 'struct': 'BalloonInfo', 'data': {'actual': 'int' } }
1069
1070##
1071# @query-balloon:
1072#
1073# Return information about the balloon device.
1074#
1075# Returns:
1076# - @BalloonInfo on success
1077# - If the balloon driver is enabled but not functional because the
1078#   KVM kernel module cannot support it, KVMMissingCap
1079# - If no balloon device is present, DeviceNotActive
1080#
1081# Since: 0.14
1082#
1083# Example:
1084#
1085# -> { "execute": "query-balloon" }
1086# <- { "return": {
1087#          "actual": 1073741824
1088#       }
1089#    }
1090##
1091{ 'command': 'query-balloon', 'returns': 'BalloonInfo' }
1092
1093##
1094# @BALLOON_CHANGE:
1095#
1096# Emitted when the guest changes the actual BALLOON level.  This value
1097# is equivalent to the @actual field return by the 'query-balloon'
1098# command
1099#
1100# @actual: the logical size of the VM in bytes Formula used:
1101#     logical_vm_size = vm_ram_size - balloon_size
1102#
1103# Note: this event is rate-limited.
1104#
1105# Since: 1.2
1106#
1107# Example:
1108#
1109# <- { "event": "BALLOON_CHANGE",
1110#      "data": { "actual": 944766976 },
1111#      "timestamp": { "seconds": 1267020223, "microseconds": 435656 } }
1112##
1113{ 'event': 'BALLOON_CHANGE',
1114  'data': { 'actual': 'int' } }
1115
1116##
1117# @MemoryInfo:
1118#
1119# Actual memory information in bytes.
1120#
1121# @base-memory: size of "base" memory specified with command line
1122#     option -m.
1123#
1124# @plugged-memory: size of memory that can be hot-unplugged.  This
1125#     field is omitted if target doesn't support memory hotplug (i.e.
1126#     CONFIG_MEM_DEVICE not defined at build time).
1127#
1128# Since: 2.11
1129##
1130{ 'struct': 'MemoryInfo',
1131  'data'  : { 'base-memory': 'size', '*plugged-memory': 'size' } }
1132
1133##
1134# @query-memory-size-summary:
1135#
1136# Return the amount of initially allocated and present hotpluggable
1137# (if enabled) memory in bytes.
1138#
1139# Example:
1140#
1141# -> { "execute": "query-memory-size-summary" }
1142# <- { "return": { "base-memory": 4294967296, "plugged-memory": 0 } }
1143#
1144# Since: 2.11
1145##
1146{ 'command': 'query-memory-size-summary', 'returns': 'MemoryInfo' }
1147
1148##
1149# @PCDIMMDeviceInfo:
1150#
1151# PCDIMMDevice state information
1152#
1153# @id: device's ID
1154#
1155# @addr: physical address, where device is mapped
1156#
1157# @size: size of memory that the device provides
1158#
1159# @slot: slot number at which device is plugged in
1160#
1161# @node: NUMA node number where device is plugged in
1162#
1163# @memdev: memory backend linked with device
1164#
1165# @hotplugged: true if device was hotplugged
1166#
1167# @hotpluggable: true if device if could be added/removed while
1168#     machine is running
1169#
1170# Since: 2.1
1171##
1172{ 'struct': 'PCDIMMDeviceInfo',
1173  'data': { '*id': 'str',
1174            'addr': 'int',
1175            'size': 'int',
1176            'slot': 'int',
1177            'node': 'int',
1178            'memdev': 'str',
1179            'hotplugged': 'bool',
1180            'hotpluggable': 'bool'
1181          }
1182}
1183
1184##
1185# @VirtioPMEMDeviceInfo:
1186#
1187# VirtioPMEM state information
1188#
1189# @id: device's ID
1190#
1191# @memaddr: physical address in memory, where device is mapped
1192#
1193# @size: size of memory that the device provides
1194#
1195# @memdev: memory backend linked with device
1196#
1197# Since: 4.1
1198##
1199{ 'struct': 'VirtioPMEMDeviceInfo',
1200  'data': { '*id': 'str',
1201            'memaddr': 'size',
1202            'size': 'size',
1203            'memdev': 'str'
1204          }
1205}
1206
1207##
1208# @VirtioMEMDeviceInfo:
1209#
1210# VirtioMEMDevice state information
1211#
1212# @id: device's ID
1213#
1214# @memaddr: physical address in memory, where device is mapped
1215#
1216# @requested-size: the user requested size of the device
1217#
1218# @size: the (current) size of memory that the device provides
1219#
1220# @max-size: the maximum size of memory that the device can provide
1221#
1222# @block-size: the block size of memory that the device provides
1223#
1224# @node: NUMA node number where device is assigned to
1225#
1226# @memdev: memory backend linked with the region
1227#
1228# Since: 5.1
1229##
1230{ 'struct': 'VirtioMEMDeviceInfo',
1231  'data': { '*id': 'str',
1232            'memaddr': 'size',
1233            'requested-size': 'size',
1234            'size': 'size',
1235            'max-size': 'size',
1236            'block-size': 'size',
1237            'node': 'int',
1238            'memdev': 'str'
1239          }
1240}
1241
1242##
1243# @SgxEPCDeviceInfo:
1244#
1245# Sgx EPC state information
1246#
1247# @id: device's ID
1248#
1249# @memaddr: physical address in memory, where device is mapped
1250#
1251# @size: size of memory that the device provides
1252#
1253# @memdev: memory backend linked with device
1254#
1255# @node: the numa node (Since: 7.0)
1256#
1257# Since: 6.2
1258##
1259{ 'struct': 'SgxEPCDeviceInfo',
1260  'data': { '*id': 'str',
1261            'memaddr': 'size',
1262            'size': 'size',
1263            'node': 'int',
1264            'memdev': 'str'
1265          }
1266}
1267
1268##
1269# @MemoryDeviceInfoKind:
1270#
1271# @nvdimm: since 2.12
1272#
1273# @virtio-pmem: since 4.1
1274#
1275# @virtio-mem: since 5.1
1276#
1277# @sgx-epc: since 6.2.
1278#
1279# Since: 2.1
1280##
1281{ 'enum': 'MemoryDeviceInfoKind',
1282  'data': [ 'dimm', 'nvdimm', 'virtio-pmem', 'virtio-mem', 'sgx-epc' ] }
1283
1284##
1285# @PCDIMMDeviceInfoWrapper:
1286#
1287# Since: 2.1
1288##
1289{ 'struct': 'PCDIMMDeviceInfoWrapper',
1290  'data': { 'data': 'PCDIMMDeviceInfo' } }
1291
1292##
1293# @VirtioPMEMDeviceInfoWrapper:
1294#
1295# Since: 2.1
1296##
1297{ 'struct': 'VirtioPMEMDeviceInfoWrapper',
1298  'data': { 'data': 'VirtioPMEMDeviceInfo' } }
1299
1300##
1301# @VirtioMEMDeviceInfoWrapper:
1302#
1303# Since: 2.1
1304##
1305{ 'struct': 'VirtioMEMDeviceInfoWrapper',
1306  'data': { 'data': 'VirtioMEMDeviceInfo' } }
1307
1308##
1309# @SgxEPCDeviceInfoWrapper:
1310#
1311# Since: 6.2
1312##
1313{ 'struct': 'SgxEPCDeviceInfoWrapper',
1314  'data': { 'data': 'SgxEPCDeviceInfo' } }
1315
1316##
1317# @MemoryDeviceInfo:
1318#
1319# Union containing information about a memory device
1320#
1321# Since: 2.1
1322##
1323{ 'union': 'MemoryDeviceInfo',
1324  'base': { 'type': 'MemoryDeviceInfoKind' },
1325  'discriminator': 'type',
1326  'data': { 'dimm': 'PCDIMMDeviceInfoWrapper',
1327            'nvdimm': 'PCDIMMDeviceInfoWrapper',
1328            'virtio-pmem': 'VirtioPMEMDeviceInfoWrapper',
1329            'virtio-mem': 'VirtioMEMDeviceInfoWrapper',
1330            'sgx-epc': 'SgxEPCDeviceInfoWrapper'
1331          }
1332}
1333
1334##
1335# @SgxEPC:
1336#
1337# Sgx EPC cmdline information
1338#
1339# @memdev: memory backend linked with device
1340#
1341# @node: the numa node (Since: 7.0)
1342#
1343# Since: 6.2
1344##
1345{ 'struct': 'SgxEPC',
1346  'data': { 'memdev': 'str',
1347            'node': 'int'
1348          }
1349}
1350
1351##
1352# @SgxEPCProperties:
1353#
1354# SGX properties of machine types.
1355#
1356# @sgx-epc: list of ids of memory-backend-epc objects.
1357#
1358# Since: 6.2
1359##
1360{ 'struct': 'SgxEPCProperties',
1361  'data': { 'sgx-epc': ['SgxEPC'] }
1362}
1363
1364##
1365# @query-memory-devices:
1366#
1367# Lists available memory devices and their state
1368#
1369# Since: 2.1
1370#
1371# Example:
1372#
1373# -> { "execute": "query-memory-devices" }
1374# <- { "return": [ { "data":
1375#                       { "addr": 5368709120,
1376#                         "hotpluggable": true,
1377#                         "hotplugged": true,
1378#                         "id": "d1",
1379#                         "memdev": "/objects/memX",
1380#                         "node": 0,
1381#                         "size": 1073741824,
1382#                         "slot": 0},
1383#                    "type": "dimm"
1384#                  } ] }
1385##
1386{ 'command': 'query-memory-devices', 'returns': ['MemoryDeviceInfo'] }
1387
1388##
1389# @MEMORY_DEVICE_SIZE_CHANGE:
1390#
1391# Emitted when the size of a memory device changes.  Only emitted for
1392# memory devices that can actually change the size (e.g., virtio-mem
1393# due to guest action).
1394#
1395# @id: device's ID
1396#
1397# @size: the new size of memory that the device provides
1398#
1399# @qom-path: path to the device object in the QOM tree (since 6.2)
1400#
1401# Note: this event is rate-limited.
1402#
1403# Since: 5.1
1404#
1405# Example:
1406#
1407# <- { "event": "MEMORY_DEVICE_SIZE_CHANGE",
1408#      "data": { "id": "vm0", "size": 1073741824,
1409#                "qom-path": "/machine/unattached/device[2]" },
1410#      "timestamp": { "seconds": 1588168529, "microseconds": 201316 } }
1411##
1412{ 'event': 'MEMORY_DEVICE_SIZE_CHANGE',
1413  'data': { '*id': 'str', 'size': 'size', 'qom-path' : 'str'} }
1414
1415##
1416# @MEM_UNPLUG_ERROR:
1417#
1418# Emitted when memory hot unplug error occurs.
1419#
1420# @device: device name
1421#
1422# @msg: Informative message
1423#
1424# Features:
1425#
1426# @deprecated: This event is deprecated.  Use
1427#     @DEVICE_UNPLUG_GUEST_ERROR instead.
1428#
1429# Since: 2.4
1430#
1431# Example:
1432#
1433# <- { "event": "MEM_UNPLUG_ERROR",
1434#      "data": { "device": "dimm1",
1435#                "msg": "acpi: device unplug for unsupported device"
1436#      },
1437#      "timestamp": { "seconds": 1265044230, "microseconds": 450486 } }
1438##
1439{ 'event': 'MEM_UNPLUG_ERROR',
1440  'data': { 'device': 'str', 'msg': 'str' },
1441  'features': ['deprecated'] }
1442
1443##
1444# @BootConfiguration:
1445#
1446# Schema for virtual machine boot configuration.
1447#
1448# @order: Boot order (a=floppy, c=hard disk, d=CD-ROM, n=network)
1449#
1450# @once: Boot order to apply on first boot
1451#
1452# @menu: Whether to show a boot menu
1453#
1454# @splash: The name of the file to be passed to the firmware as logo
1455#     picture, if @menu is true.
1456#
1457# @splash-time: How long to show the logo picture, in milliseconds
1458#
1459# @reboot-timeout: Timeout before guest reboots after boot fails
1460#
1461# @strict: Whether to attempt booting from devices not included in the
1462#     boot order
1463#
1464# Since: 7.1
1465##
1466{ 'struct': 'BootConfiguration', 'data': {
1467     '*order': 'str',
1468     '*once': 'str',
1469     '*menu': 'bool',
1470     '*splash': 'str',
1471     '*splash-time': 'int',
1472     '*reboot-timeout': 'int',
1473     '*strict': 'bool' } }
1474
1475##
1476# @SMPConfiguration:
1477#
1478# Schema for CPU topology configuration.  A missing value lets QEMU
1479# figure out a suitable value based on the ones that are provided.
1480#
1481# @cpus: number of virtual CPUs in the virtual machine
1482#
1483# @sockets: number of sockets in the CPU topology
1484#
1485# @dies: number of dies per socket in the CPU topology
1486#
1487# @clusters: number of clusters per die in the CPU topology (since
1488#     7.0)
1489#
1490# @cores: number of cores per cluster in the CPU topology
1491#
1492# @threads: number of threads per core in the CPU topology
1493#
1494# @maxcpus: maximum number of hotpluggable virtual CPUs in the virtual
1495#     machine
1496#
1497# Since: 6.1
1498##
1499{ 'struct': 'SMPConfiguration', 'data': {
1500     '*cpus': 'int',
1501     '*sockets': 'int',
1502     '*dies': 'int',
1503     '*clusters': 'int',
1504     '*cores': 'int',
1505     '*threads': 'int',
1506     '*maxcpus': 'int' } }
1507
1508##
1509# @x-query-irq:
1510#
1511# Query interrupt statistics
1512#
1513# Features:
1514#
1515# @unstable: This command is meant for debugging.
1516#
1517# Returns: interrupt statistics
1518#
1519# Since: 6.2
1520##
1521{ 'command': 'x-query-irq',
1522  'returns': 'HumanReadableText',
1523  'features': [ 'unstable' ] }
1524
1525##
1526# @x-query-jit:
1527#
1528# Query TCG compiler statistics
1529#
1530# Features:
1531#
1532# @unstable: This command is meant for debugging.
1533#
1534# Returns: TCG compiler statistics
1535#
1536# Since: 6.2
1537##
1538{ 'command': 'x-query-jit',
1539  'returns': 'HumanReadableText',
1540  'if': 'CONFIG_TCG',
1541  'features': [ 'unstable' ] }
1542
1543##
1544# @x-query-numa:
1545#
1546# Query NUMA topology information
1547#
1548# Features:
1549#
1550# @unstable: This command is meant for debugging.
1551#
1552# Returns: topology information
1553#
1554# Since: 6.2
1555##
1556{ 'command': 'x-query-numa',
1557  'returns': 'HumanReadableText',
1558  'features': [ 'unstable' ] }
1559
1560##
1561# @x-query-opcount:
1562#
1563# Query TCG opcode counters
1564#
1565# Features:
1566#
1567# @unstable: This command is meant for debugging.
1568#
1569# Returns: TCG opcode counters
1570#
1571# Since: 6.2
1572##
1573{ 'command': 'x-query-opcount',
1574  'returns': 'HumanReadableText',
1575  'if': 'CONFIG_TCG',
1576  'features': [ 'unstable' ] }
1577
1578##
1579# @x-query-ramblock:
1580#
1581# Query system ramblock information
1582#
1583# Features:
1584#
1585# @unstable: This command is meant for debugging.
1586#
1587# Returns: system ramblock information
1588#
1589# Since: 6.2
1590##
1591{ 'command': 'x-query-ramblock',
1592  'returns': 'HumanReadableText',
1593  'features': [ 'unstable' ] }
1594
1595##
1596# @x-query-rdma:
1597#
1598# Query RDMA state
1599#
1600# Features:
1601#
1602# @unstable: This command is meant for debugging.
1603#
1604# Returns: RDMA state
1605#
1606# Since: 6.2
1607##
1608{ 'command': 'x-query-rdma',
1609  'returns': 'HumanReadableText',
1610  'features': [ 'unstable' ] }
1611
1612##
1613# @x-query-roms:
1614#
1615# Query information on the registered ROMS
1616#
1617# Features:
1618#
1619# @unstable: This command is meant for debugging.
1620#
1621# Returns: registered ROMs
1622#
1623# Since: 6.2
1624##
1625{ 'command': 'x-query-roms',
1626  'returns': 'HumanReadableText',
1627  'features': [ 'unstable' ] }
1628
1629##
1630# @x-query-usb:
1631#
1632# Query information on the USB devices
1633#
1634# Features:
1635#
1636# @unstable: This command is meant for debugging.
1637#
1638# Returns: USB device information
1639#
1640# Since: 6.2
1641##
1642{ 'command': 'x-query-usb',
1643  'returns': 'HumanReadableText',
1644  'features': [ 'unstable' ] }
1645
1646##
1647# @SmbiosEntryPointType:
1648#
1649# @32: SMBIOS version 2.1 (32-bit) Entry Point
1650#
1651# @64: SMBIOS version 3.0 (64-bit) Entry Point
1652#
1653# Since: 7.0
1654##
1655{ 'enum': 'SmbiosEntryPointType',
1656  'data': [ '32', '64' ] }
1657
1658##
1659# @MemorySizeConfiguration:
1660#
1661# Schema for memory size configuration.
1662#
1663# @size: memory size in bytes
1664#
1665# @max-size: maximum hotpluggable memory size in bytes
1666#
1667# @slots: number of available memory slots for hotplug
1668#
1669# Since: 7.1
1670##
1671{ 'struct': 'MemorySizeConfiguration', 'data': {
1672     '*size': 'size',
1673     '*max-size': 'size',
1674     '*slots': 'uint64' } }
1675
1676##
1677# @dumpdtb:
1678#
1679# Save the FDT in dtb format.
1680#
1681# @filename: name of the dtb file to be created
1682#
1683# Since: 7.2
1684#
1685# Example:
1686#
1687# -> { "execute": "dumpdtb" }
1688#      "arguments": { "filename": "fdt.dtb" } }
1689# <- { "return": {} }
1690##
1691{ 'command': 'dumpdtb',
1692  'data': { 'filename': 'str' },
1693  'if': 'CONFIG_FDT' }
1694