Lines Matching refs:pp

123 	struct refclockproc *pp;  in pst_start()  local
139 pp = peer->procptr; in pst_start()
140 pp->io.clock_recv = pst_receive; in pst_start()
141 pp->io.srcclock = peer; in pst_start()
142 pp->io.datalen = 0; in pst_start()
143 pp->io.fd = fd; in pst_start()
144 if (!io_addclock(&pp->io)) { in pst_start()
146 pp->io.fd = -1; in pst_start()
150 pp->unitptr = up; in pst_start()
156 pp->clockdesc = DESCRIPTION; in pst_start()
157 memcpy((char *)&pp->refid, WWVREFID, 4); in pst_start()
172 struct refclockproc *pp; in pst_shutdown() local
174 pp = peer->procptr; in pst_shutdown()
175 up = pp->unitptr; in pst_shutdown()
176 if (-1 != pp->io.fd) in pst_shutdown()
177 io_closeclock(&pp->io); in pst_shutdown()
192 struct refclockproc *pp; in pst_receive() local
205 pp = peer->procptr; in pst_receive()
206 up = pp->unitptr; in pst_receive()
207 up->lastptr += refclock_gtlin(rbufp, up->lastptr, pp->a_lastcode in pst_receive()
217 pp->lastrec = trtmp; in pst_receive()
219 pp->lencode = up->lastptr - pp->a_lastcode; in pst_receive()
228 if (pp->lencode < LENPST) { in pst_receive()
237 if (sscanf(pp->a_lastcode, in pst_receive()
239 &ampmchar, &pp->hour, &pp->minute, &pp->second, &pp->nsec, in pst_receive()
240 &daychar, junque, &pp->day, info, &ltemp) != 10) { in pst_receive()
244 pp->nsec *= 1000000; in pst_receive()
254 pp->leap = LEAP_NOTINSYNC; in pst_receive()
256 memcpy((char *)&pp->refid, WWVHREFID, 4); in pst_receive()
258 memcpy((char *)&pp->refid, WWVREFID, 4); in pst_receive()
260 peer->refid = pp->refid; in pst_receive()
262 pp->lastref = pp->lastrec; in pst_receive()
263 pp->disp = PST_PHI * ltemp * 60; in pst_receive()
269 if (!refclock_process(pp)) in pst_receive()
286 struct refclockproc *pp; in pst_poll() local
296 pp = peer->procptr; in pst_poll()
297 up = pp->unitptr; in pst_poll()
299 up->lastptr = pp->a_lastcode; in pst_poll()
300 if (write(pp->io.fd, "QTQDQMT", 6) != 6) in pst_poll()
302 if (pp->coderecv == pp->codeproc) { in pst_poll()
307 record_clock_stats(&peer->srcadr, pp->a_lastcode); in pst_poll()
310 printf("pst: timecode %d %s\n", pp->lencode, in pst_poll()
311 pp->a_lastcode); in pst_poll()
313 pp->polls++; in pst_poll()