Lines Matching refs:res
73 int res; in tty_putchar() local
75 res = k_sem_take(&tty->tx_sem, in tty_putchar()
78 if (res < 0) { in tty_putchar()
79 return res; in tty_putchar()
104 int res = 0; in tty_write() local
118 res = tty_putchar(tty, *p++); in tty_write()
119 if (res < 0) { in tty_write()
122 errno = -res; in tty_write()
123 return res; in tty_write()
145 int res; in tty_getchar() local
147 res = k_sem_take(&tty->rx_sem, SYS_TIMEOUT_MS(tty->rx_timeout)); in tty_getchar()
148 if (res < 0) { in tty_getchar()
149 return res; in tty_getchar()
166 int res = 0; in tty_read_unbuf() local
171 res = uart_poll_in(tty->uart_dev, &c); in tty_read_unbuf()
172 if (res <= -2) { in tty_read_unbuf()
178 errno = res; in tty_read_unbuf()
184 if (res == 0) { in tty_read_unbuf()
198 if (res == -1) { in tty_read_unbuf()
210 int res = 0; in tty_read() local
217 res = tty_getchar(tty); in tty_read()
218 if (res < 0) { in tty_read()
221 errno = -res; in tty_read()
222 return res; in tty_read()
234 *p++ = (uint8_t)res; in tty_read()