diff options
author | Paul E. McKenney <paulmck@linux.vnet.ibm.com> | 2014-02-26 17:28:43 -0500 |
---|---|---|
committer | Paul E. McKenney <paulmck@linux.vnet.ibm.com> | 2014-05-14 12:45:19 -0400 |
commit | 8c55f2271c732670099f0a47d287c1b4a1d812c2 (patch) | |
tree | 1cd9813a0cd63aafc1df9f1e62c1676a9f3a7c6d | |
parent | da601c63fd3a3e6c30f85eefd5ee46397b5b439d (diff) |
torture: Allow variations of "defconfig" to be specified
Some environments require some variation on "make defconfig" to initialize
the .config file. This commit therefore adds a --defconfig argument to
allow this to be specified. The default value is of course "defconfig".
Signed-off-by: Paul E. McKenney <paulmck@linux.vnet.ibm.com>
Reviewed-by: Josh Triplett <josh@joshtriplett.org>
-rwxr-xr-x | tools/testing/selftests/rcutorture/bin/configinit.sh | 2 | ||||
-rw-r--r-- | tools/testing/selftests/rcutorture/bin/kvm.sh | 8 |
2 files changed, 9 insertions, 1 deletions
diff --git a/tools/testing/selftests/rcutorture/bin/configinit.sh b/tools/testing/selftests/rcutorture/bin/configinit.sh index a1be6e62add1..9c3f3d39b934 100755 --- a/tools/testing/selftests/rcutorture/bin/configinit.sh +++ b/tools/testing/selftests/rcutorture/bin/configinit.sh | |||
@@ -62,7 +62,7 @@ grep '^grep' < $T/u.sh > $T/upd.sh | |||
62 | echo "cat - $c" >> $T/upd.sh | 62 | echo "cat - $c" >> $T/upd.sh |
63 | make mrproper | 63 | make mrproper |
64 | make $buildloc distclean > $builddir/Make.distclean 2>&1 | 64 | make $buildloc distclean > $builddir/Make.distclean 2>&1 |
65 | make $buildloc defconfig > $builddir/Make.defconfig.out 2>&1 | 65 | make $buildloc $TORTURE_DEFCONFIG > $builddir/Make.defconfig.out 2>&1 |
66 | mv $builddir/.config $builddir/.config.sav | 66 | mv $builddir/.config $builddir/.config.sav |
67 | sh $T/upd.sh < $builddir/.config.sav > $builddir/.config | 67 | sh $T/upd.sh < $builddir/.config.sav > $builddir/.config |
68 | cp $builddir/.config $builddir/.config.new | 68 | cp $builddir/.config $builddir/.config.new |
diff --git a/tools/testing/selftests/rcutorture/bin/kvm.sh b/tools/testing/selftests/rcutorture/bin/kvm.sh index a52a077ee258..59945b7793d9 100644 --- a/tools/testing/selftests/rcutorture/bin/kvm.sh +++ b/tools/testing/selftests/rcutorture/bin/kvm.sh | |||
@@ -38,6 +38,7 @@ dur=30 | |||
38 | dryrun="" | 38 | dryrun="" |
39 | KVM="`pwd`/tools/testing/selftests/rcutorture"; export KVM | 39 | KVM="`pwd`/tools/testing/selftests/rcutorture"; export KVM |
40 | PATH=${KVM}/bin:$PATH; export PATH | 40 | PATH=${KVM}/bin:$PATH; export PATH |
41 | TORTURE_DEFCONFIG=defconfig | ||
41 | TORTURE_INITRD="$KVM/initrd"; export TORTURE_INITRD | 42 | TORTURE_INITRD="$KVM/initrd"; export TORTURE_INITRD |
42 | RCU_KMAKE_ARG=""; export RCU_KMAKE_ARG | 43 | RCU_KMAKE_ARG=""; export RCU_KMAKE_ARG |
43 | TORTURE_SUITE=rcu | 44 | TORTURE_SUITE=rcu |
@@ -56,6 +57,7 @@ usage () { | |||
56 | echo " --configs \"config-file list\"" | 57 | echo " --configs \"config-file list\"" |
57 | echo " --cpus N" | 58 | echo " --cpus N" |
58 | echo " --datestamp string" | 59 | echo " --datestamp string" |
60 | echo " --defconfig string" | ||
59 | echo " --dryrun sched|script" | 61 | echo " --dryrun sched|script" |
60 | echo " --duration minutes" | 62 | echo " --duration minutes" |
61 | echo " --interactive" | 63 | echo " --interactive" |
@@ -96,6 +98,11 @@ do | |||
96 | ds=$2 | 98 | ds=$2 |
97 | shift | 99 | shift |
98 | ;; | 100 | ;; |
101 | --defconfig) | ||
102 | checkarg --defconfig "defconfigtype" "$#" "$2" '^[^/][^/]*$' '^--' | ||
103 | TORTURE_DEFCONFIG=$2 | ||
104 | shift | ||
105 | ;; | ||
99 | --dryrun) | 106 | --dryrun) |
100 | checkarg --dryrun "sched|script" $# "$2" 'sched\|script' '^--' | 107 | checkarg --dryrun "sched|script" $# "$2" 'sched\|script' '^--' |
101 | dryrun=$2 | 108 | dryrun=$2 |
@@ -259,6 +266,7 @@ END { | |||
259 | # Generate a script to execute the tests in appropriate batches. | 266 | # Generate a script to execute the tests in appropriate batches. |
260 | cat << ___EOF___ > $T/script | 267 | cat << ___EOF___ > $T/script |
261 | TORTURE_SUITE="$TORTURE_SUITE"; export TORTURE_SUITE | 268 | TORTURE_SUITE="$TORTURE_SUITE"; export TORTURE_SUITE |
269 | TORTURE_DEFCONFIG="$TORTURE_DEFCONFIG"; export TORTURE_DEFCONFIG | ||
262 | ___EOF___ | 270 | ___EOF___ |
263 | awk < $T/cfgcpu.pack \ | 271 | awk < $T/cfgcpu.pack \ |
264 | -v CONFIGDIR="$CONFIGFRAG/$kversion/" \ | 272 | -v CONFIGDIR="$CONFIGFRAG/$kversion/" \ |