]> git.apps.os.sepia.ceph.com Git - xfstests-dev.git/commit
src/seek_sanity_test: Fix for filesystems without unwritten extent support
authorAndreas Gruenbacher <agruenba@redhat.com>
Fri, 23 Jun 2017 13:32:14 +0000 (15:32 +0200)
committerEryu Guan <eguan@redhat.com>
Mon, 26 Jun 2017 07:20:14 +0000 (15:20 +0800)
commitd1df9deaaba34c8cd50d516a99dd55aa77b97c0a
treed6113d0b979fcd9cc58060408bbf9d2b08251a63
parentd8e5df11f2b6daed41b73f477e46a5a96ed7feb4
src/seek_sanity_test: Fix for filesystems without unwritten extent support

src/seek_sanity_test assumes that after preallocating space in a
file with fallocate, fseek SEEK_HOLE / SEEK_DATA will still report
the allocated space as a hole.  On filesystems without unwritten
extent support, that space will be reported as data, though.  On
such filesystems, skip the unwritten extent tests.

Tested on ext4, xfs, and gfs2 + patches for fseek SEEK_HOLE /
SEEK_DATA support.

Signed-off-by: Andreas Gruenbacher <agruenba@redhat.com>
Reviewed-by: Eryu Guan <eguan@redhat.com>
Signed-off-by: Eryu Guan <eguan@redhat.com>
src/seek_sanity_test.c