OSDN Git Service

serial: stm32: add FIFO threshold configuration
authorFabrice Gasnier <fabrice.gasnier@foss.st.com>
Tue, 13 Apr 2021 17:40:15 +0000 (19:40 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 22 Apr 2021 10:11:25 +0000 (12:11 +0200)
commit2aa1bbb21f26de43b55a9d9cab9c0370c15a86ed
tree2406b41b59ee2238ad354361782291f1bd9457b3
parent31db3ce05b1a7c045ff462761a9c6c8ebe25d620
serial: stm32: add FIFO threshold configuration

Add the support for two optional DT properties, to configure RX and TX
FIFO thresholds:
- rx-threshold
- tx-threshold
This replaces hard-coded 8 bytes threshold. Keep 8 as the default value if
not specified, for backward compatibility.

Signed-off-by: Fabrice Gasnier <fabrice.gasnier@foss.st.com>
Signed-off-by: Erwan Le Ray <erwan.leray@foss.st.com>
Changes in v2:
Change added properties naming as proposed by Rob Herring.
Link: https://lore.kernel.org/r/20210413174015.23011-5-erwan.leray@foss.st.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/tty/serial/stm32-usart.c
drivers/tty/serial/stm32-usart.h