summaryrefslogtreecommitdiff
path: root/drivers/serial/Kconfig
diff options
context:
space:
mode:
authorStefan Roese <sr@denx.de>2017-08-16 17:37:16 +0200
committerBin Meng <bmeng.cn@gmail.com>2017-08-24 11:00:47 +0800
commit3ca7a06afb7cbc867b7861a8b9aada74e5bbb559 (patch)
tree725eb62e426a11719fdfaaaa080fe462ddeaea5e /drivers/serial/Kconfig
parent7fded0ce0ff68551ceb631f98d60db162e49f80c (diff)
serial: serial-uclass: Add generic serial RX buffer support
Pasting longer lines into the U-Boot console prompt sometimes leads to characters missing. One problem here is the small 16-byte FIFO of the legacy NS16550 UART, e.g. on x86 platforms. This patch now introduces a Kconfig option to enable RX buffer support for all DM based serial drivers. With this option enabled, I was able paste really long lines into the U-Boot console, without any characters missing. Signed-off-by: Stefan Roese <sr@denx.de> Cc: Simon Glass <sjg@chromium.org> Cc: Bin Meng <bmeng.cn@gmail.com> Cc: Tom Rini <trini@konsulko.com> Reviewed-by: Bin Meng <bmeng.cn@gmail.com> Tested-by: Bin Meng <bmeng.cn@gmail.com>
Diffstat (limited to 'drivers/serial/Kconfig')
-rw-r--r--drivers/serial/Kconfig15
1 files changed, 15 insertions, 0 deletions
diff --git a/drivers/serial/Kconfig b/drivers/serial/Kconfig
index 1c2c5d66e1..aeed538fa4 100644
--- a/drivers/serial/Kconfig
+++ b/drivers/serial/Kconfig
@@ -64,6 +64,21 @@ config DM_SERIAL
implements serial_putc() etc. The uclass interface is
defined in include/serial.h.
+config SERIAL_RX_BUFFER
+ bool "Enable RX buffer for serial input"
+ depends on DM_SERIAL
+ help
+ Enable RX buffer support for the serial driver. This enables
+ pasting longer strings, even when the RX FIFO of the UART is
+ not big enough (e.g. 16 bytes on the normal NS16550).
+
+config SERIAL_RX_BUFFER_SIZE
+ int "RX buffer size"
+ depends on SERIAL_RX_BUFFER
+ default 256
+ help
+ The size of the RX buffer (needs to be power of 2)
+
config SPL_DM_SERIAL
bool "Enable Driver Model for serial drivers in SPL"
depends on DM_SERIAL