mirror of
https://github.com/mii443/qemu.git
synced 2025-12-09 05:58:32 +00:00
block: Add PreallocMode to blk_truncate()
blk_truncate() itself will pass that value to bdrv_truncate(), and all callers of blk_truncate() just set the parameter to PREALLOC_MODE_OFF for now. Signed-off-by: Max Reitz <mreitz@redhat.com> Reviewed-by: Stefan Hajnoczi <stefanha@redhat.com> Message-id: 20170613202107.10125-4-mreitz@redhat.com Signed-off-by: Max Reitz <mreitz@redhat.com>
This commit is contained in:
@@ -2958,7 +2958,7 @@ void qmp_block_resize(bool has_device, const char *device,
|
||||
}
|
||||
|
||||
bdrv_drained_begin(bs);
|
||||
ret = blk_truncate(blk, size, errp);
|
||||
ret = blk_truncate(blk, size, PREALLOC_MODE_OFF, errp);
|
||||
bdrv_drained_end(bs);
|
||||
|
||||
out:
|
||||
|
||||
Reference in New Issue
Block a user