Lines Matching refs:sppp

174 static MALLOC_DEFINE(M_SPPP, "sppp", "synchronous PPP interface internals");
208 u_char protoidx; /* index into state table in struct sppp */
216 void (*Up)(struct sppp *sp);
217 void (*Down)(struct sppp *sp);
218 void (*Open)(struct sppp *sp);
219 void (*Close)(struct sppp *sp);
221 int (*RCR)(struct sppp *sp, struct lcp_header *h, int len);
222 void (*RCN_rej)(struct sppp *sp, struct lcp_header *h, int len);
223 void (*RCN_nak)(struct sppp *sp, struct lcp_header *h, int len);
225 void (*tlu)(struct sppp *sp);
226 void (*tld)(struct sppp *sp);
227 void (*tls)(struct sppp *sp);
228 void (*tlf)(struct sppp *sp);
229 void (*scr)(struct sppp *sp);
264 static void sppp_cisco_send(struct sppp *sp, int type, long par1, long par2);
265 static void sppp_cisco_input(struct sppp *sp, struct mbuf *m);
267 static void sppp_cp_input(const struct cp *cp, struct sppp *sp,
269 static void sppp_cp_send(struct sppp *sp, u_short proto, u_char type,
272 static void sppp_cp_change_state(const struct cp *cp, struct sppp *sp,
275 struct sppp *sp, unsigned int type, unsigned int id,
278 static void sppp_up_event(const struct cp *cp, struct sppp *sp);
279 static void sppp_down_event(const struct cp *cp, struct sppp *sp);
280 static void sppp_open_event(const struct cp *cp, struct sppp *sp);
281 static void sppp_close_event(const struct cp *cp, struct sppp *sp);
282 static void sppp_to_event(const struct cp *cp, struct sppp *sp);
284 static void sppp_null(struct sppp *sp);
286 static void sppp_pp_up(struct sppp *sp);
287 static void sppp_pp_down(struct sppp *sp);
289 static void sppp_lcp_init(struct sppp *sp);
290 static void sppp_lcp_up(struct sppp *sp);
291 static void sppp_lcp_down(struct sppp *sp);
292 static void sppp_lcp_open(struct sppp *sp);
293 static void sppp_lcp_close(struct sppp *sp);
295 static int sppp_lcp_RCR(struct sppp *sp, struct lcp_header *h, int len);
296 static void sppp_lcp_RCN_rej(struct sppp *sp, struct lcp_header *h, int len);
297 static void sppp_lcp_RCN_nak(struct sppp *sp, struct lcp_header *h, int len);
298 static void sppp_lcp_tlu(struct sppp *sp);
299 static void sppp_lcp_tld(struct sppp *sp);
300 static void sppp_lcp_tls(struct sppp *sp);
301 static void sppp_lcp_tlf(struct sppp *sp);
302 static void sppp_lcp_scr(struct sppp *sp);
303 static void sppp_lcp_check_and_close(struct sppp *sp);
304 static int sppp_ncp_check(struct sppp *sp);
306 static void sppp_ipcp_init(struct sppp *sp);
307 static void sppp_ipcp_up(struct sppp *sp);
308 static void sppp_ipcp_down(struct sppp *sp);
309 static void sppp_ipcp_open(struct sppp *sp);
310 static void sppp_ipcp_close(struct sppp *sp);
312 static int sppp_ipcp_RCR(struct sppp *sp, struct lcp_header *h, int len);
313 static void sppp_ipcp_RCN_rej(struct sppp *sp, struct lcp_header *h, int len);
314 static void sppp_ipcp_RCN_nak(struct sppp *sp, struct lcp_header *h, int len);
315 static void sppp_ipcp_tlu(struct sppp *sp);
316 static void sppp_ipcp_tld(struct sppp *sp);
317 static void sppp_ipcp_tls(struct sppp *sp);
318 static void sppp_ipcp_tlf(struct sppp *sp);
319 static void sppp_ipcp_scr(struct sppp *sp);
321 static void sppp_ipv6cp_init(struct sppp *sp);
322 static void sppp_ipv6cp_up(struct sppp *sp);
323 static void sppp_ipv6cp_down(struct sppp *sp);
324 static void sppp_ipv6cp_open(struct sppp *sp);
325 static void sppp_ipv6cp_close(struct sppp *sp);
327 static int sppp_ipv6cp_RCR(struct sppp *sp, struct lcp_header *h, int len);
328 static void sppp_ipv6cp_RCN_rej(struct sppp *sp, struct lcp_header *h, int len);
329 static void sppp_ipv6cp_RCN_nak(struct sppp *sp, struct lcp_header *h, int len);
330 static void sppp_ipv6cp_tlu(struct sppp *sp);
331 static void sppp_ipv6cp_tld(struct sppp *sp);
332 static void sppp_ipv6cp_tls(struct sppp *sp);
333 static void sppp_ipv6cp_tlf(struct sppp *sp);
334 static void sppp_ipv6cp_scr(struct sppp *sp);
336 static void sppp_pap_input(struct sppp *sp, struct mbuf *m);
337 static void sppp_pap_init(struct sppp *sp);
338 static void sppp_pap_open(struct sppp *sp);
339 static void sppp_pap_close(struct sppp *sp);
342 static void sppp_pap_tlu(struct sppp *sp);
343 static void sppp_pap_tld(struct sppp *sp);
344 static void sppp_pap_scr(struct sppp *sp);
346 static void sppp_chap_input(struct sppp *sp, struct mbuf *m);
347 static void sppp_chap_init(struct sppp *sp);
348 static void sppp_chap_open(struct sppp *sp);
349 static void sppp_chap_close(struct sppp *sp);
351 static void sppp_chap_tlu(struct sppp *sp);
352 static void sppp_chap_tld(struct sppp *sp);
353 static void sppp_chap_scr(struct sppp *sp);
368 static int sppp_params(struct sppp *sp, u_long cmd, void *data);
371 static void sppp_phase_network(struct sppp *sp);
376 static void sppp_set_ip_addr(struct sppp *sp, u_long src);
379 static void sppp_get_ip6_addrs(struct sppp *sp, struct in6_addr *src,
382 static void sppp_set_ip6_addr(struct sppp *sp, const struct in6_addr *src);
383 static void sppp_gen_ip6_addr(struct sppp *sp, const struct in6_addr *src);
385 static void sppp_suggest_ip6_addr(struct sppp *sp, struct in6_addr *src);
455 struct sppp *sp;
457 sp = malloc(sizeof(struct sppp), M_SPPP, M_WAITOK | M_ZERO);
477 * harmless to allocate struct sppp's for non-sppp
492 "sppp",
496 MODULE_VERSION(sppp, 1);
497 DECLARE_MODULE(sppp, spppmod, SI_SUB_DRIVERS, SI_ORDER_ANY);
511 struct sppp *sp = IFP2SP(ifp);
744 struct sppp *sp = dummy;
755 struct sppp *sp = IFP2SP(ifp);
774 struct sppp *sp = IFP2SP(ifp);
1004 struct sppp *sp = IFP2SP(ifp);
1007 mtx_init(&sp->mtx, "sppp", MTX_NETWORK_LOCK, MTX_DEF | MTX_RECURSE);
1057 struct sppp *sp = IFP2SP(ifp);
1060 KASSERT(mtx_initialized(&sp->mtx), ("sppp mutex is not initialized"));
1081 struct sppp *sp = IFP2SP(ifp);
1091 struct sppp *sp = IFP2SP(ifp);
1104 struct sppp *sp = IFP2SP(ifp);
1120 struct sppp *sp = IFP2SP(ifp);
1148 struct sppp *sp = IFP2SP(ifp);
1171 struct sppp *sp = IFP2SP(ifp);
1289 sppp_cisco_input(struct sppp *sp, struct mbuf *m)
1359 sppp_cisco_send(struct sppp *sp, int type, long par1, long par2)
1407 sppp_cp_send(struct sppp *sp, u_short proto, u_char type,
1452 sppp_cp_input(const struct cp *cp, struct sppp *sp, struct mbuf *m)
1872 sppp_up_event(const struct cp *cp, struct sppp *sp)
1898 sppp_down_event(const struct cp *cp, struct sppp *sp)
1935 sppp_open_event(const struct cp *cp, struct sppp *sp)
1985 sppp_close_event(const struct cp *cp, struct sppp *sp)
2024 sppp_to_event(const struct cp *cp, struct sppp *sp)
2084 sppp_cp_change_state(const struct cp *cp, struct sppp *sp, int newstate)
2116 sppp_pp_up(struct sppp *sp)
2124 sppp_pp_down(struct sppp *sp)
2132 sppp_lcp_init(struct sppp *sp)
2152 sppp_lcp_up(struct sppp *sp)
2196 sppp_lcp_down(struct sppp *sp)
2227 sppp_lcp_open(struct sppp *sp)
2233 sppp_lcp_close(struct sppp *sp)
2241 sppp_to_event(&lcp, (struct sppp *)cookie);
2251 sppp_lcp_RCR(struct sppp *sp, struct lcp_header *h, int len)
2479 sppp_lcp_RCN_rej(struct sppp *sp, struct lcp_header *h, int len)
2543 sppp_lcp_RCN_nak(struct sppp *sp, struct lcp_header *h, int len)
2620 sppp_lcp_tlu(struct sppp *sp)
2690 sppp_lcp_tld(struct sppp *sp)
2716 sppp_lcp_tls(struct sppp *sp)
2734 sppp_lcp_tlf(struct sppp *sp)
2751 sppp_lcp_scr(struct sppp *sp)
2793 sppp_ncp_check(struct sppp *sp)
2808 sppp_lcp_check_and_close(struct sppp *sp)
2831 sppp_ipcp_init(struct sppp *sp)
2843 sppp_ipcp_up(struct sppp *sp)
2849 sppp_ipcp_down(struct sppp *sp)
2855 sppp_ipcp_open(struct sppp *sp)
2896 sppp_ipcp_close(struct sppp *sp)
2909 sppp_to_event(&ipcp, (struct sppp *)cookie);
2919 sppp_ipcp_RCR(struct sppp *sp, struct lcp_header *h, int len)
3129 sppp_ipcp_RCN_rej(struct sppp *sp, struct lcp_header *h, int len)
3174 sppp_ipcp_RCN_nak(struct sppp *sp, struct lcp_header *h, int len)
3252 sppp_ipcp_tlu(struct sppp *sp)
3260 sppp_ipcp_tld(struct sppp *sp)
3265 sppp_ipcp_tls(struct sppp *sp)
3272 sppp_ipcp_tlf(struct sppp *sp)
3280 sppp_ipcp_scr(struct sppp *sp)
3309 sppp_ipcp_init(struct sppp *sp)
3314 sppp_ipcp_up(struct sppp *sp)
3319 sppp_ipcp_down(struct sppp *sp)
3324 sppp_ipcp_open(struct sppp *sp)
3329 sppp_ipcp_close(struct sppp *sp)
3339 sppp_ipcp_RCR(struct sppp *sp, struct lcp_header *h, int len)
3345 sppp_ipcp_RCN_rej(struct sppp *sp, struct lcp_header *h, int len)
3350 sppp_ipcp_RCN_nak(struct sppp *sp, struct lcp_header *h, int len)
3355 sppp_ipcp_tlu(struct sppp *sp)
3360 sppp_ipcp_tld(struct sppp *sp)
3365 sppp_ipcp_tls(struct sppp *sp)
3370 sppp_ipcp_tlf(struct sppp *sp)
3375 sppp_ipcp_scr(struct sppp *sp)
3390 sppp_ipv6cp_init(struct sppp *sp)
3402 sppp_ipv6cp_up(struct sppp *sp)
3408 sppp_ipv6cp_down(struct sppp *sp)
3414 sppp_ipv6cp_open(struct sppp *sp)
3446 sppp_ipv6cp_close(struct sppp *sp)
3454 sppp_to_event(&ipv6cp, (struct sppp *)cookie);
3464 sppp_ipv6cp_RCR(struct sppp *sp, struct lcp_header *h, int len)
3628 sppp_ipv6cp_RCN_rej(struct sppp *sp, struct lcp_header *h, int len)
3674 sppp_ipv6cp_RCN_nak(struct sppp *sp, struct lcp_header *h, int len)
3768 sppp_ipv6cp_tlu(struct sppp *sp)
3776 sppp_ipv6cp_tld(struct sppp *sp)
3781 sppp_ipv6cp_tls(struct sppp *sp)
3788 sppp_ipv6cp_tlf(struct sppp *sp)
3799 sppp_ipv6cp_scr(struct sppp *sp)
3827 static void sppp_ipv6cp_init(struct sppp *sp)
3831 static void sppp_ipv6cp_up(struct sppp *sp)
3835 static void sppp_ipv6cp_down(struct sppp *sp)
3840 static void sppp_ipv6cp_open(struct sppp *sp)
3844 static void sppp_ipv6cp_close(struct sppp *sp)
3852 static int sppp_ipv6cp_RCR(struct sppp *sp, struct lcp_header *h, int len)
3857 static void sppp_ipv6cp_RCN_rej(struct sppp *sp, struct lcp_header *h, int len)
3861 static void sppp_ipv6cp_RCN_nak(struct sppp *sp, struct lcp_header *h, int len)
3865 static void sppp_ipv6cp_tlu(struct sppp *sp)
3869 static void sppp_ipv6cp_tld(struct sppp *sp)
3873 static void sppp_ipv6cp_tls(struct sppp *sp)
3877 static void sppp_ipv6cp_tlf(struct sppp *sp)
3881 static void sppp_ipv6cp_scr(struct sppp *sp)
3975 sppp_chap_input(struct sppp *sp, struct mbuf *m)
4196 sppp_chap_init(struct sppp *sp)
4207 sppp_chap_open(struct sppp *sp)
4220 sppp_chap_close(struct sppp *sp)
4229 struct sppp *sp = (struct sppp *)cookie;
4265 sppp_chap_tlu(struct sppp *sp)
4323 sppp_chap_tld(struct sppp *sp)
4336 sppp_chap_scr(struct sppp *sp)
4377 sppp_pap_input(struct sppp *sp, struct mbuf *m)
4518 sppp_pap_init(struct sppp *sp)
4530 sppp_pap_open(struct sppp *sp)
4547 sppp_pap_close(struct sppp *sp)
4560 struct sppp *sp = (struct sppp *)cookie;
4598 struct sppp *sp = (struct sppp *)cookie;
4611 sppp_pap_tlu(struct sppp *sp)
4639 sppp_pap_tld(struct sppp *sp)
4653 sppp_pap_scr(struct sppp *sp)
4685 sppp_auth_send(const struct cp *cp, struct sppp *sp,
4770 struct sppp *sp = (struct sppp*)dummy;
4823 sppp_get_ip_addrs(struct sppp *sp, u_long *src, u_long *dst, u_long *srcmask)
4867 sppp_set_ip_addr(struct sppp *sp, u_long src)
4925 sppp_get_ip6_addrs(struct sppp *sp, struct in6_addr *src, struct in6_addr *dst,
4975 sppp_gen_ip6_addr(struct sppp *sp, struct in6_addr *addr)
4984 sppp_set_ip6_addr(struct sppp *sp, const struct in6_addr *src)
5027 sppp_suggest_ip6_addr(struct sppp *sp, struct in6_addr *suggest)
5049 sppp_params(struct sppp *sp, u_long cmd, void *data)
5205 sppp_phase_network(struct sppp *sp)
5418 sppp_null(struct sppp *unused)