Thread (14 messages) 14 messages, 3 authors, 2011-12-12
STALE5293d

[PATCH RESEND 6/8] serial: 8250: update rs485 flags with polarity settings

From: Wolfram Sang <hidden>
Date: 2011-12-09 17:08:48
Also in: lkml
Subsystem: 8250/16?50 (and clone uarts) serial driver, the rest, tty layer and serial drivers · Maintainers: Greg Kroah-Hartman, Linus Torvalds, Jiri Slaby

Report the only mode we can support with the 16C850.

Signed-off-by: Wolfram Sang <redacted>
---
 drivers/tty/serial/8250.c |    3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)
diff --git a/drivers/tty/serial/8250.c b/drivers/tty/serial/8250.c
index 28b3608..8cf6d76 100644
--- a/drivers/tty/serial/8250.c
+++ b/drivers/tty/serial/8250.c
@@ -2750,6 +2750,9 @@ static int serial8250_ioctl_port(struct uart_port *port,
 		serial_outp(up, UART_LCR, lcr);
 		spin_unlock_irqrestore(&up->port.lock, flags);
 
+		/* only mode supported by the 16C850 */
+		rs485ctrl.flags &= ~SER_RS485_RTS_ON_SEND;
+		rs485ctrl.flags |= SER_RS485_RTS_AFTER_SEND;
 		up->rs485_flags = rs485ctrl.flags;
 
 		return 0;
-- 
1.7.7.3
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help