linux-stable/drivers/tty
Gabriel Krisman Bertazi f209fa03fc serial: 8250_pci: Detach low-level driver during PCI error recovery
During a PCI error recovery, like the ones provoked by EEH in the ppc64
platform, all IO to the device must be blocked while the recovery is
completed.  Current 8250_pci implementation only suspends the port
instead of detaching it, which doesn't prevent incoming accesses like
TIOCMGET and TIOCMSET calls from reaching the device.  Those end up
racing with the EEH recovery, crashing it.  Similar races were also
observed when opening the device and when shutting it down during
recovery.

This patch implements a more robust IO blockage for the 8250_pci
recovery by unregistering the port at the beginning of the procedure and
re-adding it afterwards.  Since the port is detached from the uart
layer, we can be sure that no request will make through to the device
during recovery.  This is similar to the solution used by the JSM serial
driver.

I thank Peter Hurley <peter@hurleysoftware.com> for valuable input on
this one over one year ago.

Signed-off-by: Gabriel Krisman Bertazi <krisman@linux.vnet.ibm.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2016-11-29 20:20:07 +01:00
..
hvc tty/hvc: Use opal irqchip interface if available 2016-07-27 12:38:20 +10:00
ipwireless tty: ipwireless, cleanup TIOCGSERIAL 2016-06-25 08:56:30 -07:00
serial serial: 8250_pci: Detach low-level driver during PCI error recovery 2016-11-29 20:20:07 +01:00
vt vt: fix Scroll Lock LED trigger name 2016-11-16 10:03:52 +01:00
amiserial.c tty: amiserial: fix invalid user-pointer check 2016-11-10 14:41:25 +01:00
bfin_jtag_comm.c
cyclades.c tty: stop defining STD_COM_FLAGS in drivers 2016-06-25 08:56:30 -07:00
ehv_bytechan.c
goldfish.c
isicom.c
Kconfig devpts: Make each mount of devpts an independent filesystem. 2016-06-05 10:36:01 -07:00
Makefile
metag_da.c timers, drivers/tty/metag_da: Initialize the poll timer as pinned 2016-07-07 10:25:14 +02:00
mips_ejtag_fdc.c timers, drivers/tty/mips_ejtag: Initialize the poll timer as pinned 2016-07-07 10:34:59 +02:00
moxa.c
moxa.h
mxser.c tty: cyclades+mxser, do not initialize to zero 2016-06-25 08:56:30 -07:00
mxser.h
n_gsm.c TTY and Serial driver update for 4.7-rc1 2016-05-20 20:57:27 -07:00
n_hdlc.c
n_r3964.c
n_tracerouter.c
n_tracesink.c
n_tracesink.h
n_tty.c
nozomi.c tty: nozomi: use permission-specific DEVICE_ATTR variants 2016-11-10 15:10:37 +01:00
pty.c pty: make ptmx file ops read-only after init 2016-09-15 12:47:03 +02:00
rocket.c tty: rocket: fix invalid user-pointer checks 2016-11-10 14:41:25 +01:00
rocket.h
rocket_int.h
synclink.c TTY and Serial driver update for 4.7-rc1 2016-05-20 20:57:27 -07:00
synclink_gt.c TTY and Serial driver update for 4.7-rc1 2016-05-20 20:57:27 -07:00
synclinkmp.c TTY and Serial driver update for 4.7-rc1 2016-05-20 20:57:27 -07:00
sysrq.c Revert "drivers/tty: Explicitly pass current to show_stack" 2016-09-28 08:12:27 +02:00
tty_audit.c
tty_buffer.c
tty_io.c
tty_ioctl.c
tty_ldisc.c
tty_ldsem.c
tty_mutex.c
tty_port.c