xfstests 068: Add mmap load
authorEric Sandeen <sandeen@redhat.com>
Fri, 28 Sep 2012 03:33:45 +0000 (03:33 +0000)
committerMark Tinguely <tinguely@eagdhcp-232-125.americas.sgi.com>
Mon, 1 Oct 2012 13:40:19 +0000 (08:40 -0500)
Test 068 is the go-to test for freeze deadlock coverage;
unfortunately it only uses fsstress, which doesn't do any
mmap IO.

Using the existing fstest binary gets us a cheap mmap
exerciser as well.

Signed-off-by: Eric Sandeen <sandeen@redhat.com>
Reviewed-by: Dave Chinner <dchinner@redhat.com>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Mark Tinguely <tinguely@sgi.com>
068

diff --git a/068 b/068
index 617420cf1f5dd5e80341c8ecef9affddefddb50d..a641e2f7d4f12df650eb8150a068c0cb42f7f603 100755 (executable)
--- a/068
+++ b/068
@@ -90,6 +90,21 @@ touch $tmp.running
     rmdir $STRESS_DIR
 } &
 
     rmdir $STRESS_DIR
 } &
 
+# start fstest -m loop in a background block; this gets us mmap coverage
+{
+    FSTEST_DIR="$SCRATCH_MNT/fstest_test_dir"
+    mkdir "$FSTEST_DIR"
+
+    procs=2
+    while [ -f "$tmp.running" ]
+      do
+      src/fstest -m -p $FSTEST_DIR  -n $procs -f 4 > /dev/null 2>&1
+    done
+
+    rm -rf $FSTEST_DIR/*
+    rmdir $FSTEST_DIR
+} &
+
 i=0
 let ITERATIONS=$ITERATIONS-1
 
 i=0
 let ITERATIONS=$ITERATIONS-1