usb_serial: clang-foramt cleanup of debug_uart_write()

This commit is contained in:
dragonmux 2022-08-19 00:47:58 +01:00 committed by Piotr Esden-Tempski
parent da447a849f
commit f5ecae48f1
1 changed files with 2 additions and 5 deletions

View File

@ -194,10 +194,8 @@ size_t debug_uart_write(const char *buf, const size_t len)
CM_ATOMIC_CONTEXT(); CM_ATOMIC_CONTEXT();
for (size_t i = 0; i < len && (usb_dbg_in + 1) % RX_FIFO_SIZE != usb_dbg_out; ++i) for (size_t i = 0; i < len && (usb_dbg_in + 1) % RX_FIFO_SIZE != usb_dbg_out; ++i) {
{ if (buf[i] == '\n') {
if (buf[i] == '\n')
{
usb_dbg_buf[usb_dbg_in++] = '\r'; usb_dbg_buf[usb_dbg_in++] = '\r';
usb_dbg_in %= RX_FIFO_SIZE; usb_dbg_in %= RX_FIFO_SIZE;
@ -209,7 +207,6 @@ size_t debug_uart_write(const char *buf, const size_t len)
} }
usbuart_run(); usbuart_run();
return len; return len;
} }