Lines Matching defs:ppp_fd
174 static int ppp_fd = -1; /* fd which is set to PPP discipline */
183 * For the old-style kernel driver, this is the same as ppp_fd.
263 ppp_fd = new_fd;
271 return !hungup && ppp_fd >= 0;
272 if (!hungup || ppp_fd == slave_fd)
435 modify_flags(ppp_fd, SC_RCVB | SC_LOGB,
532 return ppp_fd;
591 close(ppp_fd);
592 ppp_fd = -1;
660 if (ioctl(ppp_fd, PPPIOCCONNECT, &ifunit) < 0)
706 if (ioctl(ppp_fd, PPPIOCCONNECT, &ifnum) < 0)
738 if (ioctl(ppp_fd, PPPIOCGFLAGS, (caddr_t) &x) == 0) {
1013 int fd = ppp_fd;
1093 if (ppp_fd >= 0) {
1094 nr = read(ppp_fd, buf, len);
1102 /* N.B. we read ppp_fd first since LCP packets come in there. */
1114 if (new_style_driver && ppp_fd < 0 && ppp_dev_fd < 0)
1198 if (ioctl(ppp_fd, PPPIOCSASYNCMAP, (caddr_t) &asyncmap) < 0) {
1207 modify_flags(ppp_fd, SC_COMP_PROT|SC_COMP_AC|SC_SYNC, x);
1219 if (ioctl(ppp_fd, PPPIOCSXASYNCMAP, accm) < 0 && errno != ENOTTY) {
1242 if (ioctl(ppp_fd, PPPIOCSMRU, (caddr_t) &mru) < 0) {
1250 if (ioctl(ppp_fd, PPPIOCSRASYNCMAP, (caddr_t) &asyncmap) < 0) {
2642 ppp_fd = -1;
2656 flags = fcntl(ppp_fd, F_GETFL);
2658 fcntl(ppp_fd, F_SETFL, flags | O_NONBLOCK) == -1)
2661 if (ioctl(ppp_fd, TIOCSETD, &ppp_disc) < 0)
2666 if (ioctl(ppp_fd, PPPIOCGUNIT, &ifunit) < 0)