FS/XFS testing framework
 help / color / mirror / Atom feed
* [PATCH v3 0/6] xfstests: add missing _require_scratch checks
@ 2026-09-15 14:17 Prabhakar Pujeri
  2026-09-15 14:17 ` [PATCH v3 1/6] generic/590,735: add missing _require_scratch check Prabhakar Pujeri
                   ` (5 more replies)
  0 siblings, 6 replies; 8+ messages in thread
From: Prabhakar Pujeri @ 2026-09-15 14:17 UTC (permalink / raw)
  To: fstests
  Cc: Prabhakar Pujeri, Zorro Lang, Darrick J. Wong, Qu Wenruo,
	Johannes Thumshirn, Jaegeuk Kim, Chao Yu, Amir Goldstein,
	Anand Jain, Filipe Manana, quwenruo.btrfs, linux-f2fs-devel,
	linux-btrfs, linux-unionfs

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/20260903035344.752-1-prabhakar.pujeri@dell.com/
- btrfs/333 v3 https://lore.kernel.org/fstests/20260831104200.2269-1-prabhakar.pujeri@dell.com/ (v1; v3 was posted but is not archived)
- btrfs/273 v2 https://lore.kernel.org/fstests/20260902050145.2439-1-prabhakar.pujeri@dell.com/ (v1; v2 was posted but is not archived)
- overlay/081 v2 https://lore.kernel.org/fstests/20260901132438.759-1-prabhakar.pujeri@dell.com/

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
-- 
2.55.0


^ permalink raw reply	[flat|nested] 8+ messages in thread

* [PATCH v3 1/6] generic/590,735: add missing _require_scratch check
  2026-09-15 14:17 [PATCH v3 0/6] xfstests: add missing _require_scratch checks Prabhakar Pujeri
@ 2026-09-15 14:17 ` Prabhakar Pujeri
  2026-09-15 14:17 ` [PATCH v3 2/6] generic/795: " Prabhakar Pujeri
                   ` (4 subsequent siblings)
  5 siblings, 0 replies; 8+ messages in thread
From: Prabhakar Pujeri @ 2026-09-15 14:17 UTC (permalink / raw)
  To: fstests; +Cc: Prabhakar Pujeri, Zorro Lang, Darrick J. Wong

Both tests use the scratch device without first requiring one, so they
fail messily instead of skipping when no scratch device is configured.

Reviewed-by: "Darrick J. Wong" <djwong@kernel.org>
Signed-off-by: Prabhakar Pujeri <prabhakar.pujeri@dell.com>
---
 tests/generic/590 | 1 +
 tests/generic/735 | 1 +
 2 files changed, 2 insertions(+)

diff --git a/tests/generic/590 b/tests/generic/590
index 54c26f2a..0775d6ff 100755
--- a/tests/generic/590
+++ b/tests/generic/590
@@ -13,6 +13,7 @@ _begin_fstest auto prealloc preallocrw
 
 . ./common/filter
 
+_require_scratch
 _require_xfs_io_command "falloc"
 
 maxextlen=$((0x1fffff))
diff --git a/tests/generic/735 b/tests/generic/735
index 60fa3dce..d7e732bc 100755
--- a/tests/generic/735
+++ b/tests/generic/735
@@ -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 ))
-- 
2.55.0


^ permalink raw reply related	[flat|nested] 8+ messages in thread

* [PATCH v3 2/6] generic/795: add missing _require_scratch check
  2026-09-15 14:17 [PATCH v3 0/6] xfstests: add missing _require_scratch checks Prabhakar Pujeri
  2026-09-15 14:17 ` [PATCH v3 1/6] generic/590,735: add missing _require_scratch check Prabhakar Pujeri
@ 2026-09-15 14:17 ` Prabhakar Pujeri
  2026-09-15 16:54   ` Zorro Lang
  2026-09-15 14:17 ` [PATCH v3 3/6] f2fs/015,016: add missing _require_scratch checks Prabhakar Pujeri
                   ` (3 subsequent siblings)
  5 siblings, 1 reply; 8+ messages in thread
From: Prabhakar Pujeri @ 2026-09-15 14:17 UTC (permalink / raw)
  To: fstests; +Cc: Prabhakar Pujeri, Zorro Lang, Darrick J. Wong

The 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.

Reviewed-by: "Darrick J. Wong" <djwong@kernel.org>
Signed-off-by: Prabhakar Pujeri <prabhakar.pujeri@dell.com>
---
 tests/generic/795 | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/tests/generic/795 b/tests/generic/795
index fa5474c5..4c0e7bdb 100755
--- a/tests/generic/795
+++ b/tests/generic/795
@@ -27,6 +27,8 @@ _cleanup()
 
 . ./common/filter
 
