On 22.12.19 12:37, Alberto Garcia wrote: > The bdrv_co_pwrite_zeroes() call here fills complete clusters with > zeroes, but it can happen that some subclusters are not part of the > write request or the copy-on-write. This patch makes sure that only > the affected subclusters are overwritten. > > A potential improvement would be to also fill with zeroes the other > subclusters if we can guarantee that we are not overwriting existing > data. However this would waste more disk space, so we should first > evaluate if it's really worth doing. > > Signed-off-by: Alberto Garcia > --- > block/qcow2.c | 9 +++++---- > 1 file changed, 5 insertions(+), 4 deletions(-) Reviewed-by: Max Reitz