summary refs log tree commit diff
path: root/devices/src
diff options
context:
space:
mode:
authorDaniel Verkamp <dverkamp@chromium.org>2018-08-23 10:00:06 -0700
committerchrome-bot <chrome-bot@chromium.org>2018-09-05 01:25:50 -0700
commit9c7cd8632563ba50d1b0452b2ac1a8defd63e5f3 (patch)
tree0c3b3dadd977ffe0071622f6316bb7642d61db98 /devices/src
parent95a8868aef2c1018b13b30f3afc2e11bb3ae2066 (diff)
downloadcrosvm-9c7cd8632563ba50d1b0452b2ac1a8defd63e5f3.tar
crosvm-9c7cd8632563ba50d1b0452b2ac1a8defd63e5f3.tar.gz
crosvm-9c7cd8632563ba50d1b0452b2ac1a8defd63e5f3.tar.bz2
crosvm-9c7cd8632563ba50d1b0452b2ac1a8defd63e5f3.tar.lz
crosvm-9c7cd8632563ba50d1b0452b2ac1a8defd63e5f3.tar.xz
crosvm-9c7cd8632563ba50d1b0452b2ac1a8defd63e5f3.tar.zst
crosvm-9c7cd8632563ba50d1b0452b2ac1a8defd63e5f3.zip
qcow: deallocate clusters in write_zeroes
When a write_zeroes call covers a whole cluster, we can deallocate the
storage for that cluster rather than writing zeroes.

This is currently implemented by removing the cluster allocation from
the mapping tables, then attempting to release the backing storage using
fallocate() with FALLOC_FL_PUNCH_HOLE.

BUG=chromium:850998
TEST=cargo test -p qcow

Change-Id: Ie4edb2e02bfaa1df9a19919b77eeb3c58c112d1c
Signed-off-by: Daniel Verkamp <dverkamp@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/1187019
Reviewed-by: Dylan Reid <dgreid@chromium.org>
Diffstat (limited to 'devices/src')
0 files changed, 0 insertions, 0 deletions