OSDN Git Service

qcow2: Implement .bdrv_co_preadv()
authorKevin Wolf <kwolf@redhat.com>
Tue, 31 May 2016 14:13:07 +0000 (16:13 +0200)
committerKevin Wolf <kwolf@redhat.com>
Thu, 16 Jun 2016 13:19:55 +0000 (15:19 +0200)
commitecfe186380e6fc3a556dff05b866ca213e277fc7
treeaf40bff28dc5d95f4a6c107fb3a59c4863b2caaa
parentb2f65d6b02b7df0a780a974a97f26fbf0e464964
qcow2: Implement .bdrv_co_preadv()

Reading from qcow2 images is now byte granularity.

Most of the affected code in qcow2 actually gets simpler with this
change. The only exception is encryption, which is fixed on 512 bytes
blocks; in order to keep this working, bs->request_alignment is set for
encrypted images.

Signed-off-by: Kevin Wolf <kwolf@redhat.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
block/qcow2-cluster.c
block/qcow2.c
block/qcow2.h