| To: | Lukas Czerner <lczerner@xxxxxxxxxx> |
|---|---|
| Subject: | Re: [PATCH 2/3] xfstests: Unset SCRATCH_DEV when deduced from SCRATCH_DEV_POOL |
| From: | Filipe David Manana <fdmanana@xxxxxxxxx> |
| Date: | Tue, 8 Apr 2014 17:52:01 +0100 |
| Cc: | "xfs@xxxxxxxxxxx" <xfs@xxxxxxxxxxx>, "linux-btrfs@xxxxxxxxxxxxxxx" <linux-btrfs@xxxxxxxxxxxxxxx>, Dave Chinner <david@xxxxxxxxxxxxx> |
| Delivered-to: | xfs@xxxxxxxxxxx |
| Dkim-signature: | v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:reply-to:in-reply-to:references:date:message-id :subject:from:to:cc:content-type; bh=eIdVLU5eXWfl6Uf/zbPScLTn0F2Zun7DRdPQcjKKBxM=; b=k9QNMrEQSKsxtmfpoFTXUTwUB3oS+Do7f8Del3hBi3K0fAkZ7g/Lb7KaAq2OED8lSb +wSmDZhZ2wNxKg+OtAS11zcunFi15A9Yt92AoUmpE1CAq6qHtU66yQyrTzbO6ADX0ztc 9wRrBs8f/8sEMYa//IST81zu2eGwOWBledCp7rXdICRPIihF+dWyv0DuuqMvvAQwj+gw hKJEpcQ4DHV+2WEctpQapgUxkpjTdh6nEKP8bDyOB+0PRaoDq8bFlxOgXe+CMYHdqBc7 3tEoiSWAYgFuY/w6Y6rp8SWHH/U/SUPs9aOLZ1kNtXOinn11JZNshc6A773pm5odP0uu 4Y4g== |
| In-reply-to: | <1396971770-23553-2-git-send-email-lczerner@xxxxxxxxxx> |
| References: | <20140404211224.GX17603@dastard> <1396971770-23553-1-git-send-email-lczerner@xxxxxxxxxx> <1396971770-23553-2-git-send-email-lczerner@xxxxxxxxxx> |
| Reply-to: | fdmanana@xxxxxxxxx |
On Tue, Apr 8, 2014 at 4:42 PM, Lukas Czerner <lczerner@xxxxxxxxxx> wrote:
> In the case that we already have sections in the config file we
> have to make sure that we unset SCRATCH_DEV if it has been deduced from
> the SCRATCH_DEV_POOL so that it does not complain about SCRATCH_DEV in
> this case.
>
> Signed-off-by: Lukas Czerner <lczerner@xxxxxxxxxx>
Tested-by: Filipe David Manana <fdmanana@xxxxxxxxx>
Tests working for btrfs now.
Thanks Lukas.
> ---
> common/config | 8 +++++++-
> 1 file changed, 7 insertions(+), 1 deletion(-)
>
> diff --git a/common/config b/common/config
> index 6fa18e2..3163801 100644
> --- a/common/config
> +++ b/common/config
> @@ -372,10 +372,15 @@ get_next_config() {
> unset MOUNT_OPTIONS
> unset MKFS_OPTIONS
> unset FSCK_OPTIONS
> + # We might have deduced SCRATCH_DEV from the SCRATCH_DEV_POOL in the
> previous
> + # run, so we have to unset it now.
> + if [ "$SCRATCH_DEV_NOT_SET" == "true" ]; then
> + unset SCRATCH_DEV
> + fi
>
> parse_config_section $1
>
> - if [ -n "$OLD_FSTYP" ] && [ $OLD_FSTYP != $FSTYP ]; then
> + if [ ! -z "$OLD_FSTYP" ] && [ $OLD_FSTYP != $FSTYP ]; then
> [ -z "$MOUNT_OPTIONS" ] && _mount_opts
> [ -z "$MKFS_OPTIONS" ] && _mkfs_opts
> [ -z "$FSCK_OPTIONS" ] && _fsck_opts
> @@ -423,6 +428,7 @@ get_next_config() {
> fi
> SCRATCH_DEV=`echo $SCRATCH_DEV_POOL | awk '{print $1}'`
> export SCRATCH_DEV
> + export SCRATCH_DEV_NOT_SET=true
> fi
>
> echo $SCRATCH_DEV | grep -q ":" > /dev/null 2>&1
> --
> 1.8.3.1
>
--
Filipe David Manana,
"Reasonable men adapt themselves to the world.
Unreasonable men adapt the world to themselves.
That's why all progress depends on unreasonable men."
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| ||
| Previous by Date: | Re: [PATCH 1/3] xfstests: Fix SCRATCH_DEV_POOL handling, Filipe David Manana |
|---|---|
| Next by Date: | Re: [PATCH 3/3] xfstests: Fix setting FSTYP automatically, Filipe David Manana |
| Previous by Thread: | [PATCH 2/3] xfstests: Unset SCRATCH_DEV when deduced from SCRATCH_DEV_POOL, Lukas Czerner |
| Next by Thread: | Re: [PATCH 1/3] xfstests: Fix SCRATCH_DEV_POOL handling, Filipe David Manana |
| Indexes: | [Date] [Thread] [Top] [All Lists] |