xfs: force file creation to the data device for certain layout tests
[xfstests-dev.git] / tests / xfs / 290
1 #! /bin/bash
2 # SPDX-License-Identifier: GPL-2.0
3 # Copyright (c) 2012 SGI.  All Rights Reserved.
4 #
5 # FS QA Test No. 290
6 #
7 # Makes calls to XFS_IOC_ZERO_RANGE and checks tossed ranges
8 #
9 # Nothing should be tossed unless the range includes a page boundry
10 #
11 # Primarily tests page boundries and boundries that are
12 #  off-by-one to ensure we're only tossing what's expected
13 #
14 seq=`basename $0`
15 seqres=$RESULT_DIR/$seq
16 echo "QA output created by $seq"
17
18 here=`pwd`
19 tmp=/tmp/$$
20 status=1        # failure is the default!
21 trap "exit \$status" 0 1 2 3 15
22
23 # get standard environment, filters and checks
24 . ./common/rc
25 . ./common/filter
26 . ./common/punch
27
28 # real QA test starts here
29
30 # Modify as appropriate.
31 _supported_fs xfs
32
33 _require_test
34 _require_xfs_io_command "zero"
35
36 testfile=$TEST_DIR/290.$$
37
38 _test_block_boundaries 4096 zero _filter_xfs_io_unique $testfile
39
40 # success, all done
41 status=0
42 exit