Skip to contentSkip to conversation

xfs test excluses needed for realtime_28k_logdev

PATCH In review Theodore Ts'o 2 participants 5 messages Jun 29, 2022 – Jul 6, 2022

lore
Share & tools
lore
#0 lore raw

cover xfs test excluses needed for realtime_28k_logdev

These are tests in my out-of-tree patches to xfstests, which were cherry-picked from Darrick's out-of-tree patches. They are needed to prevent a huge whackload (that's a technical term) of test failures in the xfs/realtime_28k_logdev test config, which uses:

XFS_MKFS_OPTIONS='-d rtinherit=1 -m reflink=0,rmapbt=0 -r extsize=28k '

and uses an external logdevice as well as an external realtime device.

This test config is being used in the xfs 5.15 backports testing, since it's one of Darrick's upstream acceptance test configs.

Darrick, any objections if I ask Zorro to consider these for upstream xfstests?

Darrick J. Wong (2):
misc: skip remap/fallocate tests when op length not congruent with
file allocation unit
misc: skip extent size hint tests when hint not congruent with file
allocation unit

 common/rc         | 16 ++++++++++++++++
 tests/generic/031 |  1 +
 tests/generic/116 |  1 +
 tests/generic/118 |  1 +
 tests/generic/119 |  1 +
 tests/generic/121 |  1 +
 tests/generic/122 |  1 +
 tests/generic/134 |  1 +
 tests/generic/136 |  1 +
 tests/generic/137 |  1 +
 tests/generic/144 |  1 +
 tests/generic/149 |  1 +
 tests/generic/162 |  1 +
 tests/generic/163 |  1 +
 tests/generic/164 |  1 +
 tests/generic/165 |  1 +
 tests/generic/168 |  1 +
 tests/generic/170 |  1 +
 tests/generic/181 |  1 +
 tests/generic/183 |  1 +
 tests/generic/185 |  1 +
 tests/generic/186 |  1 +
 tests/generic/187 |  1 +
 tests/generic/188 |  1 +
 tests/generic/189 |  1 +
 tests/generic/190 |  1 +
 tests/generic/191 |  1 +
 tests/generic/194 |  1 +
 tests/generic/195 |  1 +
 tests/generic/196 |  1 +
 tests/generic/197 |  1 +
 tests/generic/199 |  1 +
 tests/generic/200 |  1 +
 tests/generic/201 |  1 +
 tests/generic/284 |  1 +
 tests/generic/287 |  1 +
 tests/generic/289 |  1 +
 tests/generic/290 |  1 +
 tests/generic/291 |  1 +
 tests/generic/292 |  1 +
 tests/generic/293 |  1 +
 tests/generic/295 |  1 +
 tests/generic/352 |  1 +
 tests/generic/358 |  1 +
 tests/generic/359 |  1 +
 tests/generic/372 |  1 +
 tests/generic/414 |  1 +
 tests/generic/501 |  1 +
 tests/generic/515 |  1 +
 tests/generic/516 |  1 +
 tests/generic/540 |  1 +
 tests/generic/541 |  1 +
 tests/generic/542 |  1 +
 tests/generic/543 |  1 +
 tests/generic/544 |  1 +
 tests/generic/546 |  1 +
 tests/generic/578 |  1 +
 tests/generic/588 |  2 ++
 tests/xfs/069     |  1 +
 tests/xfs/180     |  1 +
 tests/xfs/182     |  1 +
 tests/xfs/184     |  1 +
 tests/xfs/192     |  1 +
 tests/xfs/193     |  1 +
 tests/xfs/198     |  1 +
 tests/xfs/200     |  1 +
 tests/xfs/204     |  1 +
 tests/xfs/208     |  1 +
 tests/xfs/209     |  1 +
 tests/xfs/210     |  1 +
 tests/xfs/211     |  1 +
 tests/xfs/212     |  1 +
 tests/xfs/215     |  1 +
 tests/xfs/218     |  1 +
 tests/xfs/219     |  1 +
 tests/xfs/221     |  1 +
 tests/xfs/223     |  1 +
 tests/xfs/224     |  1 +
 tests/xfs/225     |  1 +
 tests/xfs/226     |  1 +
 tests/xfs/228     |  1 +
 tests/xfs/230     |  1 +
 tests/xfs/231     |  1 +
 tests/xfs/232     |  1 +
 tests/xfs/237     |  1 +
 tests/xfs/239     |  1 +
 tests/xfs/240     |  1 +
 tests/xfs/241     |  1 +
 tests/xfs/248     |  1 +
 tests/xfs/249     |  1 +
 tests/xfs/251     |  1 +
 tests/xfs/254     |  1 +
 tests/xfs/255     |  1 +
 tests/xfs/256     |  1 +
 tests/xfs/257     |  1 +
 tests/xfs/258     |  1 +
 tests/xfs/280     |  1 +
 tests/xfs/312     |  1 +
 tests/xfs/315     |  1 +
 tests/xfs/322     |  1 +
 tests/xfs/326     |  1 +
 tests/xfs/329     |  1 +
 tests/xfs/346     |  1 +
 tests/xfs/347     |  1 +
 tests/xfs/436     |  1 +
 tests/xfs/507     |  3 +++
 106 files changed, 124 insertions(+)
Signature · 1 line
2.31.0
#1 lore raw

PATCH 1/2 misc: skip remap/fallocate tests when op length not congruent with file allocation unit

From: "Darrick J. Wong" <[email protected]>

Nearly all of the reflink and fpunch/fcollapse/finsert tests that I have written assumed that it was ok to use 64k as the fundamental unit of allocation. This works fine for testing the XFS data device, since the file allocation unit is always a power of two, and never larger than 64k. Making this assumption allows those tests to encode md5sums in the golden output for easy file data integrity checking.

Unfortunately, this isn't necessarily the case when we're testing reflink and fallocate on the XFS realtime device. For those configurations, the file allocation unit is a realtime extent, which can be any integer multiple of the block size. If the request length isn't an exact multiple of the allocation unit size, reflink and fallocate will fail due to alignment issues, so there's no point in running these tests.

Assuming this edgecase configuration of an edgecase feature is vanishingly rare, let's just _notrun the tests instead of rewriting a ton of tests to do their integrity checking by hand.

