diff options
author | Johan Hovold <jhovold@gmail.com> | 2013-03-07 15:55:49 +0100 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2013-03-18 16:27:53 -0700 |
commit | 31ca020b57f7c08da187613cf20becd664c467fa (patch) | |
tree | d9e88ffeba1fd99eb52e2f98d93b5584eb62b2c9 /drivers/tty/tty_port.c | |
parent | 8bde9658a0e6a7098dcda1ce6ea6b278029644b4 (diff) | |
download | op-kernel-dev-31ca020b57f7c08da187613cf20becd664c467fa.zip op-kernel-dev-31ca020b57f7c08da187613cf20becd664c467fa.tar.gz |
TTY: wake up processes last at hangup
Move wake up of processes on blocked-open and modem-status wait queues
to after port shutdown at hangup.
This way the woken up processes can use the ASYNC_INITIALIZED flag to
detect port shutdown.
Note that this is the order currently used by serial-core.
Signed-off-by: Johan Hovold <jhovold@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/tty/tty_port.c')
-rw-r--r-- | drivers/tty/tty_port.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/tty/tty_port.c b/drivers/tty/tty_port.c index 2aea2f9..73bc1d9 100644 --- a/drivers/tty/tty_port.c +++ b/drivers/tty/tty_port.c @@ -231,9 +231,9 @@ void tty_port_hangup(struct tty_port *port) } port->tty = NULL; spin_unlock_irqrestore(&port->lock, flags); + tty_port_shutdown(port); wake_up_interruptible(&port->open_wait); wake_up_interruptible(&port->delta_msr_wait); - tty_port_shutdown(port); } EXPORT_SYMBOL(tty_port_hangup); |