]> git.apps.os.sepia.ceph.com Git - xfstests-dev.git/commitdiff
xfstests: quota not supported on realtime filesystems
authorDave Chinner <dchinner@redhat.com>
Thu, 16 May 2013 11:52:05 +0000 (06:52 -0500)
committerRich Johnston <rjohnston@sgi.com>
Thu, 16 May 2013 11:52:05 +0000 (06:52 -0500)
Realtime XFS filesystems do not support quotas, so quota tests
always fail on such filesystems. Add a check to _require_quota to
detect this situation and notrun the quota tests...

Also, fix _require_xfs_quota and _require_prjquota to have the same
checks.

Signed-off-by: Dave Chinner <dchinner@redhat.com>
Reviewed-by: Rich Johnston <rjohnston@sgi.com>
Signed-off-by: Rich Johnston <rjohnston@sgi.com>
common/quota

index fd5374ffb958a10160ed4d9abaf58c277b3fd967..b320cf22d38bfe6ebdc7ec63dae43e3ff4d895f1 100644 (file)
@@ -40,6 +40,12 @@ _require_quota()
        if [ ! -f /proc/fs/xfs/xqmstat ]; then
            _notrun "Installed kernel does not support XFS quotas"
         fi
+       if [ "$USE_EXTERNAL" = yes -a ! -z "$TEST_RTDEV" ]; then
+           _notrun "Quotas not supported on realtime test device"
+       fi
+       if [ "$USE_EXTERNAL" = yes -a ! -z "$SCRATCH_RTDEV" ]; then
+           _notrun "Quotas not supported on realtime scratch device"
+       fi
        ;;
     *)
        _notrun "disk quotas not supported by this filesystem type: $FSTYP"
@@ -62,6 +68,12 @@ _require_xfs_quota()
 {
     src/feature -q $TEST_DEV
     [ $? -ne 0 ] && _notrun "Installed kernel does not support XFS quota"
+    if [ "$USE_EXTERNAL" = yes -a ! -z "$TEST_RTDEV" ]; then
+       _notrun "Quotas not supported on realtime test device"
+    fi
+    if [ "$USE_EXTERNAL" = yes -a ! -z "$SCRATCH_RTDEV" ]; then
+       _notrun "Quotas not supported on realtime scratch device"
+    fi
     [ -n $XFS_QUOTA_PROG ] || _notrun "XFS quota user tools not installed"
 }
 
@@ -73,6 +85,9 @@ _require_prjquota()
     [ -n "$1" ] && _dev="$1" || _dev="$TEST_DEV"
     src/feature -p $_dev
     [ $? -ne 0 ] && _notrun "Installed kernel does not support project quotas"
+    if [ "$USE_EXTERNAL" = yes -a ! -z "$_dev" ]; then
+       _notrun "Project quotas not supported on realtime filesystem"
+    fi
 }
 
 #