Commit be2c92b8 authored by Rob Herring's avatar Rob Herring Committed by Greg Kroah-Hartman

serial: core: fix console problems on uart_close

Commit 761ed4a9 ('tty: serial_core: convert uart_close to use
tty_port_close') started setting the ttyport console flag for serial
drivers. This is causing crashes, hangs, or garbage output on several
platforms because the serial shutdown is skipped and IRQs are left
enabled.

Partially revert commit 761ed4a9 and drop reporting UART tty_ports
as a console leaving the console handling to the serial_core as it was
before.

Fixes: 761ed4a9 ("tty: serial_core: convert uart_close to use tty_port_close")
Reported-by: default avatarNiklas Söderlund <niklas.soderlund+renesas@ragnatech.se>
Reported-by: default avatarMike Galbraith <umgwanakikbuti@gmail.com>
Reported-by: default avatarMugunthan V N <mugunthanvnm@ti.com>
Cc: Peter Hurley <peter@hurleysoftware.com>
Cc: Geert Uytterhoeven <geert+renesas@glider.be>
Cc: Alan Cox <alan@linux.intel.com>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: Jiri Slaby <jslaby@suse.com>
Cc: linux-serial@vger.kernel.org
Signed-off-by: default avatarRob Herring <robh@kernel.org>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 09065c5f
...@@ -2746,8 +2746,6 @@ int uart_add_one_port(struct uart_driver *drv, struct uart_port *uport) ...@@ -2746,8 +2746,6 @@ int uart_add_one_port(struct uart_driver *drv, struct uart_port *uport)
uport->cons = drv->cons; uport->cons = drv->cons;
uport->minor = drv->tty_driver->minor_start + uport->line; uport->minor = drv->tty_driver->minor_start + uport->line;
port->console = uart_console(uport);
/* /*
* If this port is a console, then the spinlock is already * If this port is a console, then the spinlock is already
* initialised. * initialised.
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment