From: Christoph Hellwig <hch@lst.de>
Date: Thu, 31 Oct 2024 17:58:23 +0000 (+0100)
Subject: xfs: handle internal rtdev in the _require_ helpers
X-Git-Tag: xfs-zoned-2024-11-18
X-Git-Url: https://www.infradead.org/git/?a=commitdiff_plain;h=a624f3c2bc538fbf3564c20652cad67598f37e57;p=users%2Fhch%2Fxfstests-dev.git

xfs: handle internal rtdev in the _require_ helpers

.. and add it to a few more tests where it matters for the main device.

Signed-off-by: Christoph Hellwig <hch@lst.de>
---

diff --git a/common/xfs b/common/xfs
index 49c5af8e5..8606c6035 100644
--- a/common/xfs
+++ b/common/xfs
@@ -2067,6 +2067,7 @@ _scratch_xfs_force_no_metadir()
 # do not run on zoned file systems
 _require_scratch_non_zoned()
 {
+	_require_non_zoned_device $SCRATCH_DEV
 	if [ "$USE_EXTERNAL" = yes -a ! -z "$SCRATCH_RTDEV" ]; then
 		_require_non_zoned_device $SCRATCH_RTDEV
 
diff --git a/tests/xfs/311 b/tests/xfs/311
index 8b806fc29..e8fc547cc 100755
--- a/tests/xfs/311
+++ b/tests/xfs/311
@@ -30,6 +30,9 @@ _cleanup()
 _require_scratch
 _require_dm_target delay
 
+# The dm-delay map added by this test doesn't work on zoned devices
+_require_non_zoned_device $SCRATCH_DEV
+
 echo "Silence is golden."
 
 _scratch_mkfs_xfs >> $seqres.full 2>&1
diff --git a/tests/xfs/438 b/tests/xfs/438
index 0239778c5..fa74b1403 100755
--- a/tests/xfs/438
+++ b/tests/xfs/438
@@ -96,6 +96,13 @@ _require_user
 _require_xfs_quota
 _require_freeze
 
+#
+# The dm-flakey map added by this test doesn't work on zoned devices
+# because table sizes need to be aligned to the zone size.
+#
+_require_non_zoned_device $SCRATCH_DEV
+_require_non_zoned_device $SCRATCH_RTDEV
+
 echo "Silence is golden"
 
 _scratch_mkfs > $seqres.full 2>&1
diff --git a/tests/xfs/449 b/tests/xfs/449
index a739df50e..86ded1960 100755
--- a/tests/xfs/449
+++ b/tests/xfs/449
@@ -12,9 +12,11 @@ _begin_fstest auto quick
 # Import common functions.
 . ./common/filter
 
-
 _require_scratch_nocheck
 
+# can't grow data volume on mixed configs
+_require_scratch_non_zoned
+
 # Geometry printing wasn't unified until xfs_spaceman grew an 'info'
 # command, so skip this test if there is no spaceman or it doesn't
 # know what 'info' is.
diff --git a/tests/xfs/524 b/tests/xfs/524
index ef47a8461..a311e2e8a 100755
--- a/tests/xfs/524
+++ b/tests/xfs/524
@@ -25,6 +25,9 @@ _require_test
 _require_scratch_nocheck
 _require_xfs_mkfs_cfgfile
 
+# reflink currently not supported for zoned devices
+_require_non_zoned_device $SCRATCH_DEV
+
 echo "Silence is golden"
 
 def_cfgfile=$TEST_DIR/a
diff --git a/tests/xfs/556 b/tests/xfs/556
index 17100ea19..0dfcbc5b7 100755
--- a/tests/xfs/556
+++ b/tests/xfs/556
@@ -32,6 +32,7 @@ _require_dm_target error
 # The dm-error map added by this test doesn't work on zoned devices
 # because table sizes need to be aligned to the zone size.
 #
+_require_non_zoned_device $SCRATCH_DEV
 _require_non_zoned_device $SCRATCH_RTDEV
 
 filter_scrub_errors() {