Hi,  BLKDISCARDZEROES won't work properly with scini devices - they do not guarantee  the zeroing out of discarded regions (this fact is published in the sysfs queue entries of our scini devices).  The reason for this lack of guarantee lies in the fact that any discard region that is not 1MB aligned in offset and size will be completed with “success” without any operation taking place (for example if you discard a single sector at some offset). So, let’s say you have data “A” in sector 0 of your volume and discard that single sector at offset 0 and then read that sector from offset 0, you will read data “A”.  The exception is when your discard is aligned to 1MB: if the discard region is 1M aligned in offset and size then we guarantee it will be zeroed; otherwise not.  Hope it helps! Cheers, Pawel
Hi to all!  Does scini devices supports BLKDISCARDZEROES ioctl call (queue/discard_zeroes_data in sysfs), i.e. guarantees that discarded blocks read back as zeroes?  I'm using ScaleIO R2_0.13000.211 on CentOS 7.2.1511 with kernel 3.10.0-327.36.3, and blkdiscard syscall works as expected: discarded blocks shows as 'trimmed capacity' and was immediately read back as zeroes. But BLKDISCARDZEROES ioctl call returns zero, which actually incorrect.
Blocks discarding and BLKDISCARDZEROES ioctl support