Skip to content

Commit 6fd9fff

Browse files
Erwan Le Raygregkh
authored andcommitted
serial: stm32: Use generic DT binding for announcing RTS/CTS lines
Add support of generic DT binding for annoucing RTS/CTS lines. The initial binding 'st,hw-flow-control' is not needed anymore since generic binding is available, but is kept for backward compatibility. Signed-off-by: Erwan Le Ray <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Greg Kroah-Hartman <[email protected]>
1 parent b2cc2b5 commit 6fd9fff

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

drivers/tty/serial/stm32-usart.c

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1033,8 +1033,9 @@ static struct stm32_port *stm32_of_get_stm32_port(struct platform_device *pdev)
10331033
if (WARN_ON(id >= STM32_MAX_PORTS))
10341034
return NULL;
10351035

1036-
stm32_ports[id].hw_flow_control = of_property_read_bool(np,
1037-
"st,hw-flow-ctrl");
1036+
stm32_ports[id].hw_flow_control =
1037+
of_property_read_bool (np, "st,hw-flow-ctrl") /*deprecated*/ ||
1038+
of_property_read_bool (np, "uart-has-rtscts");
10381039
stm32_ports[id].port.line = id;
10391040
stm32_ports[id].cr1_irq = USART_CR1_RXNEIE;
10401041
stm32_ports[id].cr3_irq = 0;

0 commit comments

Comments
 (0)