2 # SPDX-License-Identifier: GPL-2.0
3 # Copyright (c) 2006 Silicon Graphics, Inc. All Rights Reserved.
7 # Concurrent I/O to same file to ensure no deadlocks
10 seqres=$RESULT_DIR/$seq
11 echo "QA output created by $seq"
15 status=1 # failure is the default!
16 trap "exit \$status" 0 1 2 3 15
18 # get standard environment, filters and checks
22 # real QA test starts here
28 echo "Buffered writer, buffered reader"
29 $XFS_IO_PROG -f -d -c 'pwrite -b 64k 0 512m' $TEST_DIR/io_test > /dev/null
30 $XFS_IO_PROG -f -c 'pwrite -b 64k 0 512m' $TEST_DIR/io_test >/dev/null &
31 $XFS_IO_PROG -c 'pread -b 64k 0 512m' $TEST_DIR/io_test > /dev/null
35 echo "Direct writer, buffered reader"
36 $XFS_IO_PROG -f -d -c 'pwrite -b 64k 0 512m' $TEST_DIR/io_test > /dev/null
37 $XFS_IO_PROG -f -d -c 'pwrite -b 64k 0 512m' $TEST_DIR/io_test >/dev/null &
38 $XFS_IO_PROG -c 'pread -b 64k 0 512m' $TEST_DIR/io_test > /dev/null
42 echo "Buffered writer, direct reader"
43 $XFS_IO_PROG -f -d -c 'pwrite -b 64k 0 512m' $TEST_DIR/io_test > /dev/null
44 $XFS_IO_PROG -f -c 'pwrite -b 64k 0 512m' $TEST_DIR/io_test >/dev/null &
45 $XFS_IO_PROG -d -c 'pread -b 64k 0 512m' $TEST_DIR/io_test > /dev/null
49 echo "Direct writer, direct reader"
50 $XFS_IO_PROG -f -d -c 'pwrite -b 64k 0 512m' $TEST_DIR/io_test > /dev/null
51 $XFS_IO_PROG -f -d -c 'pwrite -b 64k 0 512m' $TEST_DIR/io_test >/dev/null &
52 $XFS_IO_PROG -d -c 'pread -b 64k 0 512m' $TEST_DIR/io_test > /dev/null