Skip to content
Commit 863fef4a authored by Ron Smith's avatar Ron Smith Committed by Anas Nashif
Browse files

drivers: serial: uart_sam0: fix |= incorrectly clearing all INTFLAGS.



fix uart_sam0_irq_update to only clear the RXS bit by writing only the
RXS bitflag to the INTFLAG register. Performing an |= opperation
with the bitflag for RXS incorrectly clears all pending interrupts set
since writing 1 to a INTFLAG clears that bit field. This causes a race
condition on when TXC will be cleared before all bytes have finished
being clocked out on tx and TXC being set 1 again. If tx finishes first,
any driver using uart_irq_tx_complete will deadlock the system.

Signed-off-by: default avatarRon Smith <rockyowl171@gmail.com>
parent 847b3205
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment