On Thu, Dec 08, 2016 at 10:04:56AM +0800, Qu Wenruo wrote: > Introduce new _require_btrfs_qgroup_report function, which will check > the accessibility to "btrfs check --qgroup-report", then set a global > flag to info _check_scratch_fs() to do extra qgroup check. > > Signed-off-by: Qu Wenruo <quwenruo@xxxxxxxxxxxxxx> > --- > common/rc | 22 ++++++++++++++++++++++ This needs rebase too. > tests/btrfs/022 | 5 +++++ > tests/btrfs/028 | 5 ++--- > tests/btrfs/042 | 6 ++---- > tests/btrfs/099 | 1 + > tests/btrfs/104 | 20 +++++--------------- > tests/btrfs/122 | 10 +++------- > tests/btrfs/123 | 5 ++--- > 8 files changed, 42 insertions(+), 32 deletions(-) > > diff --git a/common/rc b/common/rc > index 1703232..bce3a09 100644 > --- a/common/rc > +++ b/common/rc > @@ -2624,6 +2624,20 @@ _check_btrfs_filesystem() > mountpoint=`_umount_or_remount_ro $device` > fi > > + # Check qgroup numbers > + if [ "$BTRFS_NEED_QGROUP_REPORT" == "yes" ];then So we can bypass the _require_btrfs_qgroup_report check if we set BTRFS_NEED_QGROUP_REPORT to "yes" directly, right? How about doing something like _require_scratch do, e.g. touching some signal file in $RESULT_DIR and only do qgroup check if that file exists? > + btrfsck $device --qgroup-report > $tmp.qgroup_report 2>&1 Shouldn't "$BTRFS_UTIL_PROG check $device ..." be used for new code? I might be wrong on this, I think btrfsck is deprecated. Thanks, Eryu -- 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