]>
Commit | Line | Data |
---|---|---|
d34bda71 BC |
1 | # -*- Mode: Python -*- |
2 | # | |
3 | # QAPI common definitions | |
4 | ||
5 | ## | |
f22a28b8 | 6 | # @QapiErrorClass |
d34bda71 BC |
7 | # |
8 | # QEMU error classes | |
9 | # | |
10 | # @GenericError: this is used for errors that don't require a specific error | |
11 | # class. This should be the default case for most errors | |
12 | # | |
13 | # @CommandNotFound: the requested command has not been found | |
14 | # | |
15 | # @DeviceEncrypted: the requested operation can't be fulfilled because the | |
16 | # selected device is encrypted | |
17 | # | |
18 | # @DeviceNotActive: a device has failed to be become active | |
19 | # | |
20 | # @DeviceNotFound: the requested device has not been found | |
21 | # | |
22 | # @KVMMissingCap: the requested operation can't be fulfilled because a | |
23 | # required KVM capability is missing | |
24 | # | |
25 | # Since: 1.2 | |
26 | ## | |
f22a28b8 EB |
27 | { 'enum': 'QapiErrorClass', |
28 | # Keep this in sync with ErrorClass in error.h | |
d34bda71 BC |
29 | 'data': [ 'GenericError', 'CommandNotFound', 'DeviceEncrypted', |
30 | 'DeviceNotActive', 'DeviceNotFound', 'KVMMissingCap' ] } | |
31 | ||
32 | ## | |
4752cdbb | 33 | # @VersionTriple |
d34bda71 | 34 | # |
4752cdbb EB |
35 | # A three-part version number. |
36 | # | |
37 | # @qemu.major: The major version number. | |
d34bda71 | 38 | # |
4752cdbb | 39 | # @qemu.minor: The minor version number. |
d34bda71 | 40 | # |
4752cdbb EB |
41 | # @qemu.micro: The micro version number. |
42 | # | |
43 | # Since: 2.4 | |
44 | ## | |
45 | { 'struct': 'VersionTriple', | |
46 | 'data': {'major': 'int', 'minor': 'int', 'micro': 'int'} } | |
47 | ||
48 | ||
49 | ## | |
50 | # @VersionInfo: | |
51 | # | |
52 | # A description of QEMU's version. | |
d34bda71 | 53 | # |
4752cdbb | 54 | # @qemu: The version of QEMU. By current convention, a micro |
d34bda71 BC |
55 | # version of 50 signifies a development branch. A micro version |
56 | # greater than or equal to 90 signifies a release candidate for | |
57 | # the next minor version. A micro version of less than 50 | |
58 | # signifies a stable release. | |
59 | # | |
60 | # @package: QEMU will always set this field to an empty string. Downstream | |
61 | # versions of QEMU should set this to a non-empty string. The | |
62 | # exact format depends on the downstream however it highly | |
63 | # recommended that a unique name is used. | |
64 | # | |
65 | # Since: 0.14.0 | |
66 | ## | |
895a2a80 | 67 | { 'struct': 'VersionInfo', |
4752cdbb | 68 | 'data': {'qemu': 'VersionTriple', 'package': 'str'} } |
d34bda71 BC |
69 | |
70 | ## | |
71 | # @query-version: | |
72 | # | |
73 | # Returns the current version of QEMU. | |
74 | # | |
75 | # Returns: A @VersionInfo object describing the current version of QEMU. | |
76 | # | |
77 | # Since: 0.14.0 | |
78 | ## | |
79 | { 'command': 'query-version', 'returns': 'VersionInfo' } | |
80 | ||
81 | ## | |
82 | # @CommandInfo: | |
83 | # | |
84 | # Information about a QMP command | |
85 | # | |
86 | # @name: The command name | |
87 | # | |
88 | # Since: 0.14.0 | |
89 | ## | |
895a2a80 | 90 | { 'struct': 'CommandInfo', 'data': {'name': 'str'} } |
d34bda71 BC |
91 | |
92 | ## | |
93 | # @query-commands: | |
94 | # | |
95 | # Return a list of supported QMP commands by this server | |
96 | # | |
97 | # Returns: A list of @CommandInfo for all supported commands | |
98 | # | |
99 | # Since: 0.14.0 | |
100 | ## | |
101 | { 'command': 'query-commands', 'returns': ['CommandInfo'] } | |
102 | ||
d1048bef DS |
103 | ## |
104 | # @OnOffAuto | |
105 | # | |
106 | # An enumeration of three options: on, off, and auto | |
107 | # | |
108 | # @auto: QEMU selects the value between on and off | |
109 | # | |
110 | # @on: Enabled | |
111 | # | |
112 | # @off: Disabled | |
113 | # | |
114 | # Since: 2.2 | |
115 | ## | |
116 | { 'enum': 'OnOffAuto', | |
117 | 'data': [ 'auto', 'on', 'off' ] } | |
32c18a2d MG |
118 | |
119 | ## | |
120 | # @OnOffSplit | |
121 | # | |
122 | # An enumeration of three values: on, off, and split | |
123 | # | |
124 | # @on: Enabled | |
125 | # | |
126 | # @off: Disabled | |
127 | # | |
128 | # @split: Mixed | |
129 | # | |
130 | # Since: 2.6 | |
131 | ## | |
132 | { 'enum': 'OnOffSplit', | |
133 | 'data': [ 'on', 'off', 'split' ] } |