drivers: nrf: Fix long receptions in UARTE async API.
If reception was longer than rx timeout, UART_RX_RDY event would provide data with delay, and synchronise at buffer end. This change makes sure that all data is given to user when timeout occurs. Signed-off-by: Mieszko Mierunski <mieszko.mierunski@nordicsemi.no>
This commit is contained in:
parent
a7a625098e
commit
7b0576243a
1 changed files with 1 additions and 3 deletions
|
@ -690,9 +690,7 @@ static void endrx_isr(struct device *dev)
|
|||
data->async->rx_buf = data->async->rx_next_buf;
|
||||
data->async->rx_next_buf = NULL;
|
||||
|
||||
data->async->rx_total_byte_cnt += rx_len;
|
||||
data->async->rx_total_user_byte_cnt =
|
||||
data->async->rx_total_byte_cnt;
|
||||
data->async->rx_total_user_byte_cnt += rx_len;
|
||||
data->async->rx_offset = 0;
|
||||
} else {
|
||||
data->async->rx_buf = NULL;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue