2 # SPDX-License-Identifier: GPL-2.0
3 # Copyright (c) 2014 Red Hat, Inc. All Rights Reserved.
5 # FS QA Test No. generic/031
7 # Test non-aligned writes against fcollapse to ensure that partial pages are
8 # correctly written and aren't left behind causing invalidation or data
12 seqres=$RESULT_DIR/$seq
13 echo "QA output created by $seq"
17 status=1 # failure is the default!
18 trap "_cleanup; exit \$status" 0 1 2 3 15
26 # get standard environment, filters and checks
30 # real QA test starts here
32 # Modify as appropriate.
35 _require_xfs_io_command "fcollapse"
37 testfile=$SCRATCH_MNT/testfile
39 _scratch_mkfs > /dev/null 2>&1
43 -c "pwrite 185332 55756" \
44 -c "fcollapse 28672 40960" \
45 -c "pwrite 133228 63394" \
46 -c "fcollapse 0 4096" \
47 $testfile | _filter_xfs_io
49 echo "==== Pre-Remount ==="
52 echo "==== Post-Remount =="