(Cherry-picked from check-blocksize-congruency_2021-11-23)

---
 common/rc         | 16 ++++++++++++++++
 tests/generic/031 |  1 +
 tests/generic/116 |  1 +
 tests/generic/118 |  1 +
 tests/generic/119 |  1 +
 tests/generic/121 |  1 +
 tests/generic/122 |  1 +
 tests/generic/134 |  1 +
 tests/generic/136 |  1 +
 tests/generic/137 |  1 +
 tests/generic/144 |  1 +
 tests/generic/149 |  1 +
 tests/generic/162 |  1 +
 tests/generic/163 |  1 +
 tests/generic/164 |  1 +
 tests/generic/165 |  1 +
 tests/generic/168 |  1 +
 tests/generic/170 |  1 +
 tests/generic/181 |  1 +
 tests/generic/183 |  1 +
 tests/generic/185 |  1 +
 tests/generic/186 |  1 +
 tests/generic/187 |  1 +
 tests/generic/188 |  1 +
 tests/generic/189 |  1 +
 tests/generic/190 |  1 +
 tests/generic/191 |  1 +
 tests/generic/194 |  1 +
 tests/generic/195 |  1 +
 tests/generic/196 |  1 +
 tests/generic/197 |  1 +
 tests/generic/199 |  1 +
 tests/generic/200 |  1 +
 tests/generic/201 |  1 +
 tests/generic/284 |  1 +
 tests/generic/287 |  1 +
 tests/generic/289 |  1 +
 tests/generic/290 |  1 +
 tests/generic/291 |  1 +
 tests/generic/292 |  1 +
 tests/generic/293 |  1 +
 tests/generic/295 |  1 +
 tests/generic/352 |  1 +
 tests/generic/358 |  1 +
 tests/generic/359 |  1 +
 tests/generic/372 |  1 +
 tests/generic/414 |  1 +
 tests/generic/501 |  1 +
 tests/generic/515 |  1 +
 tests/generic/516 |  1 +
 tests/generic/540 |  1 +
 tests/generic/541 |  1 +
 tests/generic/542 |  1 +
 tests/generic/543 |  1 +
 tests/generic/544 |  1 +
 tests/generic/546 |  1 +
 tests/generic/578 |  1 +
 tests/generic/588 |  2 ++
 tests/xfs/208     |  1 +
 tests/xfs/210     |  1 +
 tests/xfs/212     |  1 +
 tests/xfs/215     |  1 +
 tests/xfs/218     |  1 +
 tests/xfs/219     |  1 +
 tests/xfs/221     |  1 +
 tests/xfs/223     |  1 +
 tests/xfs/224     |  1 +
 tests/xfs/225     |  1 +
 tests/xfs/226     |  1 +
 tests/xfs/228     |  1 +
 tests/xfs/230     |  1 +
 tests/xfs/248     |  1 +
 tests/xfs/249     |  1 +
 tests/xfs/251     |  1 +
 tests/xfs/254     |  1 +
 tests/xfs/255     |  1 +
 tests/xfs/256     |  1 +
 tests/xfs/257     |  1 +
 tests/xfs/258     |  1 +
 tests/xfs/280     |  1 +
 tests/xfs/312     |  1 +
 tests/xfs/315     |  1 +
 tests/xfs/322     |  1 +
 tests/xfs/329     |  1 +
 tests/xfs/436     |  1 +
 85 files changed, 101 insertions(+)
common/rc +16 -0
index d5cf5201..9378ff26 100644
@@ -4691,6 +4691,22 @@ _get_file_block_size()
 	esac
 }
 
