From 314b22120156a664ba660a550625193f88cc9cc2 Mon Sep 17 00:00:00 2001 From: David Sterba Date: Tue, 16 Aug 2011 18:50:23 +0200 Subject: [PATCH] xfstests: setup and run non-generic mkfs for btrfs Signed-off-by: David Sterba Signed-off-by: Christoph Hellwig --- common | 3 +++ common.config | 1 + common.rc | 5 ++++- 3 files changed, 8 insertions(+), 1 deletion(-) diff --git a/common b/common index 817c0039..07232245 100644 --- a/common +++ b/common @@ -306,6 +306,9 @@ case "$FSTYP" in udf) [ "$MKFS_UDF_PROG" = "" ] && _fatal "mkfs_udf/mkudffs not found" ;; + btrfs) + [ "$MKFS_BTRFS_PROG" = "" ] && _fatal "mkfs.btrfs not found" + ;; nfs) ;; esac diff --git a/common.config b/common.config index 36421391..e94624ee 100644 --- a/common.config +++ b/common.config @@ -184,6 +184,7 @@ case "$HOSTOS" in Linux) export MKFS_XFS_PROG="`set_prog_path mkfs.xfs`" export MKFS_UDF_PROG="`set_prog_path mkudffs`" + export MKFS_BTRFS_PROG="`set_prog_path mkfs.btrfs`" export XFS_FSR_PROG="`set_prog_path xfs_fsr`" export MKFS_NFS_PROG="false" ;; diff --git a/common.rc b/common.rc index 2cbcb73a..35f782b3 100644 --- a/common.rc +++ b/common.rc @@ -310,6 +310,9 @@ _scratch_mkfs() udf) $MKFS_UDF_PROG $MKFS_OPTIONS $* $SCRATCH_DEV > /dev/null ;; + btrfs) + $MKFS_BTRFS_PROG $MKFS_OPTIONS $* $SCRATCH_DEV > /dev/null + ;; *) /sbin/mkfs -t $FSTYP -- $MKFS_OPTIONS $* $SCRATCH_DEV ;; @@ -333,7 +336,7 @@ _scratch_mkfs_sized() /sbin/mkfs.$FSTYP $MKFS_OPTIONS -b $blocksize $SCRATCH_DEV $blocks ;; btrfs) - /sbin/mkfs.$FSTYP $MKFS_OPTIONS $SCRATCH_DEV -b $fssize + $MKFS_BTRFS_PROG $MKFS_OPTIONS -b $fssize $SCRATCH_DEV ;; *) _notrun "Filesystem $FSTYP not supported in _scratch_mkfs_sized" -- 2.39.5