mirror of
https://github.com/apache/nuttx.git
synced 2025-01-13 12:08:36 +08:00
Lee Lup Yuen
b2c1930825
Some UART Controllers (Synopsys DesignWare 8250) will trigger spurious interrupts when the Line Control Register (LCR) is set while the UART is busy. This patch provides the option (16550_WAIT_LCR) to wait for UART until it's not busy, before setting the LCR. (16550_WAIT_LCR is disabled by default) This patch fixes the spurious UART interrupts for the upcoming port of NuttX to StarFive JH7110 SoC (with Synopsys DesignWare 8250 UART). [The patch is explained here](https://lupyuen.github.io/articles/plic#appendix-fix-the-spurious-uart-interrupts) drivers/serial/uart_16550.c: If 16550_WAIT_LCR is enabled, wait until UART is not busy before setting LCR include/nuttx/serial/uart_16550.h: Define the UART Status Register (USR) for checking if UART is busy drivers/serial/Kconfig-16550: Added option 16550_WAIT_LCR to 16550 UART Config, disabled by default |
||
---|---|---|
.. | ||
CMakeLists.txt | ||
Kconfig | ||
Kconfig-16550 | ||
Kconfig-lpuart | ||
Kconfig-pl011 | ||
Kconfig-sci | ||
Kconfig-uart | ||
Kconfig-usart | ||
Make.defs | ||
ptmx.c | ||
pty.c | ||
pty.h | ||
serial.c | ||
serial_dma.c | ||
serial_io.c | ||
serial_pl011.c | ||
uart_16550.c | ||
uart_bth4.c | ||
uart_rpmsg.c |