+# Given a file path and a byte length of a file operation under test, ensure
+# that the length is an integer multiple of the file's allocation unit size.
+# In other words, skip the test unless (oplen ≡ alloc_unit mod 0).  This is
+# intended for file remapping operations.
+_require_congruent_file_oplen()
+{
+	local file="$1"
+	local alloc_unit=$(_get_file_block_size "$file")
+	local oplen="$2"
+
+	test $alloc_unit -gt $oplen && \
+		_notrun "$1: file alloc unit $alloc_unit larger than op length $oplen"
+	test $((oplen % alloc_unit)) -eq 0 || \
+		_notrun "$1: file alloc unit $alloc_unit not congruent with op length $oplen"
+}
+
 # Get the minimum block size of an fs.
 _get_block_size()
 {
tests/generic/031 +1 -0
index cbb2fc34..0d2e8268 100755
@@ -25,6 +25,7 @@ testfile=$SCRATCH_MNT/testfile
 
 _scratch_mkfs > /dev/null 2>&1
 _scratch_mount
+_require_congruent_file_oplen $SCRATCH_MNT 4096
 
 $XFS_IO_PROG -f \
 	-c "pwrite 185332 55756" \
tests/generic/116 +1 -0
index b8816e31..7f83d994 100755
@@ -31,6 +31,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $testdir $blksz
 _pwrite_byte 0x61 $((blksz * 2)) $((blksz * 6)) $testdir/file1 >> $seqres.full
 _pwrite_byte 0x61 $((blksz * 2)) $((blksz * 6)) $testdir/file2 >> $seqres.full
 _test_cycle_mount
tests/generic/118 +1 -0
index 4fa2e1e3..2b2a1b48 100755
@@ -32,6 +32,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $testdir $blksz
 _pwrite_byte 0x61 $((blksz * 2)) $((blksz * 6)) $testdir/file1 >> $seqres.full
 _pwrite_byte 0x62 $((blksz * 2)) $((blksz * 6)) $testdir/file2 >> $seqres.full
 _test_cycle_mount
tests/generic/119 +1 -0
index fd4c3661..bcf0fdc5 100755
@@ -34,6 +34,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $testdir $blksz
 _pwrite_byte 0x61 0 $((blksz * 8)) $testdir/file1 >> $seqres.full
 _pwrite_byte 0x62 0 $((blksz * 8)) $testdir/file2 >> $seqres.full
 _pwrite_byte 0x63 0 $((blksz * 8)) $testdir/file3 >> $seqres.full
tests/generic/121 +1 -0
index 43137469..e9038240 100755
@@ -31,6 +31,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $TEST_DIR $blksz
 _pwrite_byte 0x61 $((blksz * 2)) $((blksz * 6)) $testdir/file1 >> $seqres.full
 _pwrite_byte 0x61 $((blksz * 2)) $((blksz * 6)) $testdir/file2 >> $seqres.full
 _test_cycle_mount
tests/generic/122 +1 -0
index fbf3f1f2..bb1b605d 100755
@@ -31,6 +31,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $testdir $blksz
 _pwrite_byte 0x61 $((blksz * 2)) $((blksz * 6)) $testdir/file1 >> $seqres.full
 _pwrite_byte 0x62 $((blksz * 2)) $((blksz * 6)) $testdir/file2 >> $seqres.full
 _test_cycle_mount
tests/generic/134 +1 -0
index ab76f046..58b81872 100755
@@ -35,6 +35,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $TEST_DIR $blksz
 _pwrite_byte 0x61 0 $((blksz + 37)) $testdir/file1 >> $seqres.full
 _pwrite_byte 0x61 0 $((blksz + 37)) $testdir/file2 >> $seqres.full
 _pwrite_byte 0x62 0 $((blksz + 37)) $testdir/file3 >> $seqres.full
tests/generic/136 +1 -0
index 98ebb0da..c5b80074 100755
@@ -35,6 +35,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $TEST_DIR $blksz
 _pwrite_byte 0x61 0 $((blksz + 37)) $testdir/file1 >> $seqres.full
 _pwrite_byte 0x61 0 $((blksz + 37)) $testdir/file2 >> $seqres.full
 _pwrite_byte 0x62 0 $((blksz + 37)) $testdir/file3 >> $seqres.full
tests/generic/137 +1 -0
index fb0071b1..8ee705fd 100755
@@ -37,6 +37,7 @@ mkdir $testdir
 
 echo "Create the original file blocks"
 blksz=65536
+_require_congruent_file_oplen $TEST_DIR $blksz
 _pwrite_byte 0x61 0 $blksz $testdir/file1 >> $seqres.full
 _pwrite_byte 0x62 $blksz $((blksz * 2)) $testdir/file1 >> $seqres.full
 
tests/generic/144 +1 -0
index 842d51f3..35f7a319 100755
@@ -35,6 +35,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $testdir $blksz
 _pwrite_byte 0x61 0 $((blksz * 5 + 37)) $testdir/file1 >> $seqres.full
 
 _reflink_range $testdir/file1 $blksz $testdir/file2 $blksz \
tests/generic/149 +1 -0
index 5343a139..108f1368 100755
@@ -35,6 +35,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $TEST_DIR $blksz
 _pwrite_byte 0x61 0 $blksz $testdir/file1 >> $seqres.full
 _pwrite_byte 0x62 $blksz $blksz $testdir/file1 >> $seqres.full
 _pwrite_byte 0x63 $((blksz * 2)) $blksz $testdir/file1 >> $seqres.full
tests/generic/162 +1 -0
index 0dc17f75..7b625e86 100755
@@ -38,6 +38,7 @@ mkdir $testdir
 loops=512
 nr_loops=$((loops - 1))
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 
 echo "Initialize files"
 echo >> $seqres.full
tests/generic/163 +1 -0
index 4a6c341e..91da69d3 100755
@@ -38,6 +38,7 @@ mkdir $testdir
 loops=512
 nr_loops=$((loops - 1))
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 
 echo "Initialize files"
 echo >> $seqres.full
tests/generic/164 +1 -0
index 8e0b630b..56c05e37 100755
@@ -40,6 +40,7 @@ mkdir $testdir
 loops=512
 nr_loops=$((loops - 1))
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 
 echo "Initialize files"
 echo >> $seqres.full
tests/generic/165 +1 -0
index d9e6a6e9..bc24bcab 100755
@@ -41,6 +41,7 @@ mkdir $testdir
 loops=512
 nr_loops=$((loops - 1))
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 
 echo "Initialize files"
 echo >> $seqres.full
tests/generic/168 +1 -0
index 575ff08c..bdc8f7a0 100755
@@ -39,6 +39,7 @@ mkdir $testdir
 loops=1024
 nr_loops=$((loops - 1))
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 
 echo "Initialize files"
 echo >> $seqres.full
tests/generic/170 +1 -0
index d323ab8f..593cfbb7 100755
@@ -40,6 +40,7 @@ mkdir $testdir
 loops=1024
 nr_loops=$((loops - 1))
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 
 echo "Initialize files"
 echo >> $seqres.full
tests/generic/181 +1 -0
index 2b4617be..5e5883df 100755
@@ -33,6 +33,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $TEST_DIR $blksz
 _pwrite_byte 0x61 0 $((blksz * 256)) $testdir/file1 >> $seqres.full
 _pwrite_byte 0x62 0 $((blksz * 256)) $testdir/file2 >> $seqres.full
 _pwrite_byte 0x62 0 $((blksz * 2)) $testdir/file2.chk >> $seqres.full
tests/generic/183 +1 -0
index 77bfcfcb..c8614514 100755
@@ -39,6 +39,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=64
 filesize=$((blksz * nr))
 _pwrite_byte 0x61 0 $filesize $testdir/file1 >> $seqres.full
tests/generic/185 +1 -0
index 09469924..75dbc6b8 100755
@@ -38,6 +38,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=64
 filesize=$((blksz * nr))
 _pwrite_byte 0x61 0 $filesize $testdir/file1 >> $seqres.full
tests/generic/186 +1 -0
index 37d88440..c5a1e13a 100755
@@ -81,6 +81,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=1024
 filesize=$((blksz * nr))
 _pwrite_byte 0x61 0 $filesize $testdir/file1 >> $seqres.full
tests/generic/187 +1 -0
index 152e3cc2..be7a635a 100755
@@ -82,6 +82,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=1024
 filesize=$((blksz * nr))
 _pwrite_byte 0x61 0 $filesize $testdir/file1 >> $seqres.full
tests/generic/188 +1 -0
index eab77b39..52a7f2d2 100755
@@ -39,6 +39,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=64
 filesize=$((blksz * nr))
 _weave_reflink_unwritten $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
tests/generic/189 +1 -0
index 75cca42a..63faac6e 100755
@@ -38,6 +38,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=64
 filesize=$((blksz * nr))
 _weave_reflink_unwritten $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
tests/generic/190 +1 -0
index 9e220740..b336f12b 100755
@@ -39,6 +39,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=64
 filesize=$((blksz * nr))
 _weave_reflink_holes $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
tests/generic/191 +1 -0
index 78b9a3f0..1b12d9ac 100755
@@ -38,6 +38,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=64
 filesize=$((blksz * nr))
 _weave_reflink_holes $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
tests/generic/194 +1 -0
index ff76438d..aa80560b 100755
@@ -41,6 +41,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=64
 filesize=$((blksz * nr))
 _weave_reflink_holes $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
tests/generic/195 +1 -0
index e087b99c..4f21201e 100755
@@ -40,6 +40,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=64
 filesize=$((blksz * nr))
 _weave_reflink_holes $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
tests/generic/196 +1 -0
index e2ae0410..366d0cad 100755
@@ -39,6 +39,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=64
 filesize=$((blksz * nr))
 _weave_reflink_regular $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
tests/generic/197 +1 -0
index c5f80207..ac314186 100755
@@ -38,6 +38,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=64
 filesize=$((blksz * nr))
 _weave_reflink_regular $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
tests/generic/199 +1 -0
index 2a8cafcc..2246fdd1 100755
@@ -46,6 +46,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=64
 filesize=$((blksz * nr))
 _weave_reflink_rainbow $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
tests/generic/200 +1 -0
index a1a78ef4..eeefeb50 100755
@@ -46,6 +46,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=64
 filesize=$((blksz * nr))
 _weave_reflink_rainbow $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
tests/generic/201 +1 -0
index 2598b44a..0a5a1d4a 100755
@@ -34,6 +34,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=64
 filesize=$((blksz * nr))
 _pwrite_byte 0x61 0 $filesize $testdir/file1 >> $seqres.full
tests/generic/284 +1 -0
index 729da77a..f9eefff3 100755
@@ -32,6 +32,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=64
 filesize=$((blksz * nr))
 _sweave_reflink_regular $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
tests/generic/287 +1 -0
index 76ea26ba..61301368 100755
@@ -33,6 +33,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=64
 filesize=$((blksz * nr))
 _sweave_reflink_regular $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
tests/generic/289 +1 -0
index ed4f3268..52d03c35 100755
@@ -34,6 +34,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=64
 filesize=$((blksz * nr))
 _sweave_reflink_unwritten $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
tests/generic/290 +1 -0
index 534fb24f..5352b9ba 100755
@@ -35,6 +35,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=64
 filesize=$((blksz * nr))
 _sweave_reflink_unwritten $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
tests/generic/291 +1 -0
index 50119c03..1c589cf6 100755
@@ -34,6 +34,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=64
 filesize=$((blksz * nr))
 _sweave_reflink_holes $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
tests/generic/292 +1 -0
index 24cdab53..725fe057 100755
@@ -35,6 +35,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=64
 filesize=$((blksz * nr))
 _sweave_reflink_holes $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
tests/generic/293 +1 -0
index 0f1d8416..05997501 100755
@@ -36,6 +36,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=64
 filesize=$((blksz * nr))
 _sweave_reflink_holes $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
tests/generic/295 +1 -0
index f66c1805..9ccf823f 100755
@@ -37,6 +37,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=64
 filesize=$((blksz * nr))
 _sweave_reflink_holes $blksz $nr $testdir/file1 $testdir/file3 >> $seqres.full
tests/generic/352 +1 -0
index 3f504a29..608c6c81 100755
@@ -29,6 +29,7 @@ _scratch_mkfs > /dev/null 2>&1
 _scratch_mount
 
 blocksize=$((128 * 1024))
+_require_congruent_file_oplen $SCRATCH_MNT $blocksize
 file="$SCRATCH_MNT/tmp"
 
 # Golden output is for $LOAD_FACTOR == 1 case
tests/generic/358 +1 -0
index 8c73ba36..91fe5e2b 100755
@@ -39,6 +39,7 @@ mkdir $testdir
 
 blocks=64
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 
 echo "Initialize file"
 _pwrite_byte 0x61 0 $((blocks * blksz)) $testdir/file >> $seqres.full
tests/generic/359 +1 -0
index 25692058..8ef4f846 100755
@@ -41,6 +41,7 @@ mkdir $testdir
 
 blocks=64
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=4
 halfway=$((blocks / 2 * blksz))
 quarter=$((blocks / 4 * blksz))
tests/generic/372 +1 -0
index b83aa598..b649f590 100755
@@ -39,6 +39,7 @@ mkdir $testdir
 
 blocks=5
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 sz=$((blocks * blksz))
 
 echo "Create the original files"
tests/generic/414 +1 -0
index 01b9da8e..6416216d 100755
@@ -39,6 +39,7 @@ mkdir $testdir
 
 blocks=32
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 sz=$((blocks * blksz))
 
 echo "Create the original files"
tests/generic/501 +1 -0
index 8c3f627b..cb158ba5 100755
@@ -34,6 +34,7 @@ _scratch_mkfs >>$seqres.full 2>&1
 _require_metadata_journaling $SCRATCH_DEV
 _init_flakey
 _mount_flakey
+_require_congruent_file_oplen $SCRATCH_MNT 2097152
 
 # Use file sizes and offsets/lengths for the clone operation that are multiples
 # of 64Kb, so that the test works on machine with any page size.
tests/generic/515 +1 -0
index 2f3bd400..758bd639 100755
@@ -30,6 +30,7 @@ _scratch_mount
 DONOR1=$SCRATCH_MNT/a
 TARGET=$SCRATCH_MNT/b
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 
 $XFS_IO_PROG -f -c "pwrite -S 0x72 0 $blksz" $DONOR1 >> $seqres.full
 
tests/generic/516 +1 -0
index 790ad532..e846ee24 100755
@@ -31,6 +31,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $TEST_DIR $blksz
 _pwrite_byte 0x61 $((blksz * 2)) $((blksz * 6)) $testdir/file1 >> $seqres.full
 _pwrite_byte 0x61 $((blksz * 2)) $((blksz * 6)) $testdir/file2 >> $seqres.full
 _pwrite_byte 0x62 $(((blksz * 6) - 33)) 1 $testdir/file2 >> $seqres.full
tests/generic/540 +1 -0
index 38e00f97..da36939a 100755
@@ -38,6 +38,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=64
 filesize=$((blksz * nr))
 _pwrite_byte 0x64 0 $((blksz * nr)) $testdir/file2 >> $seqres.full
tests/generic/541 +1 -0
index 89b2adad..a0f6cae3 100755
@@ -38,6 +38,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=64
 filesize=$((blksz * nr))
 _pwrite_byte 0x64 0 $((blksz * nr)) $testdir/file2 >> $seqres.full
tests/generic/542 +1 -0
index e7682f59..530fb8e0 100755
@@ -38,6 +38,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=64
 filesize=$((blksz * nr))
 _pwrite_byte 0x64 0 $((blksz * nr)) $testdir/file2 >> $seqres.full
tests/generic/543 +1 -0
index 624cfc41..1dad37fb 100755
@@ -38,6 +38,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=64
 filesize=$((blksz * nr))
 _pwrite_byte 0x64 0 $((blksz * nr)) $testdir/file2 >> $seqres.full
tests/generic/544 +1 -0
index 4dbaea4d..a4f654af 100755
@@ -27,6 +27,7 @@ _scratch_mkfs > $seqres.full 2>&1
 _scratch_mount >> $seqres.full 2>&1
 
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=2
 filesize=$((blksz * nr))
 testdir=$SCRATCH_MNT/test-$seq
tests/generic/546 +1 -0
index 7723b980..9dc507be 100755
@@ -39,6 +39,7 @@ _scratch_mkfs_sized $((512 * 1024 * 1024)) >> $seqres.full 2>&1
 _require_metadata_journaling $SCRATCH_DEV
 _init_flakey
 _mount_flakey
+_require_congruent_file_oplen $SCRATCH_MNT 4096
 
 # Create preallocated extent where we can write into
 $XFS_IO_PROG -f -c 'falloc 8k 64m' "$SCRATCH_MNT/foobar" >> $seqres.full
tests/generic/578 +1 -0
index 01929a28..d04cacb4 100755
@@ -41,6 +41,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $TEST_DIR $blksz
 filesz=$((blksz * 4))
 _pwrite_byte 0x61 0 $filesz $testdir/file1 >> $seqres.full
 _cp_reflink $testdir/file1 $testdir/file2 >> $seqres.full
tests/generic/588 +2 -0
index 563ff65e..a915a73e 100755
@@ -35,6 +35,8 @@ _require_metadata_journaling $SCRATCH_DEV
 _init_flakey
 _mount_flakey
 
+_require_congruent_file_oplen $SCRATCH_MNT 65536
+
 # Create our test file with two 256Kb extents, one at file offset 0 and the
 # other at file offset 256Kb.
 $XFS_IO_PROG -f -c "pwrite -S 0xa3 0 256K" \
tests/xfs/208 +1 -0
index 66c3eda1..0fbb99c8 100755
@@ -35,6 +35,7 @@ testdir=$SCRATCH_MNT/test-$seq
 mkdir $testdir
 
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=128
 filesize=$((blksz * nr))
 bufnr=16
tests/xfs/210 +1 -0
index 6edc5606..2439967b 100755
@@ -27,6 +27,7 @@ _require_xfs_io_command "cowextsize"
 echo "Format and mount"
 _scratch_mkfs > $seqres.full 2>&1
 _scratch_mount >> $seqres.full 2>&1
+_require_congruent_file_oplen $SCRATCH_MNT 65536
 
 testdir=$SCRATCH_MNT/test-$seq
 mkdir $testdir
tests/xfs/212 +1 -0
index b133e09b..805a72af 100755
@@ -30,6 +30,7 @@ testdir=$SCRATCH_MNT/test-$seq
 mkdir $testdir
 
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=16
 filesize=$((blksz * nr))
 bufnr=2
tests/xfs/215 +1 -0
index 20217187..c07cdd1a 100755
@@ -34,6 +34,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=64
 filesize=$((blksz * nr))
 real_blksz=$(_get_block_size $testdir)
tests/xfs/218 +1 -0
index b834bbeb..cc3e1552 100755
@@ -33,6 +33,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=64
 filesize=$((blksz * nr))
 real_blksz=$(_get_block_size $testdir)
tests/xfs/219 +1 -0
index b0eeb784..bd2c47bf 100755
@@ -34,6 +34,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=64
 filesize=$((blksz * nr))
 real_blksz=$(_get_block_size $testdir)
tests/xfs/221 +1 -0
index 09b2067d..cda99b5c 100755
@@ -33,6 +33,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=64
 filesize=$((blksz * nr))
 real_blksz=$(_get_block_size $testdir)
tests/xfs/223 +1 -0
index 11dbad14..e22c1ba9 100755
@@ -36,6 +36,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=64
 filesize=$((blksz * nr))
 real_blksz=$(_get_block_size $testdir)
tests/xfs/224 +1 -0
index f8bab07e..7e984a8a 100755
@@ -35,6 +35,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=64
 filesize=$((blksz * nr))
 real_blksz=$(_get_block_size $testdir)
tests/xfs/225 +1 -0
index 52a37d64..a07ef3f0 100755
@@ -34,6 +34,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=64
 filesize=$((blksz * nr))
 real_blksz=$(_get_block_size $testdir)
tests/xfs/226 +1 -0
index 826bd08d..1e566e2e 100755
@@ -33,6 +33,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=64
 filesize=$((blksz * nr))
 real_blksz=$(_get_block_size $testdir)
tests/xfs/228 +1 -0
index f2f2f6a9..85a4abc5 100755
@@ -41,6 +41,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=64
 filesize=$((blksz * nr))
 real_blksz=$(_get_block_size $testdir)
tests/xfs/230 +1 -0
index 15f6b684..2347a307 100755
@@ -41,6 +41,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=64
 filesize=$((blksz * nr))
 real_blksz=$(_get_block_size $testdir)
tests/xfs/248 +1 -0
index 32902cb7..cdb1da02 100755
@@ -34,6 +34,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=64
 filesize=$((blksz * nr))
 $XFS_IO_PROG -c "cowextsize $((blksz * 16))" $testdir >> $seqres.full
tests/xfs/249 +1 -0
index 774d3bf2..0c4b0335 100755
@@ -35,6 +35,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=64
 filesize=$((blksz * nr))
 $XFS_IO_PROG -c "cowextsize $((blksz * 16))" $testdir >> $seqres.full
tests/xfs/251 +1 -0
index 0b090180..1efa331d 100755
@@ -36,6 +36,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=64
 filesize=$((blksz * nr))
 $XFS_IO_PROG -c "cowextsize $((blksz * 16))" $testdir >> $seqres.full
tests/xfs/254 +1 -0
index 40d176fc..d08ccc52 100755
@@ -37,6 +37,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=64
 filesize=$((blksz * nr))
 $XFS_IO_PROG -c "cowextsize $((blksz * 16))" $testdir >> $seqres.full
tests/xfs/255 +1 -0
index 255f3b2f..8ec6f0be 100755
@@ -36,6 +36,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=64
 filesize=$((blksz * nr))
 $XFS_IO_PROG -c "cowextsize $((blksz * 16))" $testdir >> $seqres.full
tests/xfs/256 +1 -0
index 1c703242..7157d532 100755
@@ -37,6 +37,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=64
 filesize=$((blksz * nr))
 $XFS_IO_PROG -c "cowextsize $((blksz * 16))" $testdir >> $seqres.full
tests/xfs/257 +1 -0
index 6a58f0ac..c3100d60 100755
@@ -38,6 +38,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=64
 filesize=$((blksz * nr))
 $XFS_IO_PROG -c "cowextsize $((blksz * 16))" $testdir >> $seqres.full
tests/xfs/258 +1 -0
index 2865cdf9..a3a130ea 100755
@@ -39,6 +39,7 @@ mkdir $testdir
 
 echo "Create the original files"
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=64
 filesize=$((blksz * nr))
 $XFS_IO_PROG -c "cowextsize $((blksz * 16))" $testdir >> $seqres.full
tests/xfs/280 +1 -0
index bc26e629..0d9a7958 100755
@@ -30,6 +30,7 @@ mkdir $testdir
 
 blocks=5
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 sz=$((blocks * blksz))
 
 echo "Create the original files"
tests/xfs/312 +1 -0
index 94f868fe..e4884787 100755
@@ -36,6 +36,7 @@ sz=$((blksz * blks))
 echo "Format filesystem"
 _scratch_mkfs >/dev/null 2>&1
 _scratch_mount >> $seqres.full
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 
 echo "Create files"
 _pwrite_byte 0x66 0 $sz $SCRATCH_MNT/file1 >> $seqres.full
tests/xfs/315 +1 -0
index 105515ab..9f6b39c8 100755
@@ -37,6 +37,7 @@ sz=$((blksz * blks))
 echo "Format filesystem"
 _scratch_mkfs >/dev/null 2>&1
 _scratch_mount >> $seqres.full
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 
 $XFS_IO_PROG -c "cowextsize $sz" $SCRATCH_MNT
 
tests/xfs/322 +1 -0
index 89a2f741..a2c3720e 100755
@@ -36,6 +36,7 @@ sz=$((blksz * blks))
 echo "Format filesystem"
 _scratch_mkfs >/dev/null 2>&1
 _scratch_mount >> $seqres.full
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 
 echo "Create files"
 _pwrite_byte 0x66 0 $sz $SCRATCH_MNT/file1 >> $seqres.full
tests/xfs/329 +1 -0
index e9a30d05..4cad686c 100755
@@ -31,6 +31,7 @@ _scratch_mount >> "$seqres.full" 2>&1
 
 testdir="$SCRATCH_MNT/test-$seq"
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 blks=3
 mkdir "$testdir"
 
tests/xfs/436 +1 -0
index d99183cf..9e6ec937 100755
@@ -42,6 +42,7 @@ _scratch_mount -o noquota >> "$seqres.full" 2>&1
 
 testdir="$SCRATCH_MNT/test-$seq"
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 blks=3
 mkdir "$testdir"
 
Signature · 1 line
2.31.0
#2 lore raw

PATCH 2/2 misc: skip extent size hint tests when hint not congruent with file allocation unit

In reply to Theodore Ts'o

From: "Darrick J. Wong" <[email protected]>

XFS files have an extent size hint, which tells the block allocator that it should try to allocate larger aligned blocks when possible. These hints must be some integer multiple of the allocation unit size, which is one fs block for files on the data device, and one rt extent for files on the realtime device. For tests that are hardwired to a static extent size hint, the fssetxattr call will fail if the hint isn't congruent, so just skip those tests.

(Cherry-picked from check-blocksize-congruency_2021-11-23)

---
 tests/xfs/069 | 1 +
 tests/xfs/180 | 1 +
 tests/xfs/182 | 1 +
 tests/xfs/184 | 1 +
 tests/xfs/192 | 1 +
 tests/xfs/193 | 1 +
 tests/xfs/198 | 1 +
 tests/xfs/200 | 1 +
 tests/xfs/204 | 1 +
 tests/xfs/209 | 1 +
 tests/xfs/211 | 1 +
 tests/xfs/231 | 1 +
 tests/xfs/232 | 1 +
 tests/xfs/237 | 1 +
 tests/xfs/239 | 1 +
 tests/xfs/240 | 1 +
 tests/xfs/241 | 1 +
 tests/xfs/326 | 1 +
 tests/xfs/346 | 1 +
 tests/xfs/347 | 1 +
 tests/xfs/507 | 3 +++
 21 files changed, 23 insertions(+)
tests/xfs/069 +1 -0
index bf4aa202..b3074e25 100755
@@ -22,6 +22,7 @@ _require_scratch
 
 _scratch_mkfs_xfs >/dev/null 2>&1
 _scratch_mount
+_require_congruent_file_oplen $SCRATCH_MNT 8388608
 
 small=$SCRATCH_MNT/small
 big=$SCRATCH_MNT/big
tests/xfs/180 +1 -0
index 72a1b738..9b52f1ff 100755
@@ -32,6 +32,7 @@ testdir=$SCRATCH_MNT/test-$seq
 mkdir $testdir
 
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=128
 filesize=$((blksz * nr))
 bufnr=16
tests/xfs/182 +1 -0
index ea565824..93852229 100755
@@ -33,6 +33,7 @@ testdir=$SCRATCH_MNT/test-$seq
 mkdir $testdir
 
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=128
 filesize=$((blksz * nr))
 bufnr=16
tests/xfs/184 +1 -0
index 95250b29..2ca6528e 100755
@@ -33,6 +33,7 @@ testdir=$SCRATCH_MNT/test-$seq
 mkdir $testdir
 
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=128
 filesize=$((blksz * nr))
 bufnr=16
tests/xfs/192 +1 -0
index 1eb9d52e..8329604d 100755
@@ -34,6 +34,7 @@ testdir=$SCRATCH_MNT/test-$seq
 mkdir $testdir
 
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=128
 filesize=$((blksz * nr))
 bufnr=16
tests/xfs/193 +1 -0
index 1bc48610..18f2fc2f 100755
@@ -31,6 +31,7 @@ testdir=$SCRATCH_MNT/test-$seq
 mkdir $testdir
 
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=128
 filesize=$((blksz * nr))
 bufnr=16
tests/xfs/198 +1 -0
index 0c650874..231e1c23 100755
@@ -32,6 +32,7 @@ testdir=$SCRATCH_MNT/test-$seq
 mkdir $testdir
 
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=128
 filesize=$((blksz * nr))
 bufnr=16
tests/xfs/200 +1 -0
index 2324fbdb..435cd9b9 100755
@@ -35,6 +35,7 @@ testdir=$SCRATCH_MNT/test-$seq
 mkdir $testdir
 
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=128
 filesize=$((blksz * nr))
 bufnr=16
tests/xfs/204 +1 -0
index 931be128..3f9b6dca 100755
@@ -36,6 +36,7 @@ testdir=$SCRATCH_MNT/test-$seq
 mkdir $testdir
 
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=128
 filesize=$((blksz * nr))
 bufnr=16
tests/xfs/209 +1 -0
index 220ea31d..08ec87f5 100755
@@ -23,6 +23,7 @@ _require_xfs_io_command "cowextsize"
 echo "Format and mount"
 _scratch_mkfs > $seqres.full 2>&1
 _scratch_mount >> $seqres.full 2>&1
+_require_congruent_file_oplen $SCRATCH_MNT 1048576
 
 testdir=$SCRATCH_MNT/test-$seq
 mkdir $testdir
tests/xfs/211 +1 -0
index 05515041..b99871ba 100755
@@ -33,6 +33,7 @@ testdir=$SCRATCH_MNT/test-$seq
 mkdir $testdir
 
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=50000
 filesize=$((blksz * nr))
 bufnr=16
tests/xfs/231 +1 -0
index 8155d0ab..fd7d7a85 100755
@@ -45,6 +45,7 @@ testdir=$SCRATCH_MNT/test-$seq
 mkdir $testdir
 
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=64
 filesize=$((blksz * nr))
 bufnr=2
tests/xfs/232 +1 -0
index 06217466..0bf3bb75 100755
@@ -46,6 +46,7 @@ testdir=$SCRATCH_MNT/test-$seq
 mkdir $testdir
 
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=64
 filesize=$((blksz * nr))
 bufnr=2
tests/xfs/237 +1 -0
index 34d54a6c..db235e05 100755
@@ -46,6 +46,7 @@ bufsize=$((blksz * bufnr))
 alignment=`_min_dio_alignment $TEST_DEV`
 
 _require_fs_space $SCRATCH_MNT $((filesize / 1024 * 3 * 5 / 4))
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 
 echo "Create the original files"
 $XFS_IO_PROG -c "cowextsize $((bufsize * 2))" $testdir
tests/xfs/239 +1 -0
index 5143cc2e..f04460bc 100755
@@ -35,6 +35,7 @@ testdir=$SCRATCH_MNT/test-$seq
 mkdir $testdir
 
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=640
 bufnr=128
 filesize=$((blksz * nr))
tests/xfs/240 +1 -0
index e5d35a83..a65c270d 100755
@@ -40,6 +40,7 @@ testdir=$SCRATCH_MNT/test-$seq
 mkdir $testdir
 
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=640
 bufnr=128
 filesize=$((blksz * nr))
tests/xfs/241 +1 -0
index 7988c2d8..d9879788 100755
@@ -36,6 +36,7 @@ testdir=$SCRATCH_MNT/test-$seq
 mkdir $testdir
 
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=640
 bufnr=128
 filesize=$((blksz * nr))
tests/xfs/326 +1 -0
index 8b95a18a..d8a9ac25 100755
@@ -40,6 +40,7 @@ echo "Format filesystem"
 _scratch_mkfs >/dev/null 2>&1
 _scratch_mount >> $seqres.full
 
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 $XFS_IO_PROG -c "cowextsize $sz" $SCRATCH_MNT
 
 echo "Create files"
tests/xfs/346 +1 -0
index bb542202..6d371342 100755
@@ -34,6 +34,7 @@ testdir=$SCRATCH_MNT/test-$seq
 mkdir $testdir
 
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=128
 filesize=$((blksz * nr))
 bufnr=8
tests/xfs/347 +1 -0
index 63ee1ec6..86f405b5 100755
@@ -33,6 +33,7 @@ testdir=$SCRATCH_MNT/test-$seq
 mkdir $testdir
 
 blksz=65536
+_require_congruent_file_oplen $SCRATCH_MNT $blksz
 nr=128
 filesize=$((blksz * nr))
 bufnr=8
tests/xfs/507 +3 -0
index b9c9ab29..8757152e 100755
@@ -44,6 +44,9 @@ echo "Format and mount"
 _scratch_mkfs > "$seqres.full" 2>&1
 _scratch_mount
 
+fs_blksz=$(_get_block_size $SCRATCH_MNT)
+_require_congruent_file_oplen $SCRATCH_MNT $((MAXEXTLEN * fs_blksz))
+
 # Create a huge sparse filesystem on the scratch device because that's what
 # we're going to need to guarantee that we have enough blocks to overflow in
 # the first place.  We need to have at least enough free space on that huge fs
Signature · 1 line
2.31.0
#3 lore raw
In reply to Theodore Ts'o
Quoted 7 lines · Theodore Ts'o

These are tests in my out-of-tree patches to xfstests, which were cherry-picked from Darrick's out-of-tree patches. They are needed to prevent a huge whackload (that's a technical term) of test failures in the xfs/realtime_28k_logdev test config, which uses:

