Lines Matching +full:0 +full:x7d
32 #define MCTP_SERIAL_VERSION 0x1 /* DSP0253 defines a single version: 1 */
36 #define BYTE_FRAME 0x7e
37 #define BYTE_ESC 0x7d
39 #define FCS_INIT 0xffff
83 return 0; in next_chunk_len()
122 dev->txpos = 0; in mctp_serial_tx_work()
125 buf[0] = BYTE_FRAME; in mctp_serial_tx_work()
133 if (txlen <= 0) { in mctp_serial_tx_work()
139 dev->txpos = 0; in mctp_serial_tx_work()
145 buf[0] = dev->txbuf[dev->txpos] & ~0x20; in mctp_serial_tx_work()
147 if (txlen <= 0) { in mctp_serial_tx_work()
153 dev->txpos = 0; in mctp_serial_tx_work()
164 buf[0] = BYTE_ESC; in mctp_serial_tx_work()
165 buf[1] = c & ~0x20; in mctp_serial_tx_work()
178 if (txlen <= 0) { in mctp_serial_tx_work()
191 dev->txpos = 0; in mctp_serial_tx_work()
196 dev->txpos = 0; in mctp_serial_tx_work()
200 buf[0] = dev->txfcs >> 8; in mctp_serial_tx_work()
201 buf[1] = dev->txfcs & 0xff; in mctp_serial_tx_work()
204 if (txlen <= 0) { in mctp_serial_tx_work()
210 dev->txpos = 0; in mctp_serial_tx_work()
222 dev->txlen = 0; in mctp_serial_tx_work()
223 dev->txpos = 0; in mctp_serial_tx_work()
248 skb_copy_bits(skb, 0, dev->txbuf, skb->len); in mctp_serial_tx()
249 dev->txpos = 0; in mctp_serial_tx()
291 cb->halen = 0; in mctp_serial_rx()
301 case 0: in mctp_serial_push_header()
320 dev->rxpos = 0; in mctp_serial_push_header()
331 case 0: in mctp_serial_push_trailer()
344 dev->rxlen = 0; in mctp_serial_push_trailer()
345 dev->rxpos = 0; in mctp_serial_push_trailer()
363 c |= 0x20; in mctp_serial_push()
374 dev->rxpos = 0; in mctp_serial_push()
405 for (i = 0; i < len; i++) in mctp_serial_tty_receive_buf()
432 ndev->hard_header_len = 0; in mctp_serial_setup()
433 ndev->addr_len = 0; in mctp_serial_setup()
454 if (idx < 0) in mctp_serial_open()
481 return 0; in mctp_serial_open()
545 memset(dev, 0x0, sizeof(*dev)); in test_next_chunk_len()
549 for (size_t i = 0; i < MAX_CHUNKS; i++) { in test_next_chunk_len()
554 if (next == 0) { in test_next_chunk_len()
566 .input = { 0x00, 0x11, 0x22, 0x7e, 0x80 },
567 .chunks = { 3, 1, 1, 0},
571 .input = { 0x00, 0x11, 0x22, 0x7e, 0x7d },
572 .chunks = { 3, 1, 1, 0},
576 .input = { 0x7e, 0x11, 0x22, },
577 .chunks = { 1, 2, 0},
581 .input = { 0x7e, 0x7e, 0x7d, },
582 .chunks = { 1, 1, 1, 0},
586 .input = { 0x7e, 0x7e, 0x00, 0x7d, },
587 .chunks = { 1, 1, 1, 1, 0},
591 .input = { 0x7e, 0x7e, 0x00, 0x7d, 0x10, 0x10},
592 .chunks = { 1, 1, 1, 1, 2, 0},
596 .input = { 0x7e },
597 .chunks = { 1, 0 },
601 .input = { 0x80 },
602 .chunks = { 1, 0 },
606 .input = { 0x80, 0x80, 0x00 },
607 .chunks = { 3, 0 },
611 .input = { 0x01, 0x00, 0x08, 0xc8, 0x00, 0x80, 0x02 },
612 .chunks = { 7, 0 },
616 .input = { 0x01, 0x00, 0x08, 0xc8, 0x7e, 0x80, 0x02 },
617 .chunks = { 4, 1, 2, 0 },