aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
Diffstat (limited to 'include')
-rw-r--r--include/block/block-io.h5
-rw-r--r--include/block/block_int-common.h15
-rw-r--r--include/block/block_int-io.h2
3 files changed, 13 insertions, 9 deletions
diff --git a/include/block/block-io.h b/include/block/block-io.h
index 7e96506138..627061fd5f 100644
--- a/include/block/block-io.h
+++ b/include/block/block-io.h
@@ -103,8 +103,9 @@ bdrv_co_ioctl(BlockDriverState *bs, int req, void *buf);
/* Ensure contents are flushed to disk. */
int coroutine_fn GRAPH_RDLOCK bdrv_co_flush(BlockDriverState *bs);
-int coroutine_fn bdrv_co_pdiscard(BdrvChild *child, int64_t offset,
- int64_t bytes);
+int coroutine_fn GRAPH_RDLOCK bdrv_co_pdiscard(BdrvChild *child, int64_t offset,
+ int64_t bytes);
+
bool bdrv_can_write_zeroes_with_unmap(BlockDriverState *bs);
int bdrv_block_status(BlockDriverState *bs, int64_t offset,
int64_t bytes, int64_t *pnum, int64_t *map,
diff --git a/include/block/block_int-common.h b/include/block/block_int-common.h
index 51eaabd9d1..c52190abdb 100644
--- a/include/block/block_int-common.h
+++ b/include/block/block_int-common.h
@@ -479,8 +479,9 @@ struct BlockDriver {
BdrvRequestFlags flags, BlockCompletionFunc *cb, void *opaque);
BlockAIOCB * GRAPH_RDLOCK_PTR (*bdrv_aio_flush)(
BlockDriverState *bs, BlockCompletionFunc *cb, void *opaque);
- BlockAIOCB *(*bdrv_aio_pdiscard)(BlockDriverState *bs,
- int64_t offset, int bytes,
+
+ BlockAIOCB * GRAPH_RDLOCK_PTR (*bdrv_aio_pdiscard)(
+ BlockDriverState *bs, int64_t offset, int bytes,
BlockCompletionFunc *cb, void *opaque);
int coroutine_fn (*bdrv_co_readv)(BlockDriverState *bs,
@@ -543,8 +544,9 @@ struct BlockDriver {
*/
int coroutine_fn (*bdrv_co_pwrite_zeroes)(BlockDriverState *bs,
int64_t offset, int64_t bytes, BdrvRequestFlags flags);
- int coroutine_fn (*bdrv_co_pdiscard)(BlockDriverState *bs,
- int64_t offset, int64_t bytes);
+
+ int coroutine_fn GRAPH_RDLOCK_PTR (*bdrv_co_pdiscard)(
+ BlockDriverState *bs, int64_t offset, int64_t bytes);
/*
* Map [offset, offset + nbytes) range onto a child of @bs to copy from,
@@ -632,8 +634,9 @@ struct BlockDriver {
int coroutine_fn (*bdrv_co_snapshot_block_status)(BlockDriverState *bs,
bool want_zero, int64_t offset, int64_t bytes, int64_t *pnum,
int64_t *map, BlockDriverState **file);
- int coroutine_fn (*bdrv_co_pdiscard_snapshot)(BlockDriverState *bs,
- int64_t offset, int64_t bytes);
+
+ int coroutine_fn GRAPH_RDLOCK_PTR (*bdrv_co_pdiscard_snapshot)(
+ BlockDriverState *bs, int64_t offset, int64_t bytes);
/*
* Invalidate any cached meta-data.
diff --git a/include/block/block_int-io.h b/include/block/block_int-io.h
index 4430bf4c4a..4bb6ccaa34 100644
--- a/include/block/block_int-io.h
+++ b/include/block/block_int-io.h
@@ -40,7 +40,7 @@ int coroutine_fn bdrv_co_preadv_snapshot(BdrvChild *child,
int coroutine_fn bdrv_co_snapshot_block_status(BlockDriverState *bs,
bool want_zero, int64_t offset, int64_t bytes, int64_t *pnum,
int64_t *map, BlockDriverState **file);
-int coroutine_fn bdrv_co_pdiscard_snapshot(BlockDriverState *bs,
+int coroutine_fn GRAPH_RDLOCK bdrv_co_pdiscard_snapshot(BlockDriverState *bs,
int64_t offset, int64_t bytes);