]> git.apps.os.sepia.ceph.com Git - xfstests-dev.git/commitdiff
generic/033: Don't call 'fzero' with the KEEP_SIZE flag
authorAnna Schumaker <anna.schumaker@oracle.com>
Fri, 25 Apr 2025 15:24:52 +0000 (11:24 -0400)
committerZorro Lang <zlang@kernel.org>
Sat, 26 Apr 2025 12:53:52 +0000 (20:53 +0800)
None of the fzero calls in this test end up writing past the end of the
file, so this flag is unnecessary and can cause the test to fail on
filesystems that don't implement FALLOC_FL_KEEP_SIZE.

Signed-off-by: Anna Schumaker <anna.schumaker@oracle.com>
Reviewed-by: Darrick J. Wong <djwong@kernel.org>
Reviewed-by: Zorro Lang <zlang@redhat.com>
Signed-off-by: Zorro Lang <zlang@kernel.org>
tests/generic/033

index a9a9ff5a3431bc3442e4163bd25ddb2684859607..b7df56b826190c523229f03d43aead2ac0603b55 100755 (executable)
@@ -37,12 +37,12 @@ $XFS_IO_PROG -f -c "pwrite 0 $bytes" $file >> $seqres.full 2>&1
 # delalloc blocks and convert the ranges to unwritten.
 endoff=$((bytes - 4096))
 for i in $(seq 0 8192 $endoff); do
-       $XFS_IO_PROG -c "fzero -k $i 4k" $file >> $seqres.full 2>&1
+       $XFS_IO_PROG -c "fzero $i 4k" $file >> $seqres.full 2>&1
 done
 
 # now zero the opposite set to remove remaining delalloc extents
 for i in $(seq 4096 8192 $endoff); do
-       $XFS_IO_PROG -c "fzero -k $i 4k" $file >> $seqres.full 2>&1
+       $XFS_IO_PROG -c "fzero $i 4k" $file >> $seqres.full 2>&1
 done
 
 _scratch_cycle_mount