Lines Matching full:fcs
525 int fcs, i, count, c, proto; in ppp_async_encode() local
536 fcs = ap->tfcs; in ppp_async_encode()
558 fcs = PPP_INITFCS; in ppp_async_encode()
565 fcs = PPP_FCS(fcs, 0xff); in ppp_async_encode()
567 fcs = PPP_FCS(fcs, 0x03); in ppp_async_encode()
572 * Once we put in the last byte, we need to put in the FCS in ppp_async_encode()
581 fcs = PPP_FCS(fcs, c); in ppp_async_encode()
591 ap->tfcs = fcs; in ppp_async_encode()
596 * We have finished the packet. Add the FCS and flag. in ppp_async_encode()
598 fcs = ~fcs; in ppp_async_encode()
599 c = fcs & 0xff; in ppp_async_encode()
601 c = (fcs >> 8) & 0xff; in ppp_async_encode()
763 unsigned int len, fcs; in process_input_packet() local
772 /* check the FCS */ in process_input_packet()
777 fcs = PPP_INITFCS; in process_input_packet()
779 fcs = PPP_FCS(fcs, *p++); in process_input_packet()
780 if (fcs != PPP_GOODFCS) in process_input_packet()
781 goto err; /* bad FCS */ in process_input_packet()
946 int dlen, fcs, i, code; in async_lcp_peek() local
965 fcs = PPP_INITFCS; in async_lcp_peek()
967 fcs = PPP_FCS(fcs, data[i]); in async_lcp_peek()
971 ap->lcp_fcs = fcs; in async_lcp_peek()
976 fcs ^= ap->lcp_fcs; in async_lcp_peek()
978 if (fcs != 0) in async_lcp_peek()