]> www.infradead.org Git - users/hch/xfstests-dev.git/commitdiff
common: support internal RT device in _require_realtime
authorChristoph Hellwig <hch@lst.de>
Sat, 23 Nov 2024 06:54:15 +0000 (07:54 +0100)
committerChristoph Hellwig <hch@lst.de>
Thu, 30 Jan 2025 05:01:11 +0000 (06:01 +0100)
If SCRATCH_DEV is a zoned device it implies an internal zoned RT device
and should not be skipped in _require_realtime.

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

index eb672db9fccdce87ed112e088ad0767099b43013..69ba7bc33bd47201b75a8fe5bf2e2312c8944fe0 100644 (file)
--- a/common/rc
+++ b/common/rc
@@ -2363,10 +2363,15 @@ _require_no_large_scratch_dev()
 #
 _require_realtime()
 {
-    [ "$USE_EXTERNAL" = yes ] || \
-       _notrun "External volumes not in use, skipped this test"
-    [ "$SCRATCH_RTDEV" = "" ] && \
-       _notrun "Realtime device required, skipped this test"
+       local zone_type=`_zone_type $SCRATCH_DEV`
+       if [ "${zone_type}" = "none" ]; then
+               if [ "$USE_EXTERNAL" != "yes" ]; then
+                       _notrun "External volumes not in use, skipped this test"
+               fi
+               if [ "$SCRATCH_RTDEV" = "" ]; then
+                       _notrun "Realtime device required, skipped this test"
+               fi
+       fi
 }
 
 # This test requires that a realtime subvolume is not in use