Commit b5744d3c authored by Paul E. McKenney's avatar Paul E. McKenney

torture: Eliminate duplicate #CHECK# from ConfigFragment

The #CHECK# directives that can be present in CFcommon and in the
rcutorture scenario Kconfig files are both copied to ConfigFragment
and grepped out of the two directive files and added to ConfigFragment.
This commit therefore removes the redundant "grep" commands and takes
advantage of the consequent opportunity to simplify redirection.
Signed-off-by: default avatarPaul E. McKenney <paulmck@kernel.org>
parent afbc1574
...@@ -44,19 +44,17 @@ then ...@@ -44,19 +44,17 @@ then
fi fi
echo ' ---' `date`: Starting build echo ' ---' `date`: Starting build
echo ' ---' Kconfig fragment at: $config_template >> $resdir/log echo ' ---' Kconfig fragment at: $config_template >> $resdir/log
touch $resdir/ConfigFragment.input $resdir/ConfigFragment touch $resdir/ConfigFragment.input
if test -r "$config_dir/CFcommon" if test -r "$config_dir/CFcommon"
then then
echo " --- $config_dir/CFcommon" >> $resdir/ConfigFragment.input echo " --- $config_dir/CFcommon" >> $resdir/ConfigFragment.input
cat < $config_dir/CFcommon >> $resdir/ConfigFragment.input cat < $config_dir/CFcommon >> $resdir/ConfigFragment.input
config_override.sh $config_dir/CFcommon $config_template > $T/Kc1 config_override.sh $config_dir/CFcommon $config_template > $T/Kc1
grep '#CHECK#' $config_dir/CFcommon >> $resdir/ConfigFragment
else else
cp $config_template $T/Kc1 cp $config_template $T/Kc1
fi fi
echo " --- $config_template" >> $resdir/ConfigFragment.input echo " --- $config_template" >> $resdir/ConfigFragment.input
cat $config_template >> $resdir/ConfigFragment.input cat $config_template >> $resdir/ConfigFragment.input
grep '#CHECK#' $config_template >> $resdir/ConfigFragment
if test -n "$TORTURE_KCONFIG_ARG" if test -n "$TORTURE_KCONFIG_ARG"
then then
echo $TORTURE_KCONFIG_ARG | tr -s " " "\012" > $T/cmdline echo $TORTURE_KCONFIG_ARG | tr -s " " "\012" > $T/cmdline
...@@ -67,7 +65,7 @@ then ...@@ -67,7 +65,7 @@ then
else else
cp $T/Kc1 $T/Kc2 cp $T/Kc1 $T/Kc2
fi fi
cat $T/Kc2 >> $resdir/ConfigFragment cat $T/Kc2 > $resdir/ConfigFragment
base_resdir=`echo $resdir | sed -e 's/\.[0-9]\+$//'` base_resdir=`echo $resdir | sed -e 's/\.[0-9]\+$//'`
if test "$base_resdir" != "$resdir" -a -f $base_resdir/bzImage -a -f $base_resdir/vmlinux if test "$base_resdir" != "$resdir" -a -f $base_resdir/bzImage -a -f $base_resdir/vmlinux
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment