This fixes the case where uart_tx() called from tx callback fill UART output fifo and immediately execute callback again. This can happen when hardware does not have interrupt for output FIFO empty and there is no non-blocking way to tell that transfer finished. For such case as soon as output FIFO is filled there is interrupt that informs that more data can be transmitted. For hardware with 32 byte fifo callback was seen to be executed recursively 3 times. That would not be a problem if chained_write_next_buf was set BEFORE next call uart_tx(). Additionally semaphore max value is increased to 2 to accommodate such case. Signed-off-by: Jerzy Kasenberg <jerzy.kasenberg.xr@bp.renesas.com> |
||
|---|---|---|
| .. | ||
| uart_async_api | ||
| uart_async_dual | ||
| uart_async_rx | ||
| uart_basic_api | ||
| uart_elementary | ||
| uart_emul | ||
| uart_errors | ||
| uart_mix_fifo_poll | ||
| uart_pm | ||