From: Miao Xie <miaox@cn.fujitsu.com> To: Linux Btrfs <linux-btrfs@vger.kernel.org>, xfs@oss.sgi.com Cc: anand.jain@oracle.com Subject: [PATCH 2/3] xfstests: fix double set for SCRATCH_DEV when SCRATCH_DEV_POOL is set Date: Fri, 24 Aug 2012 09:41:42 +0800 [thread overview] Message-ID: <5036DBD6.4040301@cn.fujitsu.com> (raw) check script has moved the first device of SCRATCH_DEV_POOL and used it to set SCRATCH_DEV. But the case 265 does the same thing again when it includes common.rc. Fix it by setting SCRATCH_DEV just by check script. Signed-off-by: Miao Xie <miaox@cn.fujitsu.com> --- common.config | 5 +++-- 1 files changed, 3 insertions(+), 2 deletions(-) diff --git a/common.config b/common.config index 7bed1c5..a35954b 100644 --- a/common.config +++ b/common.config @@ -232,12 +232,13 @@ fi # a btrfs tester will set only SCRATCH_DEV_POOL, we will put first of its dev # to SCRATCH_DEV and rest to SCRATCH_DEV_POOL to maintain the backward compatibility -if [ ! -z "$SCRATCH_DEV_POOL" ]; then +if [ "$iam" == "check" -a ! -z "$SCRATCH_DEV_POOL" ]; then if [ ! -z "$SCRATCH_DEV" ]; then echo "common.config: Error: \$SCRATCH_DEV should be unset when \$SCRATCH_DEV_POOL is set" exit 1 fi - SCRATCH_DEV=`echo $SCRATCH_DEV_POOL | awk '{print $1}'` + # the user may forget to export SCRATCH_DEV when he/she set SCRATCH_DEV_POOL. + export SCRATCH_DEV=`echo $SCRATCH_DEV_POOL | awk '{print $1}'` SCRATCH_DEV_POOL=`echo $SCRATCH_DEV_POOL | awk '{ for (i = 2; i <= NF; i++) print $i}'` fi -- 1.7.6.5
WARNING: multiple messages have this Message-ID (diff)
From: Miao Xie <miaox@cn.fujitsu.com> To: Linux Btrfs <linux-btrfs@vger.kernel.org>, xfs@oss.sgi.com Cc: anand.jain@oracle.com Subject: [PATCH 2/3] xfstests: fix double set for SCRATCH_DEV when SCRATCH_DEV_POOL is set Date: Fri, 24 Aug 2012 09:41:42 +0800 [thread overview] Message-ID: <5036DBD6.4040301@cn.fujitsu.com> (raw) check script has moved the first device of SCRATCH_DEV_POOL and used it to set SCRATCH_DEV. But the case 265 does the same thing again when it includes common.rc. Fix it by setting SCRATCH_DEV just by check script. Signed-off-by: Miao Xie <miaox@cn.fujitsu.com> --- common.config | 5 +++-- 1 files changed, 3 insertions(+), 2 deletions(-) diff --git a/common.config b/common.config index 7bed1c5..a35954b 100644 --- a/common.config +++ b/common.config @@ -232,12 +232,13 @@ fi # a btrfs tester will set only SCRATCH_DEV_POOL, we will put first of its dev # to SCRATCH_DEV and rest to SCRATCH_DEV_POOL to maintain the backward compatibility -if [ ! -z "$SCRATCH_DEV_POOL" ]; then +if [ "$iam" == "check" -a ! -z "$SCRATCH_DEV_POOL" ]; then if [ ! -z "$SCRATCH_DEV" ]; then echo "common.config: Error: \$SCRATCH_DEV should be unset when \$SCRATCH_DEV_POOL is set" exit 1 fi - SCRATCH_DEV=`echo $SCRATCH_DEV_POOL | awk '{print $1}'` + # the user may forget to export SCRATCH_DEV when he/she set SCRATCH_DEV_POOL. + export SCRATCH_DEV=`echo $SCRATCH_DEV_POOL | awk '{print $1}'` SCRATCH_DEV_POOL=`echo $SCRATCH_DEV_POOL | awk '{ for (i = 2; i <= NF; i++) print $i}'` fi -- 1.7.6.5 _______________________________________________ xfs mailing list xfs@oss.sgi.com http://oss.sgi.com/mailman/listinfo/xfs
next reply other threads:[~2012-08-24 1:42 UTC|newest] Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top 2012-08-24 1:41 Miao Xie [this message] 2012-08-24 1:41 ` [PATCH 2/3] xfstests: fix double set for SCRATCH_DEV when SCRATCH_DEV_POOL is set Miao Xie
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=5036DBD6.4040301@cn.fujitsu.com \ --to=miaox@cn.fujitsu.com \ --cc=anand.jain@oracle.com \ --cc=linux-btrfs@vger.kernel.org \ --cc=xfs@oss.sgi.com \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.