Allow to specify unsupported file systems
PATCH 1/2 Allow to specify unsupported file systems
As an addition to checking for supported file systems it would be nice to be able to specify unsupported file system. In combination with "generic" fs it can be useful. This patch adds that feature. For example to set ext3 as an unsupported fs add "!ext3" into list.
Also specify ext3 and ex4 as unsupported file systems in 213 and 214 since those fs does not support fallocate. There may be others though.
--- 213 | 2 +- 214 | 2 +- common.rc | 22 +++++++++++++++++----- 3 files changed, 19 insertions(+), 7 deletions(-)
213 +1 -1
@@ -47,7 +47,7 @@ trap "_cleanup; exit \$status" 0 1 2 3 15 # real QA test starts here # generic, but xfs_io's fallocate must work -_supported_fs generic +_supported_fs generic !ext3 !ext3 # only Linux supports fallocate _supported_os Linux
214 +1 -1
@@ -45,7 +45,7 @@ trap "_cleanup; exit \$status" 0 1 2 3 15 # real QA test starts here # generic, but xfs_io's fallocate must work -_supported_fs generic +_supported_fs generic !ext3 !ext2 # only Linux supports fallocate _supported_os Linux
common.rc +17 -5
@@ -656,15 +656,27 @@ _fail() # _supported_fs() { + supp=0 for f do - if [ "$f" = "$FSTYP" -o "$f" = "generic" ] - then - return - fi + if [ "$f" = \!"$FSTYP" ] + then + supp=0 + break + fi + + if [ "$f" = "$FSTYP" -o "$f" = "generic" ] + then + supp=1 + fi done - _notrun "not suitable for this filesystem type: $FSTYP" + if [ $supp -eq 1 ] + then + return + else + _notrun "not suitable for this filesystem type: $FSTYP" + fi } # tests whether $FSTYP is one of the supported OSes for a test
Signature · 6 lines
1.7.1.1 _______________________________________________ xfs mailing list [email protected] http://oss.sgi.com/mailman/listinfo/xfs
PATCH 2/2 Show duration of current test
It may be useful to compare both times, last and current, in the xfstests output.
--- check | 3 ++- 1 files changed, 2 insertions(+), 1 deletions(-)
check +2 -1
@@ -275,13 +275,14 @@ do else if diff $seq.out $tmp.out >/dev/null 2>&1 then - echo "" if $err then : else echo "$seq `expr $stop - $start`" >>$tmp.time + echo -n " `expr $stop - $start`s" fi + echo "" else echo " - output mismatch (see $seq.out.bad)" mv $tmp.out $seq.out.bad
Signature · 6 lines
1.7.1.1 _______________________________________________ xfs mailing list [email protected] http://oss.sgi.com/mailman/listinfo/xfs
Quoted 4 lines · Lukas Czerner
As an addition to checking for supported file systems it would be nice to be able to specify unsupported file system. In combination with "generic" fs it can be useful. This patch adds that feature. For example to set ext3 as an unsupported fs add "!ext3" into list.
Interesting idea, I agree it could be useful to exclude rather than have to enumerate everything.
I don't think there's any need to make use of it except where needed--i.e., don't go changing things, just use it where it fits from here on.
One comment below.
Quoted 15 lines
Also specify ext3 and ex4 as unsupported file systems in 213 and 214 since those fs does not support fallocate. There may be others though.
Signed-off-by Lukas Czerner <[email protected]>--- 213 | 2 +- 214 | 2 +- common.rc | 22 +++++++++++++++++----- 3 files changed, 19 insertions(+), 7 deletions(-)213 +0
-0
213 trap "_cleanup; exit \$status" 0 1 2 3 15 · line 50
Quoted 5 lines
213 +1
-1@@ -47,7 +47,7 @@ trap "_cleanup; exit \$status" 0 1 2 3 15 # real QA test starts here # generic, but xfs_io's fallocate must work -_supported_fs generic +_supported_fs generic !ext3 !ext3
Did you mean !ext2 for the second one here?
Quoted 43 lines
213 +0
-0# only Linux supports fallocate _supported_os Linux214 +1
-1@@ -45,7 +45,7 @@ trap "_cleanup; exit \$status" 0 1 2 3 15 # real QA test starts here # generic, but xfs_io's fallocate must work -_supported_fs generic +_supported_fs generic !ext3 !ext2 # only Linux supports fallocate _supported_os Linuxcommon.rc +11
-4@@ -656,15 +656,27 @@ _fail() # _supported_fs() { + supp=0 for f do - if [ "$f" = "$FSTYP" -o "$f" = "generic" ] - then - return - fi + if [ "$f" = \!"$FSTYP" ] + then + supp=0 + break + fi + + if [ "$f" = "$FSTYP" -o "$f" = "generic" ] + then + supp=1 + fi done
common.rc _fail() · line 682
Quoted 10 lines
common.rc +6
-1- _notrun "not suitable for this filesystem type: $FSTYP" + if [ $supp -eq 1 ] + then + return + else + _notrun "not suitable for this filesystem type: $FSTYP" + fi } # tests whether $FSTYP is one of the supported OSes for a test
_______________________________________________
xfs mailing list
[email protected]
http://oss.sgi.com/mailman/listinfo/xfs
Re: [PATCH 2/2] Show duration of current test
In reply to Lukas CzernerQuoted 2 lines · Lukas Czerner
It may be useful to compare both times, last and current, in the xfstests output.
This one looks good.
Quoted 15 lines
Signed-off-by Lukas Czerner <[email protected]>--- check | 3 ++- 1 files changed, 2 insertions(+), 1 deletions(-)check +0
-1@@ -275,13 +275,14 @@ do else if diff $seq.out $tmp.out >/dev/null 2>&1 then - echo "" if $err
check do · line 288
Quoted 10 lines
check +2
-0then : else echo "$seq `expr $stop - $start`" >>$tmp.time + echo -n " `expr $stop - $start`s" fi + echo "" else echo " - output mismatch (see $seq.out.bad)" mv $tmp.out $seq.out.bad
_______________________________________________
xfs mailing list
[email protected]
http://oss.sgi.com/mailman/listinfo/xfs
Quoted 6 lines · Alex Elder
Quoted 4 lines · Lukas Czerner
As an addition to checking for supported file systems it would be nice to be able to specify unsupported file system. In combination with "generic" fs it can be useful. This patch adds that feature. For example to set ext3 as an unsupported fs add "!ext3" into list.
Quoted 6 lines
Interesting idea, I agree it could be useful to exclude rather than have to enumerate everything.
I don't think there's any need to make use of it except where needed--i.e., don't go changing things, just use it where it fits from here on.
ok, agreed.
Thanks.
Quoted 19 lines
One comment below.
Quoted 16 lines
Also specify ext3 and ex4 as unsupported file systems in 213 and 214 since those fs does not support fallocate. There may be others though.
Signed-off-by Lukas Czerner <[email protected]>--- 213 | 2 +- 214 | 2 +- common.rc | 22 +++++++++++++++++----- 3 files changed, 19 insertions(+), 7 deletions(-)213 +0
-0@@ -47,7 +47,7 @@ trap "_cleanup; exit \$status" 0 1 2 3 15
Quoted 6 lines
213 trap "_cleanup; exit \$status" 0 1 2 3 15 · line 50
Quoted 4 lines
213 +1
-1# real QA test starts here # generic, but xfs_io's fallocate must work -_supported_fs generic +_supported_fs generic !ext3 !ext3Did you mean !ext2 for the second one here?
Oh, my bad, it should be !ext2. Do you want me to send it again ?
Quoted 60 lines
Quoted 54 lines
213 +0
-0# only Linux supports fallocate _supported_os Linux214 +1
-1@@ -45,7 +45,7 @@ trap "_cleanup; exit \$status" 0 1 2 3 15 # real QA test starts here # generic, but xfs_io's fallocate must work -_supported_fs generic +_supported_fs generic !ext3 !ext2 # only Linux supports fallocate _supported_os Linuxcommon.rc +17
-5@@ -656,15 +656,27 @@ _fail() # _supported_fs() { + supp=0 for f do - if [ "$f" = "$FSTYP" -o "$f" = "generic" ] - then - return - fi + if [ "$f" = \!"$FSTYP" ] + then + supp=0 + break + fi + + if [ "$f" = "$FSTYP" -o "$f" = "generic" ] + then + supp=1 + fi done - _notrun "not suitable for this filesystem type: $FSTYP" + if [ $supp -eq 1 ] + then + return + else + _notrun "not suitable for this filesystem type: $FSTYP" + fi } # tests whether $FSTYP is one of the supported OSes for a test
Signature · 4 lines
_______________________________________________ xfs mailing list [email protected] http://oss.sgi.com/mailman/listinfo/xfs