[PATCH] common: support defrag test on f2fs

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



f2fs-tools has a defragment tool, so we can test generic/324 on f2fs

Signed-off-by: Chen Rong <rongx.a.chen@xxxxxxxxx>
---
 common/config | 1 +
 common/defrag | 3 +++
 2 files changed, 4 insertions(+)

diff --git a/common/config b/common/config
index d0fbfe5..71cb367 100644
--- a/common/config
+++ b/common/config
@@ -226,6 +226,7 @@ case "$HOSTOS" in
         export MKFS_BTRFS_PROG="`set_btrfs_mkfs_prog_path_with_opts`"
         export MKFS_F2FS_PROG="`set_prog_path mkfs.f2fs`"
         export DUMP_F2FS_PROG="`set_prog_path dump.f2fs`"
+        export DEFRAG_F2FS_PROG="`set_prog_path defrag.f2fs`"
         export BTRFS_UTIL_PROG="`set_prog_path btrfs`"
         export BTRFS_SHOW_SUPER_PROG="`set_prog_path btrfs-show-super`"
 	export BTRFS_CONVERT_PROG="`set_prog_path btrfs-convert`"
diff --git a/common/defrag b/common/defrag
index d279382..d54b89c 100644
--- a/common/defrag
+++ b/common/defrag
@@ -44,6 +44,9 @@ _require_defrag()
     btrfs)
 	DEFRAG_PROG="$BTRFS_UTIL_PROG filesystem defragment"
 	;;
+    f2fs)
+	DEFRAG_PROG="$DEFRAG_F2FS_PROG"
+	;;
     *)
         _notrun "defragmentation not supported for fstype \"$FSTYP\""
 	;;
-- 
2.7.4

--
To unsubscribe from this list: send the line "unsubscribe fstests" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux Filesystems Development]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux