You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
feat(block): advertise VIRTIO_BLK_F_WRITE_ZEROES for non-read-only devices
Set VIRTIO_BLK_F_WRITE_ZEROES in avail_features for any non-read-only
block device, alongside VIRTIO_BLK_F_DISCARD. Populate the
max_write_zeroes_sectors, max_write_zeroes_seg, and
write_zeroes_may_unmap config fields in both VirtioBlock::new() and
the persist::restore() path so the values match what the guest sees
on a fresh boot vs after a snapshot restore.
write_zeroes_may_unmap=1 lets the guest set the UNMAP flag on
individual segments, which we then translate to fallocate's
PUNCH_HOLE mode (UNMAP=0 uses ZERO_RANGE).
Update the test_virtio_features and test_virtio_read_config
expectations to account for the new feature bit and config fields.
Signed-off-by: Nikita Kalyazin <nikita.kalyazin@e2b.dev>
0 commit comments