4 # Exercise IO on the realtime device (direct, buffered, mmapd)
6 #-----------------------------------------------------------------------
7 # Copyright (c) 2000-2004 Silicon Graphics, Inc. All Rights Reserved.
8 #-----------------------------------------------------------------------
14 echo "QA output created by $seq"
18 status=1 # failure is the default!
19 trap "rm -f $tmp.*; exit \$status" 0 1 2 3 15
21 # get standard environment, filters and checks
25 # real QA test starts here
39 if ! _scratch_mkfs_xfs >$tmp.out 2>&1
42 echo "failed to mkfs $SCRATCH_DEV"
49 echo "failed to mount $SCRATCH_DEV"
54 realtime_direct_aligned()
56 echo direct realtime writes, 4 files, 2m each, increasing offsets.
59 $XFS_IO_PROG -fdxR $SCRATCH_MNT/rt-direct-$1-$i \
60 -c "extsize $1" -c "pwrite ${i}m 1m" \
66 realtime_buffer_aligned()
68 echo buffered realtime writes, 4 files, 2m each, increasing offsets.
71 $XFS_IO_PROG -fxR $SCRATCH_MNT/rt-buffera-$1-$i \
72 -c "extsize $1" -c "pwrite ${i}m 1m" \
78 realtime_buffer_unaligned()
80 echo buffered realtime writes, 4 files, unaligned byte offsets/sizes.
83 $XFS_IO_PROG -fxR $SCRATCH_MNT/rt-bufferu-$1-$i \
84 -c "extsize $1" -c "pwrite $i 1" \
90 realtime_mmap_unaligned()
92 # mmap realtime writes, 4 files, unaligned byte offsets/sizes.
95 $XFS_IO_PROG -fxR $SCRATCH_MNT/rt-mmap-$1-$i \
96 -c "extsize $1" -c "pwrite $i 1" \
105 realtime_direct_aligned 0
106 #realtime_direct_aligned 1m
107 realtime_buffer_aligned 0
108 #realtime_buffer_aligned 1m
109 realtime_buffer_unaligned 0
110 #realtime_buffer_unaligned 1m
111 #realtime_mmap_unaligned 0
112 #realtime_mmap_unaligned 1m