2 # SPDX-License-Identifier: GPL-2.0
3 # Copyright (c) 2010 Red Hat. All Rights Reserved.
7 # Test Generic fallocate hole punching
10 seqres=$RESULT_DIR/$seq
11 echo "QA output created by $seq"
15 status=1 # failure is the default!
22 trap "_cleanup ; exit \$status" 0 1 2 3 15
24 # get standard environment, filters and checks
29 # real QA test starts here
33 _require_xfs_io_command "fpunch"
34 _require_xfs_io_command "falloc"
35 _require_xfs_io_command "fiemap"
37 testfile=$TEST_DIR/255.$$
39 # Standard punch hole tests
40 _test_generic_punch falloc fpunch fpunch fiemap _filter_hole_fiemap $testfile
42 # Delayed allocation punch hole tests
43 _test_generic_punch -d falloc fpunch fpunch fiemap _filter_hole_fiemap $testfile
45 # Multi hole punch tests
46 _test_generic_punch -k falloc fpunch fpunch fiemap _filter_hole_fiemap $testfile
48 # Delayed allocation multi punch hole tests
49 _test_generic_punch -d -k falloc fpunch fpunch fiemap _filter_hole_fiemap $testfile