Home | History | Annotate | Download | only in src

Lines Matching refs:link

80 #include "link.h"
184 p->link.type = PHYSICAL_LINK;
185 p->link.name = dl->name;
186 p->link.len = sizeof *p;
189 throughput_init(&p->link.stats.total, SAMPLE_PERIOD);
190 p->link.stats.parent = dl->bundle->ncp.mp.active ?
191 &dl->bundle->ncp.mp.link.stats.total : NULL;
192 p->link.stats.gather = 1;
194 memset(p->link.Queue, '\0', sizeof p->link.Queue);
195 memset(p->link.proto_in, '\0', sizeof p->link.proto_in);
196 memset(p->link.proto_out, '\0', sizeof p->link.proto_out);
197 link_EmptyStack(&p->link);
203 hdlc_Init(&p->hdlc, &p->link.lcp);
225 lcp_Init(&p->link.lcp, dl->bundle, &p->link, &dl->fsmp);
226 ccp_Init(&p->link.ccp, dl->bundle, &p->link, &dl->fsmp);
273 log_Printf(LogWARN, "%s: %s: Invalid parity\n", p->link.name, str);
311 log_Printf(LogPHASE, "%s: Disconnected!\n", p->link.name);
322 log_Printf(LogPHASE, "%s: %s is in use\n", p->link.name, p->name.full);
325 p->link.name, p->name.full, uu_lockerr(res));
337 log_Printf(LogALERT, "%s: Can't uu_unlock %s\n", p->link.name,
350 log_Printf(LogDEBUG, "%s: Close\n", p->link.name);
370 throughput_stop(&p->link.stats.total);
371 throughput_log(&p->link.stats.total, LogPHASE, p->link.name);
374 log_Printf(LogPHASE, "%s: HUPing %ld\n", p->link.name,
388 p->link.name, fn, strerror(errno));
405 throughput_destroy(&p->link.stats.total);
417 p->out = link_Dequeue(&p->link);
422 p->link.name, nw, (unsigned long)p->out->m_len, p->fd);
433 log_Printf(LogPHASE, "%s: write (fd %d, len %zd): %s\n", p->link.name,
452 prompt_Printf(arg->prompt, "Name: %s\n", p->link.name);
476 prompt_Printf(arg->prompt, "\n Link Type: %s\n", mode2Nam(p->type));
484 (u_long)link_QueueLen(&p->link));
536 throughput_disp(&p->link.stats.total, arg->prompt);
554 p->link.name, n, (int)(sizeof p->input.buf - p->input.sz), p->fd);
557 log_Printf(LogPHASE, "%s: read (%d): %s\n", p->link.name, p->fd,
561 p->link.name, p->fd);
569 if (p->link.lcp.fsm.state <= ST_CLOSED) {
580 p->link.name);
583 link_PullPacket(&p->link, rbuff, p->input.sz, bundle);
591 link_PullPacket(&p->link, rbuff, n, bundle);
603 p->link.name = dl->name;
604 memset(p->link.Queue, '\0', sizeof p->link.Queue);
618 p->link.lcp.fsm.bundle = dl->bundle;
619 p->link.lcp.fsm.link = &p->link;
620 memset(&p->linklink.lcp.fsm.FsmTimer);
621 memset(&p->link.lcp.fsm.OpenTimer, '\0', sizeof p->link.lcp.fsm.OpenTimer);
622 memset(&p->link.lcp.fsm.StoppedTimer, '\0',
623 sizeof p->link.lcp.fsm.StoppedTimer);
624 p->link.lcp.fsm.parent = &dl->fsmp;
625 lcp_SetupCallbacks(&p->link.lcp);
627 p->link.ccp.fsm.bundle = dl->bundle;
628 p->link.ccp.fsm.link = &p->link;
629 /* Our in.state & out.state are NULL (no link-level ccp yet) */
630 memset(&p->link.ccp.fsm.FsmTimer, '\0', sizeof p->link.ccp.fsm.FsmTimer);
631 memset(&p->link.ccp.fsm.OpenTimer, '\0', sizeof p->link.ccp.fsm.OpenTimer);
632 memset(&p->link.ccp.fsm.StoppedTimer, '\0',
633 sizeof p->link.ccp.fsm.StoppedTimer);
634 p->link.ccp.fsm.parent = &dl->fsmp;
635 ccp_SetupCallbacks(&p->link.ccp);
637 p->hdlc.lqm.owner = &p->link.lcp;
642 p->link.stats.total.in.SampleOctets = (long long *)iov[(*niov)++].iov_base;
643 p->link.stats.total.out.SampleOctets = (long long *)iov[(*niov)++].iov_base;
644 p->link.stats.parent = dl->bundle->ncp.mp.active ?
645 &dl->bundle->ncp.mp.link.stats.total : NULL;
646 p->link.stats.gather = 1;
654 log_Printf(LogPHASE, "%s: Unknown link type\n", p->link.name);
658 log_Printf(LogPHASE, "%s: Device %s, link type is %s\n",
659 p->link.name, p->name.full, p->handler->name);
662 lqr_reStart(&p->link.lcp);
665 throughput_restart(&p->link.stats.total, "physical throughput",
698 timer_Stop(&p->link.lcp.fsm.FsmTimer);
699 timer_Stop(&p->link.ccp.fsm.FsmTimer);
700 timer_Stop(&p->link.lcp.fsm.OpenTimer);
701 timer_Stop(&p->link.ccp.fsm.OpenTimer);
702 timer_Stop(&p->link.lcp.fsm.StoppedTimer);
703 timer_Stop(&p->link.ccp.fsm.StoppedTimer);
714 timer_Stop(&p->link.stats.total.Timer);
729 iov[*niov].iov_base = p ? (void *)p->link.stats.total.in.SampleOctets : NULL;
732 iov[*niov].iov_base = p ? (void *)p->link.stats.total.out.SampleOctets : NULL;
862 log_Printf(LogTIMER, "%s: fdset(r) %d\n", p->link.name, p->fd);
867 log_Printf(LogTIMER, "%s: fdset(e) %d\n", p->link.name, p->fd);
870 if (w && (force || link_QueueLen(&p->link) || p->out)) {
872 log_Printf(LogTIMER, "%s: fdset(w) %d\n", p->link.name, p->fd);
894 log_Printf(LogTIMER, "%s: fdunset(r) %d\n", p->link.name, p->fd);
899 log_Printf(LogTIMER, "%s: fdunset(e) %d\n", p->link.name, p->fd);
904 log_Printf(LogTIMER, "%s: fdunset(w) %d\n", p->link.name, p->fd);
955 log_Printf(LogWARN, "%s: Cannot change mode %s to %s\n", p->link.name,
970 link_DeleteQueue(&p->link);
1003 p->link.name, fn, strerror(errno));
1007 throughput_start(&p->link.stats.total, "physical throughput",
1012 log_Printf(LogPHASE, "%s: Connected!\n", p->link.name);
1023 log_Printf(LogDEBUG, "%s: Open: Modem is already open!\n", p->link.name);
1034 log_Printf(LogDEBUG, "%s: stdin is unidentified\n", p->link.name);
1060 log_Printf(LogWARN, "%s: %s: %s\n", p->link.name, p->name.full,
1064 " a '!' or contain at least one ':'\n", p->link.name,
1082 link_EmptyStack(&p->link);
1085 link_Stack(&p->link, &synclayer);
1087 link_Stack(&p->link, &asynclayer);
1088 link_Stack(&p->link, &hdlclayer);
1091 link_Stack(&p->link, &acflayer);
1092 link_Stack(&p->link, &protolayer);
1093 link_Stack(&p->link, &lqrlayer);
1094 link_Stack(&p->link, &ccplayer);
1095 link_Stack(&p->link, &vjlayer);
1096 link_Stack(&p->link, &tcpmsslayer);
1098 link_Stack(&p->link, &natlayer);