xfstests: add missing _require_scratch checks
v3 cover xfstests: add missing _require_scratch checks
Fully consolidated resend of all remaining _require_scratch fixes, as requested by Zorro on the v2 cover.
All of these patches add a single missing _require_scratch check; with the exception of btrfs/333 (which places it at the top of _require_btrfs_iouring_encoded_read(), per Qu Wenruo's earlier review) they are plain one-line adds directly after the resource checks. No other changes.
v3:
- Merge ALL six single-line fixes into one series, per Zorro's request of 2026-09-03 on the v2 cover letter.
- Add Johannes Thumshirn's R-b for btrfs/273 and Chao Yu's R-b for f2fs/015,016 (both since v2).
- No code changes; patch contents are identical to the v2/v3 versions previously posted individually.
v2 pieces (this and the three it pulls forward) for reference:
- [PATCH v2 0/3] https://lore.kernel.org/fstests/[email protected]/
- btrfs/333 v3 https://lore.kernel.org/fstests/[email protected]/ (v1; v3 was posted but is not archived)
- btrfs/273 v2 https://lore.kernel.org/fstests/[email protected]/ (v1; v2 was posted but is not archived)
- overlay/081 v2 https://lore.kernel.org/fstests/[email protected]/
Reviewed-bys carried (per the individual threads):
- Darrick J. Wong: generic/590,735 and generic/795
- Zorro Lang + Chao Yu: f2fs/015,016
- Qu Wenruo: btrfs/333 (v3) and btrfs/273 (v2)
- Johannes Thumshirn: btrfs/273 (v2, second R-b)
- Amir Goldstein: overlay/081 (as Acked/Reviewed on v1; kept)
Prabhakar Pujeri (6):
generic/590,735: add missing _require_scratch check generic/795: add missing _require_scratch check f2fs/015,016: add missing _require_scratch checks btrfs/333: require scratch before checking encoded reads btrfs/273: add missing _require_scratch check overlay/081: add missing _require_scratch check
common/btrfs | 1 + tests/btrfs/273 | 1 + tests/f2fs/015 | 1 + tests/f2fs/016 | 1 + tests/generic/590 | 1 + tests/generic/735 | 1 + tests/generic/795 | 2 ++ tests/overlay/081 | 1 + 8 files changed, 9 insertions(+)
Base: upstream master a370dcbed43563f0462801e889e0eceb93c7cfad
Signature · 8 lines
2.55.0 _______________________________________________ Linux-f2fs-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel
PATCH v3 1/6 generic/590,735: add missing _require_scratch check
Both tests use the scratch device without first requiring one, so they fail messily instead of skipping when no scratch device is configured.
--- tests/generic/590 | 1 + tests/generic/735 | 1 + 2 files changed, 2 insertions(+)
tests/generic/590 +1 -0
@@ -13,6 +13,7 @@ _begin_fstest auto prealloc preallocrw . ./common/filter +_require_scratch _require_xfs_io_command "falloc" maxextlen=$((0x1fffff))
tests/generic/735 +1 -0
@@ -20,6 +20,7 @@ if [[ "$FSTYP" =~ ext[0-9]+ ]]; then fi _require_odirect +_require_scratch _require_xfs_io_command "falloc" _require_xfs_io_command "finsert" _require_max_file_range_blocks $(( (1 << 32) - 1 ))
Signature · 1 line
2.55.0
PATCH v3 2/6 generic/795: add missing _require_scratch check
In reply to Prabhakar PujeriThe test runs _scratch_mkfs and _scratch_mount without first requiring a scratch device, so it fails messily instead of skipping when no scratch device is configured.
--- tests/generic/795 | 2 ++ 1 file changed, 2 insertions(+)
tests/generic/795 +2 -0
@@ -27,6 +27,8 @@ _cleanup() . ./common/filter +_require_scratch + fsv_file_size=10000000 nproc_enabler=$((4 * LOAD_FACTOR)) nproc_reader=$((6 * LOAD_FACTOR))
Signature · 1 line
2.55.0
Re: [PATCH v3 2/6] generic/795: add missing _require_scratch check
Quoted 7 lines · Prabhakar Pujeri
The test runs
_scratch_mkfsand_scratch_mountwithout first requiring a scratch device, so it fails messily instead of skipping when no scratch device is configured.Reviewed-by "Darrick J. Wong" <[email protected]>Signed-off-by Prabhakar Pujeri <[email protected]>---
Thanks for consolidating the scattered patches! As mentioned in my previous review comment, I think patches 1/6 and 2/6 can be squashed together at least. Anyway, let me take care of squashing them upon merging. Overall, the patchset looks good to me.
Quoted 19 lines
tests/generic/795 | 2 ++ 1 file changed, 2 insertions(+)tests/generic/795 +2
-0@@ -27,6 +27,8 @@ _cleanup() . ./common/filter +_require_scratch + fsv_file_size=10000000 nproc_enabler=$((4 * LOAD_FACTOR)) nproc_reader=$((6 * LOAD_FACTOR))Signature · 1 line
2.55.0
PATCH v3 3/6 f2fs/015,016: add missing _require_scratch checks
In reply to Prabhakar PujeriBoth tests run _scratch_mkfs in a loop without first requiring a scratch device, so they fail messily instead of skipping when no scratch device is configured.
--- tests/f2fs/015 | 1 + tests/f2fs/016 | 1 + 2 files changed, 2 insertions(+)
tests/f2fs/015 +1 -0
@@ -12,6 +12,7 @@ _begin_fstest auto quick mount _require_kernel_config CONFIG_F2FS_FS_XATTR _require_kernel_config CONFIG_F2FS_FS_POSIX_ACL _require_kernel_config CONFIG_F2FS_FAULT_INJECTION +_require_scratch options=( # mount_option mkfs_option
tests/f2fs/016 +1 -0
@@ -15,6 +15,7 @@ _require_kernel_config CONFIG_F2FS_FS_LZORLE _require_kernel_config CONFIG_F2FS_FS_LZ4 _require_kernel_config CONFIG_F2FS_FS_LZ4HC _require_kernel_config CONFIG_F2FS_FS_ZSTD +_require_scratch options=( # mount_option mkfs_option
Signature · 8 lines
2.55.0 _______________________________________________ Linux-f2fs-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel
PATCH v3 4/6 btrfs/333: require scratch before checking encoded reads
In reply to Prabhakar Pujeri_require_btrfs_iouring_encoded_read() formats and mounts the scratch device while checking for encoded-read support. Without a configured scratch device, callers therefore fail inside the helper before any scratch requirement is checked.
Add _require_scratch at the top of the helper so that all of its callers skip cleanly when no scratch device is present.
--- common/btrfs | 1 + 1 file changed, 1 insertion(+)
common/btrfs +1 -0
@@ -1055,6 +1055,7 @@ _require_btrfs_iouring_encoded_read() local tmpfile local ret + _require_scratch _require_command src/btrfs_encoded_read _scratch_mkfs &> /dev/null
Signature · 1 line
2.55.0
PATCH v3 5/6 btrfs/273: add missing _require_scratch check
In reply to Prabhakar PujeriThe test passes $SCRATCH_DEV to _require_zoned_device() and mkfs/mount without first requiring a scratch device, so it fails messily instead of skipping when no scratch device is configured.
--- tests/btrfs/273 | 1 + 1 file changed, 1 insertion(+)
tests/btrfs/273 +1 -0
@@ -28,6 +28,7 @@ _fixed_by_kernel_commit 2ce543f47843 \ # which is further fixed by _fixed_by_kernel_commit d5b81ced74af \ "btrfs: zoned: fix API misuse of zone finish waiting" +_require_scratch _require_zoned_device "$SCRATCH_DEV" _require_limited_active_zones "$SCRATCH_DEV"
Signature · 1 line
2.55.0
PATCH v3 6/6 overlay/081: add missing _require_scratch check
In reply to Prabhakar PujeriThe test runs _scratch_mkfs without first requiring a scratch device, so it fails messily instead of skipping when no scratch device is configured. Add _require_scratch so the test skips cleanly when no scratch device is present.
--- tests/overlay/081 | 1 + 1 file changed, 1 insertion(+)
tests/overlay/081 +1 -0
@@ -14,6 +14,7 @@ _begin_fstest auto quick . ./common/filter . ./common/attr +_require_scratch _scratch_mkfs >>$seqres.full 2>&1
Signature · 1 line
2.55.0