XFS_MKFS_OPTIONS='-d rtinherit=1 -m reflink=0,rmapbt=0 -r extsize=28k '

Quoted 7 lines

and uses an external logdevice as well as an external realtime device.

This test config is being used in the xfs 5.15 backports testing, since it's one of Darrick's upstream acceptance test configs.

Darrick, any objections if I ask Zorro to consider these for upstream xfstests?

Hmm, maybe I should post the most recent version of this. Ok, I'll move towards upstream head and send it in a day or two.

--D

Quoted 117 lines

Darrick J. Wong (2):
misc: skip remap/fallocate tests when op length not congruent with
file allocation unit
misc: skip extent size hint tests when hint not congruent with file
allocation unit

 common/rc         | 16 ++++++++++++++++
 tests/generic/031 |  1 +
 tests/generic/116 |  1 +
 tests/generic/118 |  1 +
 tests/generic/119 |  1 +
 tests/generic/121 |  1 +
 tests/generic/122 |  1 +
 tests/generic/134 |  1 +
 tests/generic/136 |  1 +
 tests/generic/137 |  1 +
 tests/generic/144 |  1 +
 tests/generic/149 |  1 +
 tests/generic/162 |  1 +
 tests/generic/163 |  1 +
 tests/generic/164 |  1 +
 tests/generic/165 |  1 +
 tests/generic/168 |  1 +
 tests/generic/170 |  1 +
 tests/generic/181 |  1 +
 tests/generic/183 |  1 +
 tests/generic/185 |  1 +
 tests/generic/186 |  1 +
 tests/generic/187 |  1 +
 tests/generic/188 |  1 +
 tests/generic/189 |  1 +
 tests/generic/190 |  1 +
 tests/generic/191 |  1 +
 tests/generic/194 |  1 +
 tests/generic/195 |  1 +
 tests/generic/196 |  1 +
 tests/generic/197 |  1 +
 tests/generic/199 |  1 +
 tests/generic/200 |  1 +
 tests/generic/201 |  1 +
 tests/generic/284 |  1 +
 tests/generic/287 |  1 +
 tests/generic/289 |  1 +
 tests/generic/290 |  1 +
 tests/generic/291 |  1 +
 tests/generic/292 |  1 +
 tests/generic/293 |  1 +
 tests/generic/295 |  1 +
 tests/generic/352 |  1 +
 tests/generic/358 |  1 +
 tests/generic/359 |  1 +
 tests/generic/372 |  1 +
 tests/generic/414 |  1 +
 tests/generic/501 |  1 +
 tests/generic/515 |  1 +
 tests/generic/516 |  1 +
 tests/generic/540 |  1 +
 tests/generic/541 |  1 +
 tests/generic/542 |  1 +
 tests/generic/543 |  1 +
 tests/generic/544 |  1 +
 tests/generic/546 |  1 +
 tests/generic/578 |  1 +
 tests/generic/588 |  2 ++
 tests/xfs/069     |  1 +
 tests/xfs/180     |  1 +
 tests/xfs/182     |  1 +
 tests/xfs/184     |  1 +
 tests/xfs/192     |  1 +
 tests/xfs/193     |  1 +
 tests/xfs/198     |  1 +
 tests/xfs/200     |  1 +
 tests/xfs/204     |  1 +
 tests/xfs/208     |  1 +
 tests/xfs/209     |  1 +
 tests/xfs/210     |  1 +
 tests/xfs/211     |  1 +
 tests/xfs/212     |  1 +
 tests/xfs/215     |  1 +
 tests/xfs/218     |  1 +
 tests/xfs/219     |  1 +
 tests/xfs/221     |  1 +
 tests/xfs/223     |  1 +
 tests/xfs/224     |  1 +
 tests/xfs/225     |  1 +
 tests/xfs/226     |  1 +
 tests/xfs/228     |  1 +
 tests/xfs/230     |  1 +
 tests/xfs/231     |  1 +
 tests/xfs/232     |  1 +
 tests/xfs/237     |  1 +
 tests/xfs/239     |  1 +
 tests/xfs/240     |  1 +
 tests/xfs/241     |  1 +
 tests/xfs/248     |  1 +
 tests/xfs/249     |  1 +
 tests/xfs/251     |  1 +
 tests/xfs/254     |  1 +
 tests/xfs/255     |  1 +
 tests/xfs/256     |  1 +
 tests/xfs/257     |  1 +
 tests/xfs/258     |  1 +
 tests/xfs/280     |  1 +
 tests/xfs/312     |  1 +
 tests/xfs/315     |  1 +
 tests/xfs/322     |  1 +
 tests/xfs/326     |  1 +
 tests/xfs/329     |  1 +
 tests/xfs/346     |  1 +
 tests/xfs/347     |  1 +
 tests/xfs/436     |  1 +
 tests/xfs/507     |  3 +++
 106 files changed, 124 insertions(+)
Signature · 1 line
2.31.0
#4 lore raw
Quoted 10 lines · Darrick J. Wong
Quoted 9 lines · Theodore Ts'o

These are tests in my out-of-tree patches to xfstests, which were cherry-picked from Darrick's out-of-tree patches. They are needed to prevent a huge whackload (that's a technical term) of test failures in the xfs/realtime_28k_logdev test config, which uses:

XFS_MKFS_OPTIONS='-d rtinherit=1 -m reflink=0,rmapbt=0 -r extsize=28k '

and uses an external logdevice as well as an external realtime device.

Quoted 8 lines
Quoted 5 lines

This test config is being used in the xfs 5.15 backports testing, since it's one of Darrick's upstream acceptance test configs.

Darrick, any objections if I ask Zorro to consider these for upstream xfstests?

Hmm, maybe I should post the most recent version of this. Ok, I'll move towards upstream head and send it in a day or two.

Many thanks!

I'll be on the lookout of your patches and drop the older versions of the aptch (from November 2021) from my tree once they show up.

- Ted