diff mbox series

[6/9] xfs/27[26]: force realtime on or off as needed

Message ID 160382532889.1202316.11271089772377137054.stgit@magnolia
State Accepted
Headers show
Series xfstests: random fixes | expand

Commit Message

Darrick J. Wong Oct. 27, 2020, 7:02 p.m. UTC
From: Darrick J. Wong <darrick.wong@oracle.com>

Certain tests have certain requirements where the realtime parameters
are concerned.  Fix them all.

Signed-off-by: Darrick J. Wong <darrick.wong@oracle.com>
---
 tests/xfs/272 |    3 +++
 tests/xfs/276 |    8 +++++++-
 2 files changed, 10 insertions(+), 1 deletion(-)

Comments

Christoph Hellwig Oct. 28, 2020, 7:43 a.m. UTC | #1
On Tue, Oct 27, 2020 at 12:02:08PM -0700, Darrick J. Wong wrote:
> From: Darrick J. Wong <darrick.wong@oracle.com>
> 
> Certain tests have certain requirements where the realtime parameters
> are concerned.  Fix them all.

Certain tests sound like a lot for exactly two flags :)

Otherwise looks good:

Reviewed-by: Christoph Hellwig <hch@lst.de>
diff mbox series

Patch

diff --git a/tests/xfs/272 b/tests/xfs/272
index a9baf2e7..6c0fede5 100755
--- a/tests/xfs/272
+++ b/tests/xfs/272
@@ -37,6 +37,9 @@  echo "Format and mount"
 _scratch_mkfs > "$seqres.full" 2>&1
 _scratch_mount
 
+# Make sure everything is on the data device
+$XFS_IO_PROG -c 'chattr -t' $SCRATCH_MNT
+
 _pwrite_byte 0x80 0 737373 $SCRATCH_MNT/urk >> $seqres.full
 sync
 $here/src/punch-alternating $SCRATCH_MNT/urk >> $seqres.full
diff --git a/tests/xfs/276 b/tests/xfs/276
index 8b7e1de5..6e2b2fb4 100755
--- a/tests/xfs/276
+++ b/tests/xfs/276
@@ -35,9 +35,15 @@  _require_test_program "punch-alternating"
 rm -f "$seqres.full"
 
 echo "Format and mount"
-_scratch_mkfs > "$seqres.full" 2>&1
+_scratch_mkfs | _filter_mkfs 2> "$tmp.mkfs"
+. $tmp.mkfs
+cat "$tmp.mkfs" > $seqres.full
 _scratch_mount
 
+# Don't let the rt extent size perturb the fsmap output with unwritten
+# extents in places we don't expect them
+test $rtextsz -eq $dbsize || _notrun "Skipping test due to rtextsize > 1 fsb"
+
 $XFS_IO_PROG -f -R -c 'pwrite -S 0x80 0 737373' $SCRATCH_MNT/urk >> $seqres.full
 sync
 $here/src/punch-alternating $SCRATCH_MNT/urk >> $seqres.full