shared,ext4: move ext[234]-specific tests out of shared/
[xfstests-dev.git] / tests / shared / 006
index 55c596593d39b6716ab4cc7ee0138f578c440e6a..aa65e9a29e7b2d282013eb6406777853b20c3892 100755 (executable)
@@ -1,4 +1,7 @@
 #! /bin/bash
+# SPDX-License-Identifier: GPL-2.0
+# Copyright (c) 2014 Red Hat Inc.  All Rights Reserved.
+#
 # FS QA Test No. shared/006
 #
 # Stress test fs by using up all inodes and check fs.
@@ -6,24 +9,6 @@
 # Also a regression test for xfsprogs commit
 # d586858 xfs_repair: fix sibling pointer tests in verify_dir2_path()
 #
-#-----------------------------------------------------------------------
-# Copyright (c) 2014 Red Hat Inc.  All Rights Reserved.
-#
-# This program is free software; you can redistribute it and/or
-# modify it under the terms of the GNU General Public License as
-# published by the Free Software Foundation.
-#
-# This program is distributed in the hope that it would be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with this program; if not, write the Free Software Foundation,
-# Inc.,  51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
-#-----------------------------------------------------------------------
-#
-
 seq=`basename $0`
 seqres=$RESULT_DIR/$seq
 echo "QA output created by $seq"
@@ -69,7 +54,7 @@ _scratch_mkfs_sized $((1024 * 1024 * 1024)) >>$seqres.full 2>&1
 _scratch_mount
 
 i=0
-free_inode=`$DF_PROG -i $SCRATCH_MNT | tail -1 | awk '{print $3}'`
+free_inode=`_get_free_inode $SCRATCH_MNT`
 file_per_dir=1000
 loop=$((free_inode / file_per_dir + 1))
 mkdir -p $SCRATCH_MNT/testdir