Browse Source
The buffer_length != 0 is used to check if there is transfer ongoing inside the uart_stm32_async_tx function. uart_stm32_dma_tx_cb clears it to 0 when TX DMA is finished, but before the USART send all the data from shift register. buffer_length is also cleared in callback async_evt_tx_done, which is called when USART finished sending all the bytes. If the uart_stm32_async_tx would be called after uart_stm32_async_tx, but before async_evt_tx_done there could be race condition on buffer_length. Signed-off-by: Adam BERLINGER <adam.berlinger@st.com>pull/89751/head
1 changed files with 0 additions and 2 deletions
Loading…
Reference in new issue