common/rc: skip encrypted direct I/O tests on f2fs
[xfstests-dev.git] / common / rc
index 2cb041afb6c594285e8e2698f529d7debf4c5a74..a2a28f321ad6e4d0366c4c9527085924b78347c8 100644 (file)
--- a/common/rc
+++ b/common/rc
@@ -2224,10 +2224,13 @@ _require_xfs_io_command()
 # check that kernel and filesystem support direct I/O
 _require_odirect()
 {
-       if [ $FSTYP = "ext4" ] ; then
+       if [ $FSTYP = "ext4" ] || [ $FSTYP = "f2fs" ] ; then
                if echo "$MOUNT_OPTIONS" | grep -q "test_dummy_encryption"; then
-                       _notrun "ext4 encryption doesn't support O_DIRECT"
-               elif echo "$MOUNT_OPTIONS" | grep -q "data=journal"; then
+                       _notrun "$FSTYP encryption doesn't support O_DIRECT"
+               fi
+       fi
+       if [ $FSTYP = "ext4" ] ; then
+               if echo "$MOUNT_OPTIONS" | grep -q "data=journal"; then
                        _notrun "ext4 data journaling doesn't support O_DIRECT"
                fi
        fi