From: Anand Jain <anand.jain@oracle.com>
To: Boris Burkov <boris@bur.io>
Cc: fstests@vger.kernel.org, linux-btrfs@vger.kernel.org
Subject: Re: [PATCH] fstests: btrfs/185 update for single device pseudo device-scan
Date: Tue, 12 Sep 2023 17:00:18 +0800 [thread overview]
Message-ID: <ef6237dc-b74e-457e-894b-c7c1c49c8600@oracle.com> (raw)
In-Reply-To: <20230911183542.GA1770246@zen>
On 12/09/2023 02:35, Boris Burkov wrote:
> On Thu, Sep 07, 2023 at 12:24:43AM +0800, Anand Jain wrote:
>> As we are obliterating the need for the device scan for the single device,
>> which will return success if the basic superblock verification passes,
>> even for the duplicate device of the mounted filesystem, drop the check
>> for the return code in this testcase and continue to verify if the device
>> path of the mounted filesystem remains unaltered after the scan.
>>
>> Also, if the test fails, it leaves the local non-standard mount point
>> remained mounted, leading to further test cases failing. Call unmount
>> in _cleanup().
>>
>> Signed-off-by: Anand Jain <anand.jain@oracle.com>
>> ---
>> tests/btrfs/185 | 5 +++--
>> 1 file changed, 3 insertions(+), 2 deletions(-)
>>
>> diff --git a/tests/btrfs/185 b/tests/btrfs/185
>> index ba0200617e69..c7b8d2d46951 100755
>> --- a/tests/btrfs/185
>> +++ b/tests/btrfs/185
>> @@ -15,6 +15,7 @@ mnt=$TEST_DIR/$seq.mnt
>> # Override the default cleanup function.
>> _cleanup()
>> {
>> + $UMOUNT_PROG $mnt > /dev/null 2>&1
>> rm -rf $mnt > /dev/null 2>&1
>> cd /
>> rm -f $tmp.*
>
> Also, do we need to do the scratch_dev_pool_put on cleanup? Do we have
> to worry about having not actually called scratch_dev_pool_get?
No need, actually, the config gets called at the beginning of the test
cases, so SCRATCH_DEV_POOL gets overwritten.
>
>> @@ -51,9 +52,9 @@ for sb_bytenr in 65536 67108864; do
>> echo ..:$? >> $seqres.full
>> done
>>
>> -# Original device is mounted, scan of its clone should fail
>> +# Original device is mounted, scan of its clone must not alter the
>> +# filesystem device path
>> $BTRFS_UTIL_PROG device scan $device_2 >> $seqres.full 2>&1
>> -[[ $? != 1 ]] && _fail "cloned device scan should fail"
>>
>> [[ $(findmnt $mnt | grep -v TARGET | $AWK_PROG '{print $2}') != $device_1 ]] && \
>> _fail "mounted device changed"
>> --
>> 2.39.3
>>
next prev parent reply other threads:[~2023-09-12 9:01 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-09-06 16:24 [PATCH] fstests: btrfs/185 update for single device pseudo device-scan Anand Jain
2023-09-11 18:32 ` Boris Burkov
2023-09-12 9:07 ` Anand Jain
2023-09-12 16:21 ` Boris Burkov
2023-09-11 18:35 ` Boris Burkov
2023-09-12 9:00 ` Anand Jain [this message]
2023-09-12 12:34 ` Zorro Lang
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=ef6237dc-b74e-457e-894b-c7c1c49c8600@oracle.com \
--to=anand.jain@oracle.com \
--cc=boris@bur.io \
--cc=fstests@vger.kernel.org \
--cc=linux-btrfs@vger.kernel.org \
/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: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox