]> git.proxmox.com Git - mirror_qemu.git/blobdiff - qapi/common.json
exec.c: subpage->sub_section is already initialized to 0
[mirror_qemu.git] / qapi / common.json
index 6987100343b75d64f935b138b1de5bf25aaab308..7b9cbcd97b4b517e5ecb77c1793b25e2485556f2 100644 (file)
 # -*- Mode: Python -*-
-#
-# QAPI common definitions
 
 ##
-# @QapiErrorClass
-#
-# QEMU error classes
-#
-# @GenericError: this is used for errors that don't require a specific error
-#                class. This should be the default case for most errors
-#
-# @CommandNotFound: the requested command has not been found
-#
-# @DeviceEncrypted: the requested operation can't be fulfilled because the
-#                   selected device is encrypted
+# = Common data types
+##
+
+##
+# @IoOperationType:
 #
-# @DeviceNotActive: a device has failed to be become active
+# An enumeration of the I/O operation types
 #
-# @DeviceNotFound: the requested device has not been found
+# @read: read operation
 #
-# @KVMMissingCap: the requested operation can't be fulfilled because a
-#                 required KVM capability is missing
+# @write: write operation
 #
-# Since: 1.2
+# Since: 2.1
 ##
-{ 'enum': 'QapiErrorClass',
-  # Keep this in sync with ErrorClass in error.h
-  'data': [ 'GenericError', 'CommandNotFound', 'DeviceEncrypted',
-            'DeviceNotActive', 'DeviceNotFound', 'KVMMissingCap' ] }
+{ 'enum': 'IoOperationType',
+  'data': [ 'read', 'write' ] }
 
 ##
-# @VersionTriple
+# @OnOffAuto:
 #
-# A three-part version number.
+# An enumeration of three options: on, off, and auto
 #
-# @major:  The major version number.
+# @auto: QEMU selects the value between on and off
 #
-# @minor:  The minor version number.
+# @on: Enabled
 #
-# @micro:  The micro version number.
+# @off: Disabled
 #
-# Since: 2.4
+# Since: 2.2
 ##
-{ 'struct': 'VersionTriple',
-  'data': {'major': 'int', 'minor': 'int', 'micro': 'int'} }
-
+{ 'enum': 'OnOffAuto',
+  'data': [ 'auto', 'on', 'off' ] }
 
 ##
-# @VersionInfo:
+# @OnOffSplit:
 #
-# A description of QEMU's version.
+# An enumeration of three values: on, off, and split
 #
-# @qemu:        The version of QEMU.  By current convention, a micro
-#               version of 50 signifies a development branch.  A micro version
-#               greater than or equal to 90 signifies a release candidate for
-#               the next minor version.  A micro version of less than 50
-#               signifies a stable release.
+# @on: Enabled
 #
-# @package:     QEMU will always set this field to an empty string.  Downstream
-#               versions of QEMU should set this to a non-empty string.  The
-#               exact format depends on the downstream however it highly
-#               recommended that a unique name is used.
+# @off: Disabled
 #
-# Since: 0.14.0
+# @split: Mixed
+#
+# Since: 2.6
 ##
-{ 'struct': 'VersionInfo',
-  'data': {'qemu': 'VersionTriple', 'package': 'str'} }
+{ 'enum': 'OnOffSplit',
+  'data': [ 'on', 'off', 'split' ] }
 
 ##
-# @query-version:
-#
-# Returns the current version of QEMU.
+# @String:
 #
-# Returns:  A @VersionInfo object describing the current version of QEMU.
+# A fat type wrapping 'str', to be embedded in lists.
 #
-# Since: 0.14.0
+# Since: 1.2
 ##
-{ 'command': 'query-version', 'returns': 'VersionInfo' }
+{ 'struct': 'String',
+  'data': {
+    'str': 'str' } }
 
 ##
-# @CommandInfo:
+# @StrOrNull:
 #
-# Information about a QMP command
+# This is a string value or the explicit lack of a string (null
+# pointer in C).  Intended for cases when 'optional absent' already
+# has a different meaning.
 #
-# @name: The command name
+# @s: the string value
+# @n: no string value
 #
-# Since: 0.14.0
+# Since: 2.10
 ##
-{ 'struct': 'CommandInfo', 'data': {'name': 'str'} }
+{ 'alternate': 'StrOrNull',
+  'data': { 's': 'str',
+            'n': 'null' } }
 
 ##
-# @query-commands:
+# @OffAutoPCIBAR:
 #
-# Return a list of supported QMP commands by this server
+# An enumeration of options for specifying a PCI BAR
 #
-# Returns: A list of @CommandInfo for all supported commands
+# @off: The specified feature is disabled
 #
-# Since: 0.14.0
+# @auto: The PCI BAR for the feature is automatically selected
+#
+# @bar0: PCI BAR0 is used for the feature
+#
+# @bar1: PCI BAR1 is used for the feature
+#
+# @bar2: PCI BAR2 is used for the feature
+#
+# @bar3: PCI BAR3 is used for the feature
+#
+# @bar4: PCI BAR4 is used for the feature
+#
+# @bar5: PCI BAR5 is used for the feature
+#
+# Since: 2.12
 ##
-{ 'command': 'query-commands', 'returns': ['CommandInfo'] }
+{ 'enum': 'OffAutoPCIBAR',
+  'data': [ 'off', 'auto', 'bar0', 'bar1', 'bar2', 'bar3', 'bar4', 'bar5' ] }
 
 ##
-# @OnOffAuto
+# @PCIELinkSpeed:
 #
-# An enumeration of three options: on, off, and auto
+# An enumeration of PCIe link speeds in units of GT/s
 #
-# @auto: QEMU selects the value between on and off
+# @2_5: 2.5GT/s
 #
-# @on: Enabled
+# @5: 5.0GT/s
 #
-# @off: Disabled
+# @8: 8.0GT/s
 #
-# Since: 2.2
+# @16: 16.0GT/s
+#
+# Since: 4.0
 ##
-{ 'enum': 'OnOffAuto',
-  'data': [ 'auto', 'on', 'off' ] }
+{ 'enum': 'PCIELinkSpeed',
+  'data': [ '2_5', '5', '8', '16' ] }
 
 ##
-# @OnOffSplit
+# @PCIELinkWidth:
 #
-# An enumeration of three values: on, off, and split
+# An enumeration of PCIe link width
 #
-# @on: Enabled
+# @1: x1
 #
-# @off: Disabled
+# @2: x2
 #
-# @split: Mixed
+# @4: x4
 #
-# Since: 2.6
+# @8: x8
+#
+# @12: x12
+#
+# @16: x16
+#
+# @32: x32
+#
+# Since: 4.0
 ##
-{ 'enum': 'OnOffSplit',
-  'data': [ 'on', 'off', 'split' ] }
+{ 'enum': 'PCIELinkWidth',
+  'data': [ '1', '2', '4', '8', '12', '16', '32' ] }