aboutsummaryrefslogtreecommitdiff
path: root/drivers/tty/tty_port.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2013-07-31 11:31:06 -0700
committerLinus Torvalds <torvalds@linux-foundation.org>2013-07-31 11:31:06 -0700
commita93f66dc5ff51a8f88f13e4a4b8e3e51ed89c0a5 (patch)
tree228d6264a0f67ee3efd89f050e0406b89a19d1bc /drivers/tty/tty_port.c
parent36f571e9ed0419e73d127e18aa8992ced867268c (diff)
parentd5a12ea7a9e58d9e5c19d25cb668aadb396423ec (diff)
Merge tag 'tty-3.11-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty
Pull tty/serial driver fixes from Greg KH: "Here are 4 tiny tty and serial driver fixes for 3.11-rc4. Nothing big, a refcount leak, a module alias fix, and two fixes to the mxs-auart serial driver" * tag 'tty-3.11-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/tty: serial: arc_uart: Fix module alias tty_port: Fix refcounting leak in tty_port_tty_hangup() serial/mxs-auart: increase time to wait for transmitter to become idle serial/mxs-auart: fix race condition in interrupt handler
Diffstat (limited to 'drivers/tty/tty_port.c')
-rw-r--r--drivers/tty/tty_port.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/drivers/tty/tty_port.c b/drivers/tty/tty_port.c
index 121aeb9393e..f597e88a705 100644
--- a/drivers/tty/tty_port.c
+++ b/drivers/tty/tty_port.c
@@ -256,10 +256,9 @@ void tty_port_tty_hangup(struct tty_port *port, bool check_clocal)
{
struct tty_struct *tty = tty_port_tty_get(port);
- if (tty && (!check_clocal || !C_CLOCAL(tty))) {
+ if (tty && (!check_clocal || !C_CLOCAL(tty)))
tty_hangup(tty);
- tty_kref_put(tty);
- }
+ tty_kref_put(tty);
}
EXPORT_SYMBOL_GPL(tty_port_tty_hangup);