cadence_uart: U-boot driver
cover cadence_uart: U-boot driver
Hi Peter,
This is a corner case bug discovered by U-boot driver for cadence GEM.
Regards,
Peter
Peter Crosthwaite (1):
cadence_uart: Flush queued characters on reset
hw/cadence_uart.c | 1 + 1 files changed, 1 insertions(+), 0 deletions(-)
PATCH 1/1 cadence_uart: Flush queued characters on reset
Reset can be used to empty the rx-fifo. As the fifo full condition is used to return false from can_receive, queued rx data should be flushed on reset accordingly.
Cc Wendy Liang <[email protected]>
Cc Jason Wu <[email protected]>
Signed-off-by Peter Crosthwaite <[email protected]>
Reported-by Jason Wu <[email protected]>
---
hw/cadence_uart.c | 1 + 1 files changed, 1 insertions(+), 0 deletions(-)
hw/cadence_uart.c +1 -0
@@ -157,6 +157,7 @@ static void uart_rx_reset(UartState *s) { s->rx_wpos =0 ; s->rx_count =0 ; +qemu_chr_accept_input (s->chr); s->r[R_SR ] |=UART_SR_INTR_REMPTY ; s->r[R_SR ] &= ~UART_SR_INTR_RFUL ;
Signature · 1 line
1.7.0.4
Peter Maydell
AppliedRe: [Qemu-devel] [PATCH arm-devs v1 1/1] cadence_uart: Flush queued characters on reset
Quoted 9 lines · Peter Crosthwaite
Reset can be used to empty the rx-fifo. As the fifo full condition is used to return false from
can_receive, queued rx data should be flushed on reset accordingly.Cc Wendy Liang <[email protected]>Cc Jason Wu <[email protected]>Signed-off-by Peter Crosthwaite <[email protected]>Reported-by Jason Wu <[email protected]>
Thanks, applied to arm-devs.next.
-- PMM