Lines Matching +full:on +full:- +full:the +full:- +full:go
4 # SPDX-License-Identifier: BSD-2-Clause
9 # modification, are permitted provided that the following conditions
11 # 1. Redistributions of source code must retain the above copyright
12 # notice, this list of conditions and the following disclaimer.
13 # 2. Redistributions in binary form must reproduce the above copyright
14 # notice, this list of conditions and the following disclaimer in the
15 # documentation and/or other materials provided with the distribution.
17 # THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
18 # ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
20 # ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
24 # HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
26 # OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
33 [ `id -u ` -ne 0 ] && echo "Must be root!" && exit 1
35 set -u
38 grep -q $mntpoint /etc/exports ||
55 static int fd, go;
64 while (go == 1) {
79 while (go == 1) {
98 while (go == 1) {
100 pos = arc4random() % (siz - s);
102 if (lseek(fd, pos, SEEK_SET) == -1)
108 if (lseek(fd, pos, SEEK_SET) == -1)
122 while (go == 1) {
123 if (fdatasync(fd) == -1)
134 while (go == 1) {
135 if (fsync(fd) == -1)
149 while (go == 1) {
151 if (lseek(fd, arc4random() % siz, SEEK_END) == -1)
158 if (ftruncate(fd, siz) == -1)
177 if ((fd = open(argv[1], O_RDWR)) == -1)
179 if (fstat(fd, &st) == -1)
186 go = 1;
202 go = 0;
205 if (munmap(cp, siz) == -1)
210 mycc -o /tmp/$prog -Wall -Wextra -O0 /tmp/$prog.c -lpthread || exit 1
212 mycc -o /tmp/serial -Wall -Wextra -O2 ../tools/serial.c || exit 1
213 mount | grep -q "on $mntpoint " && umount -f $mntpoint
214 mdconfig -l | grep -q md$mdstart && mdconfig -d -u $mdstart
215 mdconfig -s 5g -u $mdstart
216 newfs -n $newfs_flags /dev/md$mdstart > /dev/null
220 mkdir -p $mp2
221 mount | grep -q "on $mp2 " && umount -f $mp2
222 mount -t nfs -o retrycnt=3 127.0.0.1:$mntpoint $mp2 || exit 1
228 $here/../testcases/swap/swap -t 5m -i 20 > /dev/null &
238 while pgrep -q swap; do pkill swap; done
240 if ! cmp -s file.orig file; then
241 od -t x1 file.orig > /var/tmp/$prog.file1
242 od -t x1 file > /var/tmp/$prog.file2
244 head -20 $log
246 ls -ls file.orig file
253 mdconfig -d -u $mdstart
254 rm -f /tmp/serial /tmp/$prog /tmp/$prog.c $log