From: Christoph Hellwig Date: Thu, 18 Dec 2025 07:30:05 +0000 (+0100) Subject: xfs/185: don't use SCRATCH_{,RT}DEV helpers X-Git-Tag: v2026.01.05~19 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=4460f5d01c7e6f1ac62fd9d62f7f9c300d998e6e;p=xfstests-dev.git xfs/185: don't use SCRATCH_{,RT}DEV helpers This tests creates loop-based data and rt devices for testing. Don't override SCRATCH_{,RT}DEV and don't use the helpers based on it because the options specified in MKFS_OPTIONS might not work for this configuration. This also means that we will now never use a log device for this test even if SCRATCH_LOGDEV was set, which is fine because the log device is not relevant for what is tested. Signed-off-by: Christoph Hellwig Reviewed-by: Darrick J. Wong Signed-off-by: Zorro Lang --- diff --git a/tests/xfs/185 b/tests/xfs/185 index 7aceb383..84139be8 100755 --- a/tests/xfs/185 +++ b/tests/xfs/185 @@ -22,12 +22,11 @@ _cleanup() { cd / rm -r -f $tmp.* - _scratch_unmount + umount $SCRATCH_MNT test -n "$ddloop" && _destroy_loop_device "$ddloop" test -n "$rtloop" && _destroy_loop_device "$rtloop" test -n "$ddfile" && rm -f "$ddfile" test -n "$rtfile" && rm -f "$rtfile" - test -n "$old_use_external" && USE_EXTERNAL="$old_use_external" } _require_test @@ -64,16 +63,8 @@ rtminor=$(stat -c '%T' "$rtloop") test $ddmajor -le $rtmajor || \ _notrun "Data loopdev minor $ddminor larger than rt minor $rtminor" -# Inject our custom-built devices as an rt-capable scratch device. -# We avoid touching "require_scratch" so that post-test fsck will not try to -# run on our synthesized scratch device. -old_use_external="$USE_EXTERNAL" -USE_EXTERNAL=yes -SCRATCH_RTDEV="$rtloop" -SCRATCH_DEV="$ddloop" - -_scratch_mkfs >> $seqres.full -_try_scratch_mount >> $seqres.full || \ +$MKFS_XFS_PROG -r rtdev=$rtloop $ddloop >> $seqres.full +mount -o rtdev=$rtloop $ddloop $SCRATCH_MNT >> $seqres.full || \ _notrun "mount with injected rt device failed" # Create a file that we'll use to seed fsmap entries for the rt device,