From 3d9f2d2af63fda5f0404fb85ea80161837a4e4e3 Mon Sep 17 00:00:00 2001 From: Kevin Wolf Date: Tue, 26 Jun 2018 13:55:20 +0200 Subject: block: Move bdrv_truncate() implementation to io.c This moves the bdrv_truncate() implementation from block.c to block/io.c so it can have access to the tracked requests infrastructure. This involves making refresh_total_sectors() public (in block_int.h). Signed-off-by: Kevin Wolf Reviewed-by: Stefan Hajnoczi --- include/block/block_int.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'include/block') diff --git a/include/block/block_int.h b/include/block/block_int.h index c653ee663a..740166a996 100644 --- a/include/block/block_int.h +++ b/include/block/block_int.h @@ -1157,4 +1157,6 @@ int coroutine_fn bdrv_co_copy_range_to(BdrvChild *src, uint64_t src_offset, BdrvChild *dst, uint64_t dst_offset, uint64_t bytes, BdrvRequestFlags flags); +int refresh_total_sectors(BlockDriverState *bs, int64_t hint); + #endif /* BLOCK_INT_H */ -- cgit v1.2.3