qcow2: Add corrupt bit

This adds an incompatible bit indicating corruption to qcow2. Any image
with this bit set may not be written to unless for repairing (and
subsequently clearing the bit if the repair has been successful).

Signed-off-by: Max Reitz <mreitz@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
This commit is contained in:
Max Reitz 2013-08-30 14:34:24 +02:00 committed by Kevin Wolf
parent 449df70638
commit 69c9872653
5 changed files with 66 additions and 9 deletions

View file

@ -80,7 +80,12 @@ in the description of a field.
tables to repair refcounts before accessing the
image.
Bits 1-63: Reserved (set to 0)
Bit 1: Corrupt bit. If this bit is set then any data
structure may be corrupt and the image must not
be written to (unless for regaining
consistency).
Bits 2-63: Reserved (set to 0)
80 - 87: compatible_features
Bitmask of compatible features. An implementation can