Re: [PATCH 3/3] xfstests: Move *_dump_log routines to common/xfs

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 





On 9/9/21 10:41 AM, Catherine Hoang wrote:
Move _scratch_remount_dump_log and _test_remount_dump_log from
common/inject to common/xfs. These routines do not inject errors and
should be placed with other xfs common functions.

Signed-off-by: Catherine Hoang <catherine.hoang@xxxxxxxxxx>

Looks ok
Reviewed-by: Allison Henderson <allison.henderson@xxxxxxxxxx>

---
  common/inject | 26 --------------------------
  common/xfs    | 26 ++++++++++++++++++++++++++
  2 files changed, 26 insertions(+), 26 deletions(-)

diff --git a/common/inject b/common/inject
index b5334d4a..6b590804 100644
--- a/common/inject
+++ b/common/inject
@@ -111,29 +111,3 @@ _scratch_inject_error()
  		_fail "Cannot inject error ${type} value ${value}."
  	fi
  }
-
-# Unmount and remount the scratch device, dumping the log
-_scratch_remount_dump_log()
-{
-	local opts="$1"
-
-	if test -n "$opts"; then
-		opts="-o $opts"
-	fi
-	_scratch_unmount
-	_scratch_dump_log
-	_scratch_mount "$opts"
-}
-
-# Unmount and remount the test device, dumping the log
-_test_remount_dump_log()
-{
-	local opts="$1"
-
-	if test -n "$opts"; then
-		opts="-o $opts"
-	fi
-	_test_unmount
-	_test_dump_log
-	_test_mount "$opts"
-}
diff --git a/common/xfs b/common/xfs
index bfb1bf1e..cda1f768 100644
--- a/common/xfs
+++ b/common/xfs
@@ -1263,3 +1263,29 @@ _require_scratch_xfs_bigtime()
  		_notrun "bigtime feature not advertised on mount?"
  	_scratch_unmount
  }
+
+# Unmount and remount the scratch device, dumping the log
+_scratch_remount_dump_log()
+{
+	local opts="$1"
+
+	if test -n "$opts"; then
+		opts="-o $opts"
+	fi
+	_scratch_unmount
+	_scratch_dump_log
+	_scratch_mount "$opts"
+}
+
+# Unmount and remount the test device, dumping the log
+_test_remount_dump_log()
+{
+	local opts="$1"
+
+	if test -n "$opts"; then
+		opts="-o $opts"
+	fi
+	_test_unmount
+	_test_dump_log
+	_test_mount "$opts"
+}




[Index of Archives]     [XFS Filesystem Development (older mail)]     [Linux Filesystem Development]     [Linux Audio Users]     [Yosemite Trails]     [Linux Kernel]     [Linux RAID]     [Linux SCSI]


  Powered by Linux