common: add CephFS support
[xfstests-dev.git] / common / rc
index a84efe49cbf4e2991b3ea6d541ec0c7cd81b9382..e3b54ecb5df25e1c1196b948969113f3c3588b1a 100644 (file)
--- a/common/rc
+++ b/common/rc
@@ -147,6 +147,8 @@ case "$FSTYP" in
         ;;
     cifs)
         ;;
+    ceph)
+        ;;
     overlay)
         ;;
     reiser4)
@@ -705,6 +707,9 @@ _test_mkfs()
     cifs)
        # do nothing for cifs
        ;;
+    ceph)
+       # do nothing for ceph
+       ;;
     overlay)
        # do nothing for overlay
        ;;
@@ -791,6 +796,10 @@ _scratch_mkfs()
        # avoid EEXIST caused by the leftover files created in previous runs
         _scratch_cleanup_files
        ;;
+    ceph)
+       # Don't re-create CephFS, just remove all files
+       _scratch_cleanup_files
+       ;;
     overlay)
        # unable to re-create overlay, remove all files in $SCRATCH_MNT to
        # avoid EEXIST caused by the leftover files created in previous runs
@@ -1490,7 +1499,7 @@ _reload_btrfs_ko()
 _require_scratch_nocheck()
 {
     case "$FSTYP" in
-       nfs*)
+       nfs*|ceph)
                echo $SCRATCH_DEV | grep -q ":/" > /dev/null 2>&1
                if [ -z "$SCRATCH_DEV" -o "$?" != "0" ]; then
                        _notrun "this test requires a valid \$SCRATCH_DEV"
@@ -1575,10 +1584,10 @@ _require_scratch()
 _require_test()
 {
     case "$FSTYP" in
-       nfs*)
+       nfs*|ceph)
                echo $TEST_DEV | grep -q ":/" > /dev/null 2>&1
                if [ -z "$TEST_DEV" -o "$?" != "0" ]; then
-                       _notrun "this test requires a valid \$TEST_DIR"
+                       _notrun "this test requires a valid \$TEST_DEV"
                fi
                if [ ! -d "$TEST_DIR" ]; then
                        _notrun "this test requires a valid \$TEST_DIR"
@@ -2658,6 +2667,9 @@ _check_test_fs()
     cifs)
        # no way to check consistency for cifs
        ;;
+    ceph)
+       # no way to check consistency for CephFS
+       ;;
     overlay)
        # no way to check consistency for overlay
        ;;
@@ -2702,6 +2714,9 @@ _check_scratch_fs()
     cifs)
        # Don't know how to check a CIFS filesystem, yet.
        ;;
+    ceph)
+       # no way to check consistency for CephFS
+       ;;
     overlay)
        # no way to check consistency for overlay
        ;;