aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorPeter Maydell <peter.maydell@linaro.org>2015-09-25 19:01:46 +0100
committerPeter Maydell <peter.maydell@linaro.org>2015-09-25 19:01:46 +0100
commit54b376230c795d9f63490fa2e951cb786f7b1e12 (patch)
treeba0fc21bca0fceb7624c075b5a0d1df25584e911 /include
parent690b286fefa806f130dfc1931b5ba0b4dd2fb415 (diff)
parente6fd57ea297ec3aad32b24090c5d3757a99df3fe (diff)
Merge remote-tracking branch 'remotes/cody/tags/block-pull-request' into staging
# gpg: Signature made Fri 25 Sep 2015 16:47:31 BST using RSA key ID C0DE3057 # gpg: Good signature from "Jeffrey Cody <jcody@redhat.com>" # gpg: aka "Jeffrey Cody <jeff@codyprime.org>" # gpg: aka "Jeffrey Cody <codyprime@gmail.com>" * remotes/cody/tags/block-pull-request: sheepdog: refine discard support sheepdog: use per AIOCB dirty indexes for non overlapping requests Backup: don't do copy-on-read in before_write_notifier block: Introduce a new API bdrv_co_no_copy_on_readv() sheepdog: add reopen support block/nfs: cache allocated filesize for read-only files block/nfs: fix calculation of allocated file size Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'include')
-rw-r--r--include/block/block.h9
1 files changed, 6 insertions, 3 deletions
diff --git a/include/block/block.h b/include/block/block.h
index ef67353108..2dd66300ed 100644
--- a/include/block/block.h
+++ b/include/block/block.h
@@ -51,15 +51,16 @@ typedef struct BlockFragInfo {
} BlockFragInfo;
typedef enum {
- BDRV_REQ_COPY_ON_READ = 0x1,
- BDRV_REQ_ZERO_WRITE = 0x2,
+ BDRV_REQ_COPY_ON_READ = 0x1,
+ BDRV_REQ_ZERO_WRITE = 0x2,
/* The BDRV_REQ_MAY_UNMAP flag is used to indicate that the block driver
* is allowed to optimize a write zeroes request by unmapping (discarding)
* blocks if it is guaranteed that the result will read back as
* zeroes. The flag is only passed to the driver if the block device is
* opened with BDRV_O_UNMAP.
*/
- BDRV_REQ_MAY_UNMAP = 0x4,
+ BDRV_REQ_MAY_UNMAP = 0x4,
+ BDRV_REQ_NO_COPY_ON_READ = 0x8,
} BdrvRequestFlags;
typedef struct BlockSizes {
@@ -252,6 +253,8 @@ int coroutine_fn bdrv_co_readv(BlockDriverState *bs, int64_t sector_num,
int nb_sectors, QEMUIOVector *qiov);
int coroutine_fn bdrv_co_copy_on_readv(BlockDriverState *bs,
int64_t sector_num, int nb_sectors, QEMUIOVector *qiov);
+int coroutine_fn bdrv_co_no_copy_on_readv(BlockDriverState *bs,
+ int64_t sector_num, int nb_sectors, QEMUIOVector *qiov);
int coroutine_fn bdrv_co_writev(BlockDriverState *bs, int64_t sector_num,
int nb_sectors, QEMUIOVector *qiov);
/*