21.04.2020 13:50, Alberto Garcia wrote:
On Tue 21 Apr 2020 10:47:17 AM CEST, Vladimir Sementsov-Ogievskiy
<[email protected]> wrote:
+ if ((flags & BDRV_REQ_ZERO_WRITE) && offset > old_length) {
+ ret = qcow2_cluster_zeroize(bs, old_length, offset - old_length, 0);
Hmm. As I understand, qcow2_cluster_zeroize is unprepared to
cluster-unaligned offset/size. I think we should handle it somehow.
You're right, it actually hits an assertion :-/
I suppose you can simply round the size up to the next cluster.
But we also need to handle unaligned old_length, we can't just align it down,
we should write zero to existing cluster if it is NORMAL cluster..
--
Best regards,
Vladimir