>From Linux kernel's Documentation/filesystems/fiemap.txt,

* FIEMAP_EXTENT_NOT_ALIGNED
Extent offsets and length are not guaranteed to be block aligned.

So this means that FIEMAP_EXTENT_NOT_ALIGNED is just a hint that indicates
that the extent range could possibly be out of alignment w.r.t to the
filesystem's blocksize. It should still be possible for fiemap ioctl to return
extents with FIEMAP_EXTENT_NOT_ALIGNED flag set (e.g. Inline extents) but
which have blocksize aligned ranges.

Signed-off-by: Chandan Rajendra <[email protected]>
---
 src/fiemap-tester.c | 11 -----------
 1 file changed, 11 deletions(-)

diff --git a/src/fiemap-tester.c b/src/fiemap-tester.c
index 8e633ab..74dea17 100644
--- a/src/fiemap-tester.c
+++ b/src/fiemap-tester.c
@@ -195,17 +195,6 @@ check_flags(struct fiemap *fiemap, int blocksize)
                        return -1;
                }
 
-               if (extent->fe_flags & FIEMAP_EXTENT_NOT_ALIGNED &&
-                   aligned_offset == extent->fe_physical &&
-                   aligned_length == extent->fe_length) {
-                       printf("ERROR: FIEMAP_EXTENT_NOT_ALIGNED is set but "
-                              "offset and length is blocksize aligned: "
-                              "%llu\n",
-                              (unsigned long long)
-                              (extent->fe_logical / blocksize));
-                       return -1;
-               }
-
                if (extent->fe_flags & FIEMAP_EXTENT_LAST &&
                    c + 1 < fiemap->fm_mapped_extents) {
                        printf("ERROR: FIEMAP_EXTENT_LAST is set but there are"
-- 
2.1.0

--
To unsubscribe from this list: send the line "unsubscribe fstests" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to