+_require_scratch
+
 fsv_file_size=10000000
 nproc_enabler=$((4 * LOAD_FACTOR))
 nproc_reader=$((6 * LOAD_FACTOR))
-- 
2.55.0


^ permalink raw reply related	[flat|nested] 8+ messages in thread

* [PATCH v3 3/6] f2fs/015,016: add missing _require_scratch checks
  2026-09-15 14:17 [PATCH v3 0/6] xfstests: add missing _require_scratch checks Prabhakar Pujeri
  2026-09-15 14:17 ` [PATCH v3 1/6] generic/590,735: add missing _require_scratch check Prabhakar Pujeri
  2026-09-15 14:17 ` [PATCH v3 2/6] generic/795: " Prabhakar Pujeri
@ 2026-09-15 14:17 ` Prabhakar Pujeri
  2026-09-15 14:17 ` [PATCH v3 4/6] btrfs/333: require scratch before checking encoded reads Prabhakar Pujeri
                   ` (2 subsequent siblings)
  5 siblings, 0 replies; 8+ messages in thread
From: Prabhakar Pujeri @ 2026-09-15 14:17 UTC (permalink / raw)
  To: fstests
  Cc: Prabhakar Pujeri, Zorro Lang, Chao Yu, Jaegeuk Kim,
	linux-f2fs-devel

Both 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.

Reviewed-by: Zorro Lang <zlang@kernel.org>
Reviewed-by: Chao Yu <chao@kernel.org>
Signed-off-by: Prabhakar Pujeri <prabhakar.pujeri@dell.com>
---
 tests/f2fs/015 | 1 +
 tests/f2fs/016 | 1 +
 2 files changed, 2 insertions(+)

diff --git a/tests/f2fs/015 b/tests/f2fs/015
index 54cada4a..75ae91f2 100755
--- a/tests/f2fs/015
+++ b/tests/f2fs/015
@@ -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
diff --git a/tests/f2fs/016 b/tests/f2fs/016
index a6df827d..e0857e0a 100755
--- a/tests/f2fs/016
+++ b/tests/f2fs/016
@@ -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
-- 
2.55.0


^ permalink raw reply related	[flat|nested] 8+ messages in thread

* [PATCH v3 4/6] btrfs/333: require scratch before checking encoded reads
  2026-09-15 14:17 [PATCH v3 0/6] xfstests: add missing _require_scratch checks Prabhakar Pujeri
                   ` (2 preceding siblings ...)
  2026-09-15 14:17 ` [PATCH v3 3/6] f2fs/015,016: add missing _require_scratch checks Prabhakar Pujeri
@ 2026-09-15 14:17 ` Prabhakar Pujeri
  2026-09-15 14:17 ` [PATCH v3 5/6] btrfs/273: add missing _require_scratch check Prabhakar Pujeri
  2026-09-15 14:17 ` [PATCH v3 6/6] overlay/081: " Prabhakar Pujeri
  5 siblings, 0 replies; 8+ messages in thread
From: Prabhakar Pujeri @ 2026-09-15 14:17 UTC (permalink / raw)
  To: fstests
  Cc: Prabhakar Pujeri, Zorro Lang, Qu Wenruo, quwenruo.btrfs,
	Anand Jain, Filipe Manana, linux-btrfs

_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.

Reviewed-by: Qu Wenruo <wqu@suse.com>
Signed-off-by: Prabhakar Pujeri <prabhakar.pujeri@dell.com>
---
 common/btrfs | 1 +
 1 file changed, 1 insertion(+)

diff --git a/common/btrfs b/common/btrfs
index a75fbf1c..ccac8626 100644
--- a/common/btrfs
+++ b/common/btrfs
@@ -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
-- 
2.55.0


^ permalink raw reply related	[flat|nested] 8+ messages in thread

* [PATCH v3 5/6] btrfs/273: add missing _require_scratch check
  2026-09-15 14:17 [PATCH v3 0/6] xfstests: add missing _require_scratch checks Prabhakar Pujeri
                   ` (3 preceding siblings ...)
  2026-09-15 14:17 ` [PATCH v3 4/6] btrfs/333: require scratch before checking encoded reads Prabhakar Pujeri
@ 2026-09-15 14:17 ` Prabhakar Pujeri
  2026-09-15 14:17 ` [PATCH v3 6/6] overlay/081: " Prabhakar Pujeri
  5 siblings, 0 replies; 8+ messages in thread
From: Prabhakar Pujeri @ 2026-09-15 14:17 UTC (permalink / raw)
  To: fstests
  Cc: Prabhakar Pujeri, Zorro Lang, Qu Wenruo, quwenruo.btrfs,
	Johannes Thumshirn, Anand Jain, Filipe Manana, linux-btrfs

