Lines Matching refs:slp
108 static struct slave *slp; variable
150 slp = &slaves[0]; in alloctape()
151 slp->count = 1; in alloctape()
152 slp->tapea = 0; in alloctape()
153 slp->firstrec = 0; in alloctape()
154 nextblock = slp->tblock; in alloctape()
162 slp->req[trecno].dblk = 0; in writerec()
163 slp->req[trecno].count = 1; in writerec()
182 slp->req[trecno].dblk = dblkno; in dumpblock()
183 slp->req[trecno].count = avail; in dumpblock()
284 int siz = (char *)nextblock - (char *)slp->req; in flushtape()
286 slp->req[trecno].count = 0; /* Sentinel */ in flushtape()
288 if (atomic((ssize_t (*)(int, void *, size_t))write, slp->fd, in flushtape()
289 (char *)slp->req, siz) != siz) in flushtape()
291 slp->sent = 1; /* we sent a request, read the response later */ in flushtape()
293 lastfirstrec = slp->firstrec; in flushtape()
295 if (++slp >= &slaves[SLAVES]) in flushtape()
296 slp = &slaves[0]; in flushtape()
299 if (slp->sent) { in flushtape()
300 if (atomic(read, slp->fd, (char *)&got, sizeof(got)) in flushtape()
305 slp->sent = 0; in flushtape()
342 slp->count = lastspclrec + blks + 1 - spcl.c_tapea; in flushtape()
343 slp->tapea = spcl.c_tapea; in flushtape()
344 slp->firstrec = lastfirstrec + ntrec; in flushtape()
345 slp->inode = curino; in flushtape()
346 nextblock = slp->tblock; in flushtape()
465 otb = (union u_spcl *)slp->tblock; in rollforward()
472 for (p = slp->req; p->count > 0; p += p->count) { in rollforward()
494 spcl.c_tapea = slp->tapea; in rollforward()
501 slp->fd, (char *)q, size) != size) { in rollforward()
505 slp->sent = 1; in rollforward()
506 if (++slp >= &slaves[SLAVES]) in rollforward()
507 slp = &slaves[0]; in rollforward()
530 slp->req[0] = *q; in rollforward()
531 nextblock = slp->tblock; in rollforward()
540 if (slp->sent) { in rollforward()
541 if (atomic(read, slp->fd, (char *)&got, sizeof(got)) in rollforward()
546 slp->sent = 0; in rollforward()
680 spcl.c_count = slp->count; in startnewtape()
685 spcl.c_firstrec = slp->firstrec; in startnewtape()
690 writeheader((ino_t)slp->inode); in startnewtape()
697 tapeno, (unsigned long long)slp->inode); in startnewtape()
751 if (i == slp - &slaves[0]) { in enslave()
824 while ((nread = atomic(read, cmd, (char *)slp->req, reqsiz)) == reqsiz) { in doslave()
825 struct req *p = slp->req; in doslave()
830 bread(p->dblk, slp->tblock[trecno], in doslave()
834 (char *)slp->tblock[trecno], in doslave()
855 wrote = rmtwrite(slp->tblock[0]+size, in doslave()
859 wrote = write(tapefd, slp->tblock[0]+size, in doslave()