diff options
author | Yinghai Lu <Yinghai.Lu@Sun.COM> | 2008-02-05 01:27:46 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2008-02-05 12:44:09 -0500 |
commit | c3e4642be734ce3d2c7398246d8cbced3a039f54 (patch) | |
tree | 68c689b44e263501433ce73e8ccdd586d9916e43 /drivers/serial | |
parent | 1523508d6321436b6edfcd99aab04a344f9aed3f (diff) |
serial: keep the DTR setting for serial console.
with reverting "x86, serial: convert legacy COM ports to platform devices",
we will have the serial console before the port is probled again.
uart_add_one_port==>uart_configure_port==>set_mcttrl(port, 0) will clear
the DTR setting by uart_set_options(). then I will lose my output from
serial console again.
So try to keep DTR in uart_configure_port()
Signed-off-by: Yinghai Lu <yinghai.lu@sun.com>
Cc: Russell King <rmk@arm.linux.org.uk>
Cc: Alan Cox <alan@lxorguk.ukuu.org.uk>
Cc: Andi Kleen <ak@suse.de>
Cc: Bjorn Helgaas <bjorn.helgaas@hp.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers/serial')
-rw-r--r-- | drivers/serial/serial_core.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/serial/serial_core.c b/drivers/serial/serial_core.c index 3bb5d241dd40..0cf382b55d4b 100644 --- a/drivers/serial/serial_core.c +++ b/drivers/serial/serial_core.c | |||
@@ -2150,10 +2150,11 @@ uart_configure_port(struct uart_driver *drv, struct uart_state *state, | |||
2150 | 2150 | ||
2151 | /* | 2151 | /* |
2152 | * Ensure that the modem control lines are de-activated. | 2152 | * Ensure that the modem control lines are de-activated. |
2153 | * keep the DTR setting that is set in uart_set_options() | ||
2153 | * We probably don't need a spinlock around this, but | 2154 | * We probably don't need a spinlock around this, but |
2154 | */ | 2155 | */ |
2155 | spin_lock_irqsave(&port->lock, flags); | 2156 | spin_lock_irqsave(&port->lock, flags); |
2156 | port->ops->set_mctrl(port, 0); | 2157 | port->ops->set_mctrl(port, port->mctrl & TIOCM_DTR); |
2157 | spin_unlock_irqrestore(&port->lock, flags); | 2158 | spin_unlock_irqrestore(&port->lock, flags); |
2158 | 2159 | ||
2159 | /* | 2160 | /* |