generic/009: fix test failure with overlay over ext4
authorAmir Goldstein <amir73il@gmail.com>
Mon, 27 Aug 2018 18:29:26 +0000 (21:29 +0300)
committerEryu Guan <guaneryu@gmail.com>
Sat, 1 Sep 2018 17:13:27 +0000 (01:13 +0800)
When running test with overlayfs and ext4 as base fs, we need to
disable extent zeroout on the underlying base fs.

Signed-off-by: Amir Goldstein <amir73il@gmail.com>
Reviewed-by: Eryu Guan <guaneryu@gmail.com>
Signed-off-by: Eryu Guan <guaneryu@gmail.com>
tests/generic/009

index fa6ef4664c66dd091195d2430e5e309cc8f267ca..a4f56d0473d79340df80f7dce8d40f7a11865607 100755 (executable)
@@ -39,6 +39,9 @@ testfile=$TEST_DIR/009.$$
 if [ "$FSTYP" = "ext4" ]; then
        _ext4_disable_extent_zeroout
 fi
+if [ "$FSTYP" = "overlay" -a "$OVL_BASE_FSTYP" = "ext4" ]; then
+       _ext4_disable_extent_zeroout "$OVL_BASE_TEST_DEV"
+fi
 
 # When PAGE_SIZE > 4096 some filesystems extent layout is different so
 # it would not match the output.