4 # Hole punching with extsize hints, holes may not reported by xfs_bmap.
5 # This is not good for certain backup apps, as they rely on the hole
6 # being visible in the file so later on they know where to migrate
7 # back the data from the tape.
9 #-----------------------------------------------------------------------
10 # Copyright (c) 2007 Silicon Graphics, Inc. All Rights Reserved.
11 #-----------------------------------------------------------------------
16 echo "QA output created by $seq"
21 status=1 # failure is the default!
22 trap "_cleanup; exit \$status" 0 1 2 3 15
29 # get standard environment, filters and checks
34 # real QA test starts here
40 # _test_punch args: blksize extsize_hint filesize "pp1 pp2 pp3" \
41 # "ps1 ps2 ps3" "pt1 pt2 pt3" "wp1 wp2" "ws1 ws2" \
44 echo "-- test dmpunch-hole without an extent size hint --"
45 _test_punch 4096 0 256 "240" "16" "d" "0" "256" "w p" noresv
48 echo "-- this time use a 4k (one block) extent size hint --"
49 _test_punch 4096 1 256 "240" "16" "d" "0" "256" "w p" noresv