The 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.

Reviewed-by: Qu Wenruo <wqu@suse.com>
Reviewed-by: Johannes Thumshirn <Johannes.Thumshirn@wdc.com>
Signed-off-by: Prabhakar Pujeri <prabhakar.pujeri@dell.com>
---
 tests/btrfs/273 | 1 +
 1 file changed, 1 insertion(+)

diff --git a/tests/btrfs/273 b/tests/btrfs/273
index 60c3967b..197cfb02 100755
--- a/tests/btrfs/273
+++ b/tests/btrfs/273
@@ -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"
 
-- 
2.55.0


^ permalink raw reply related	[flat|nested] 8+ messages in thread

* [PATCH v3 6/6] overlay/081: add missing _require_scratch check
  2026-09-15 14:17 [PATCH v3 0/6] xfstests: add missing _require_scratch checks Prabhakar Pujeri
                   ` (4 preceding siblings ...)
  2026-09-15 14:17 ` [PATCH v3 5/6] btrfs/273: add missing _require_scratch check Prabhakar Pujeri
@ 2026-09-15 14:17 ` Prabhakar Pujeri
  5 siblings, 0 replies; 8+ messages in thread
From: Prabhakar Pujeri @ 2026-09-15 14:17 UTC (permalink / raw)
  To: fstests; +Cc: Prabhakar Pujeri, Zorro Lang, Amir Goldstein, linux-unionfs

The 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.

Signed-off-by: Prabhakar Pujeri <prabhakar.pujeri@dell.com>
Reviewed-by: Amir Goldstein <amir73il@gmail.com>
---
 tests/overlay/081 | 1 +
 1 file changed, 1 insertion(+)

diff --git a/tests/overlay/081 b/tests/overlay/081
index 2270a047..e0ab558b 100755
--- a/tests/overlay/081
+++ b/tests/overlay/081
@@ -14,6 +14,7 @@ _begin_fstest auto quick
 . ./common/filter
 . ./common/attr
 
+_require_scratch
 
 _scratch_mkfs >>$seqres.full 2>&1
 
-- 
2.55.0


^ permalink raw reply related	[flat|nested] 8+ messages in thread

* Re: [PATCH v3 2/6] generic/795: add missing _require_scratch check
  2026-09-15 14:17 ` [PATCH v3 2/6] generic/795: " Prabhakar Pujeri
@ 2026-09-15 16:54   ` Zorro Lang
  0 siblings, 0 replies; 8+ messages in thread
From: Zorro Lang @ 2026-09-15 16:54 UTC (permalink / raw)
  To: Prabhakar Pujeri; +Cc: fstests, Darrick J. Wong

On Tue, Sep 15, 2026 at 02:17:41PM +0000, Prabhakar Pujeri wrote:
> The 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.
> 
> Reviewed-by: "Darrick J. Wong" <djwong@kernel.org>
> Signed-off-by: Prabhakar Pujeri <prabhakar.pujeri@dell.com>
> ---

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.

Reviewed-by: Zorro Lang <zlang@kernel.org>

>  tests/generic/795 | 2 ++
>  1 file changed, 2 insertions(+)
> 
> diff --git a/tests/generic/795 b/tests/generic/795
> index fa5474c5..4c0e7bdb 100755
> --- a/tests/generic/795
> +++ b/tests/generic/795
> @@ -27,6 +27,8 @@ _cleanup()
>  
>  . ./common/filter
>  
> +_require_scratch
> +
>  fsv_file_size=10000000
>  nproc_enabler=$((4 * LOAD_FACTOR))
>  nproc_reader=$((6 * LOAD_FACTOR))
> -- 
> 2.55.0
> 

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2026-09-15 16:55 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-09-15 14:17 [PATCH v3 0/6] xfstests: add missing _require_scratch checks Prabhakar Pujeri
2026-09-15 14:17 ` [PATCH v3 1/6] generic/590,735: add missing _require_scratch check Prabhakar Pujeri
2026-09-15 14:17 ` [PATCH v3 2/6] generic/795: " Prabhakar Pujeri
2026-09-15 16:54   ` Zorro Lang
2026-09-15 14:17 ` [PATCH v3 3/6] f2fs/015,016: add missing _require_scratch checks Prabhakar Pujeri
2026-09-15 14:17 ` [PATCH v3 4/6] btrfs/333: require scratch before checking encoded reads Prabhakar Pujeri
2026-09-15 14:17 ` [PATCH v3 5/6] btrfs/273: add missing _require_scratch check Prabhakar Pujeri
2026-09-15 14:17 ` [PATCH v3 6/6] overlay/081: " Prabhakar Pujeri

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox