summaryrefslogtreecommitdiff
path: root/qapi-schema.json
diff options
context:
space:
mode:
authorPaolo Bonzini <pbonzini@redhat.com>2013-09-04 19:00:34 +0200
committerStefan Hajnoczi <stefanha@redhat.com>2013-09-06 15:25:09 +0200
commitfacd6e2b5c0217f9d9eeb2ee497dda28009518bd (patch)
treed714230b019c9a89665a0acdbadef9ee9b0cf4cf /qapi-schema.json
parent4c93a13b5daf9bd5fca1a547661b0fb9a2f0ca52 (diff)
downloadqemu-facd6e2b5c0217f9d9eeb2ee497dda28009518bd.tar.gz
docs, qapi: document qemu-img map
Eric Blake also requested including the output in qapi-schema.json, so that it is published through the introspection mechanism. Signed-off-by: Paolo Bonzini <pbonzini@redhat.com> Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
Diffstat (limited to 'qapi-schema.json')
-rw-r--r--qapi-schema.json29
1 files changed, 29 insertions, 0 deletions
diff --git a/qapi-schema.json b/qapi-schema.json
index 5d5164f9e2..2b2c8bce07 100644
--- a/qapi-schema.json
+++ b/qapi-schema.json
@@ -831,6 +831,35 @@
{ 'enum': 'BlockDeviceIoStatus', 'data': [ 'ok', 'failed', 'nospace' ] }
##
+# @BlockDeviceMapEntry:
+#
+# Entry in the metadata map of the device (returned by "qemu-img map")
+#
+# @start: Offset in the image of the first byte described by this entry
+# (in bytes)
+#
+# @length: Length of the range described by this entry (in bytes)
+#
+# @depth: Number of layers (0 = top image, 1 = top image's backing file, etc.)
+# before reaching one for which the range is allocated. The value is
+# in the range 0 to the depth of the image chain - 1.
+#
+# @zero: the sectors in this range read as zeros
+#
+# @data: reading the image will actually read data from a file (in particular,
+# if @offset is present this means that the sectors are not simply
+# preallocated, but contain actual data in raw format)
+#
+# @offset: if present, the image file stores the data for this range in
+# raw format at the given offset.
+#
+# Since 1.7
+##
+{ 'type': 'BlockDeviceMapEntry',
+ 'data': { 'start': 'int', 'length': 'int', 'depth': 'int', 'zero': 'bool',
+ 'data': 'bool', '*offset': 'int' } }
+
+##
# @BlockDirtyInfo:
#
# Block dirty bitmap information.