Log Message:
-----------
* jffs2.conf: sample jffs2 test configuration.
* jffs2-empty.img: dummy canned jffs2 image, made with mkfs.jffs2.
* run-tests (setup_lower, do_unmount): support jffs2.
* run-tests (wait4): support fractional delay time, including
sub-second (e.g., "sleep 0.5"). Also delay during setup time too
(needed to work around a race b/t the devfs and mtdblock drivers).
Tags:
----
LKML-branch
Modified Files:
--------------
unionfs/regression-2.0:
ChangeLog (r1.1.2.19 -> r1.1.2.20)
default.conf (r1.1.2.4 -> r1.1.2.5)
run-tests (r1.1.2.8 -> r1.1.2.9)
Added Files:
-----------
unionfs/regression-2.0:
jffs2-empty.img (r1.1.2.1)
jffs2.conf (r1.1.2.1)
Revision Data
-------------
Index: default.conf
===================================================================
RCS file: /home/cvs/unionfs/unionfs/regression-2.0/Attic/default.conf,v
retrieving revision 1.1.2.4
retrieving revision 1.1.2.5
diff -Lregression-2.0/default.conf -Lregression-2.0/default.conf -u -d -b -B -p
-r1.1.2.4 -r1.1.2.5
--- regression-2.0/default.conf
+++ regression-2.0/default.conf
@@ -36,10 +36,10 @@ BROKEN_TESTS="
TESTS2RUN=${MYTESTS:-$ALL_TESTS}
# name of four devices to use
-DEV0=/dev/loop1
-DEV1=/dev/loop2
-DEV2=/dev/loop3
-DEV3=/dev/loop4
+DEV0=/dev/loop0
+DEV1=/dev/loop1
+DEV2=/dev/loop2
+DEV3=/dev/loop3
# name of file systems to format four device
FS0=ext2
FS1=ext2
Index: ChangeLog
===================================================================
RCS file: /home/cvs/unionfs/unionfs/regression-2.0/Attic/ChangeLog,v
retrieving revision 1.1.2.19
retrieving revision 1.1.2.20
diff -Lregression-2.0/ChangeLog -Lregression-2.0/ChangeLog -u -d -b -B -p
-r1.1.2.19 -r1.1.2.20
--- regression-2.0/ChangeLog
+++ regression-2.0/ChangeLog
@@ -1,3 +1,15 @@
+2007-05-23 Erez Zadok <[EMAIL PROTECTED]>
+
+ * jffs2.conf: sample jffs2 test configuration.
+
+ * jffs2-empty.img: dummy canned jffs2 image, made with mkfs.jffs2.
+
+ * run-tests (setup_lower, do_unmount): support jffs2.
+
+ * run-tests (wait4): support fractional delay time, including
+ sub-second (e.g., "sleep 0.5"). Also delay during setup time too
+ (needed to work around a race b/t the devfs and mtdblock drivers).
+
2007-05-22 Erez Zadok <[EMAIL PROTECTED]>
* nfs.conf: an all-NFS sample configuration.
Index: run-tests
===================================================================
RCS file: /home/cvs/unionfs/unionfs/regression-2.0/Attic/run-tests,v
retrieving revision 1.1.2.8
retrieving revision 1.1.2.9
diff -Lregression-2.0/run-tests -Lregression-2.0/run-tests -u -d -b -B -p
-r1.1.2.8 -r1.1.2.9
--- regression-2.0/run-tests
+++ regression-2.0/run-tests
@@ -45,14 +45,9 @@ done
# pretty sleep command
function wait4
{
- count=$delay
- echo -n "Sleep for "
- while test $count -gt 0 ; do
- echo -n "$count.."
- sleep 1
- let count=count-1
- done
- echo '0!'
+ echo -n "Sleep for "$delay" seconds..."
+ sleep $delay
+ echo '!'
}
# run command verbosely plus optional delay
function runcmd
@@ -78,9 +73,17 @@ function setup_lower
case "$dev" in
/dev/loop*)
+ case "$fs" in
+ jffs2 )
+ runcmd cp jffs2-empty.img /tmp/fs.$$.$i
+ runcmd losetup $dev /tmp/fs.$$.$i
+ ;;
+ * )
runcmd dd if=/dev/zero of=/tmp/fs.$$.$i bs=1024k
count=1 seek=100 2> /dev/null
runcmd losetup $dev /tmp/fs.$$.$i
;;
+ esac
+ ;;
*)
;;
esac
@@ -95,6 +98,11 @@ function setup_lower
runcmd mkdir -p /n/lower/b$i
runcmd mount -t $fs localhost:/n/export/b$i /n/lower/b$i
;;
+ jffs2 )
+ runcmd modprobe mtdblock
+ runcmd modprobe block2mtd block2mtd=$dev,128ki
+ runcmd mount -t $fs /dev/mtdblock$i /n/lower/b$i
+ ;;
* )
runcmd mkfs -t $fs -q $dev
runcmd mkdir -p /n/lower/b$i
@@ -111,7 +119,9 @@ function do_umount
dev=$2
fs=$3
+ # first, unmount main branch
runcmd umount /n/lower/b$branch
+
case "$fs" in
nfs* )
runcmd exportfs -u localhost:/n/export/b$branch
@@ -117,6 +127,10 @@ function do_umount
runcmd exportfs -u localhost:/n/export/b$branch
runcmd umount /n/export/b$branch
;;
+ jffs2 )
+ runcmd rmmod block2mtd
+ runcmd rmmod mtdblock
+ ;;
* )
;;
esac
@@ -149,9 +163,8 @@ do
exit 1
fi
- unset delay
- setup_lower
delay=$DELAY
+ setup_lower
# run actual test and abort on error (test script tries to umount unionfs)
runcmd bash $t
--- /dev/null
+++ regression-2.0/jffs2.conf
@@ -0,0 +1,92 @@
+# default Unionfs 2.0 regression configuration file
+
+# names of all possible tests
+# Note: you can give full name of test (t-chmod.sh) or short (chmod)
+ALL_TESTS="
+ t-chmod.sh
+ t-creat-open.sh
+ t-create.sh
+ t-flock.sh
+ t-fsync.sh
+ t-link-rename.sh
+ t-link.sh
+ t-lookup-opaque.sh
+ t-lookup.sh
+ t-mkdir.sh
+ t-mknod.sh
+ t-mmap.sh
+ t-open-unlink.sh
+ t-open.sh
+ t-readdir.sh
+ t-rename-matrix.sh
+ t-rename-whiteout.sh
+ t-symlink.sh
+ t-truncate-all.sh
+ t-unlink-whiteout.sh
+"
+
+# The branch-management test is "broken" and needs to be rewritten to
+# support the new remount-style -ezk.
+BROKEN_TESTS="
+ t-branchman.sh
+ t-incgen.sh
+"
+# names of tests to run (change as you like)
+# Will take $MYTESTS list of tests from the environment
+TESTS2RUN=${MYTESTS:-$ALL_TESTS}
+
+# name of four devices to use
+DEV0=/dev/loop0
+DEV1=/dev/loop1
+DEV2=/dev/loop2
+DEV3=/dev/loop3
+# name of file systems to format four device
+FS0=jffs2
+FS1=ext2
+FS2=ext2
+FS3=ext2
+
+# delay between each test (in seconds, optional)
+DELAY=1
+
+# Echo the command being executed to a file/device (optional) This is useful
+# when unionfs printk's some debugging output which may go to a log file,
+# console, or syslog. With this you can show command in your logs before it
+# runs.
+#ECHODEV=/var/log/all
+ECHODEV=/dev/console
+
+# ANSI color codes, concatinated by ';'
+#
+# 00 for normal display (or just 0)
+# 01 for bold on (or just 1)
+# 02 faint (or just 2)
+# 03 standout (or just 3)
+# 04 underline (or just 4)
+# 05 blink on (or just 5)
+# 07 reverse video on (or just 7)
+# 08 nondisplayed (invisible) (or just 8)
+# 22 normal
+# 23 no-standout
+# 24 no-underline
+# 25 no-blink
+# 27 no-reverse
+# 30 black foreground
+# 31 red foreground
+# 32 green foreground
+# 33 yellow foreground
+# 34 blue foreground
+# 35 magenta foreground
+# 36 cyan foreground
+# 37 white foreground
+# 39 default foreground
+# 40 black background
+# 41 red background
+# 42 green background
+# 43 yellow background
+# 44 blue background
+# 45 magenta background
+# 46 cyan background
+# 47 white background
+# 49 default background
+OUTPUT_COLOR="1;32"
_______________________________________________
unionfs-cvs mailing list: http://unionfs.filesystems.org/
[email protected]
http://www.fsl.cs.sunysb.edu/mailman/listinfo/unionfs-cvs