@@ -201,6 +201,9 @@ _xfs_get_file_block_size()
# For each directory, each file subsequently created will target the given
# device for file data allocations. For each empty regular file, each
# subsequent file data allocation will be on the given device.
+#
+# NOTE: If you call this on $TEST_DIR, you must reset the rtinherit flag state
+# before the end of the test to avoid polluting subsequent tests.
_xfs_force_bdev()
{
local device="$1"
@@ -31,11 +31,16 @@ _require_fs_space $TEST_DIR 3200000
TDIR="${TEST_DIR}/t_holes"
NFILES="10"
EXTSIZE="256k"
-_xfs_force_bdev data $TEST_DIR
# Create the test directory
mkdir ${TDIR}
+# Per-directory extent size hints aren't particularly useful for files that
+# are created on the realtime section. Force the test file to be created on
+# the data directory. Do not change the rtinherit flag on $TEST_DIR because
+# that will affect other tests.
+_xfs_force_bdev data $TDIR
+
# Set the test directory extsize
$XFS_IO_PROG -c "extsize ${EXTSIZE}" ${TDIR}