diff mbox series

[v2,7/9] block/file-posix: drop unallocated_blocks_are_zero

Message ID 20200507084800.20596-8-vsementsov@virtuozzo.com
State Superseded
Headers show
Series [v2,1/9] qemu-img: convert: don't use unallocated_blocks_are_zero | expand

Commit Message

Vladimir Sementsov-Ogievskiy May 7, 2020, 8:47 a.m. UTC
raw_co_block_status() in block/file-posix.c never returns 0, so
unallocated_blocks_are_zero is useless (it doesn't affect the only user
of the field: bdrv_co_block_status()). Drop it.

Signed-off-by: Vladimir Sementsov-Ogievskiy <vsementsov@virtuozzo.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
---
 block/file-posix.c | 3 ---
 1 file changed, 3 deletions(-)
diff mbox series

Patch

diff --git a/block/file-posix.c b/block/file-posix.c
index 05e094be29..5c01735108 100644
--- a/block/file-posix.c
+++ b/block/file-posix.c
@@ -2878,9 +2878,6 @@  static int coroutine_fn raw_co_pwrite_zeroes(
 
 static int raw_get_info(BlockDriverState *bs, BlockDriverInfo *bdi)
 {
-    BDRVRawState *s = bs->opaque;
-
-    bdi->unallocated_blocks_are_zero = s->discard_zeroes;
     return 0;
 }