Home
last modified time | relevance | path

Searched refs:fcs (Results 1 – 3 of 3) sorted by relevance

/libmctp-latest/
Dcrc-16-ccitt.c46 uint16_t crc_16_ccitt(uint16_t fcs, const uint8_t *cp, uint32_t len) in crc_16_ccitt() argument
49 fcs = crc_16_ccitt_byte(fcs, *cp++); in crc_16_ccitt()
51 return fcs; in crc_16_ccitt()
54 uint16_t crc_16_ccitt_byte(uint16_t fcs, const uint8_t c) in crc_16_ccitt_byte() argument
56 return (fcs >> 8) ^ crc_16_ccitt_table[(fcs ^ c) & 0xff]; in crc_16_ccitt_byte()
Dcrc-16-ccitt.h10 uint16_t crc_16_ccitt(uint16_t fcs, const uint8_t *cp, uint32_t len);
12 uint16_t crc_16_ccitt_byte(uint16_t fcs, const uint8_t c);
Dserial.c146 uint16_t fcs; in mctp_binding_serial_tx() local
158 fcs = crc_16_ccitt(FCS_INIT_16, (const uint8_t *)hdr + 1, 2); in mctp_binding_serial_tx()
159 fcs = crc_16_ccitt(fcs, (const uint8_t *)mctp_pktbuf_hdr(pkt), len); in mctp_binding_serial_tx()
173 tlr->fcs_msb = fcs >> 8; in mctp_binding_serial_tx()
174 tlr->fcs_lsb = fcs & 0xff; in mctp_binding_serial_tx()