]> git.apps.os.sepia.ceph.com Git - xfstests-dev.git/commitdiff
xfs/161: adapt the test case for LBS filesystem
authorPankaj Raghav <p.raghav@samsung.com>
Wed, 16 Oct 2024 23:15:32 +0000 (16:15 -0700)
committerZorro Lang <zlang@kernel.org>
Wed, 23 Oct 2024 04:23:57 +0000 (12:23 +0800)
This test fails for >= 64k filesystem block size on a 4k PAGE_SIZE
system(see LBS efforts[1]). Adapt the blksz so that we create more than
one block for the testcase.

Cap the blksz to be at least 64k to retain the same behaviour as before
for smaller filesystem blocksizes.

[1] LBS effort: https://lore.kernel.org/lkml/20230915183848.1018717-1-kernel@pankajraghav.com/

Signed-off-by: Pankaj Raghav <p.raghav@samsung.com>
Reviewed-by: Darrick J. Wong <djwong@kernel.org>
Reviewed-by: Zorro Lang <zlang@redhat.com>
Signed-off-by: Darrick J. Wong <djwong@kernel.org>
Reviewed-by: Christoph Hellwig <hch@lst.de>
Signed-off-by: Zorro Lang <zlang@kernel.org>
tests/xfs/161

index 002ee7d800dcf125f6d7e3723cdafd57cb1d39d9..948121c0569484831eddfaf5bdcfefea07e5b3fd 100755 (executable)
@@ -37,7 +37,11 @@ _scratch_xfs_db -c 'version' -c 'sb 0' -c 'p' >> $seqres.full
 _scratch_mount >> $seqres.full
 
 
-blksz=$(_get_file_block_size "$SCRATCH_MNT")
+min_blksz=65536
+file_blksz=$(_get_file_block_size "$SCRATCH_MNT")
+blksz=$(( 2 * $file_blksz))
+
+blksz=$(( blksz > min_blksz ? blksz : min_blksz ))
 # Write more than one block to exceed the soft block quota limit via
 # xfs_quota.
 filesz=$(( 2 * $blksz))