aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/tty/pty.c
diff options
context:
space:
mode:
authorPeter Hurley <peter@hurleysoftware.com>2014-11-05 12:13:02 -0500
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2014-11-05 21:50:42 -0500
commit2febdb632bb96235b94b8fccaf882a78f8f4b2bb (patch)
treef4740b43b225a863f05df7edb59d3b3badfdb445 /drivers/tty/pty.c
parent2aff5e2bc62db43e05c814461a08aff0fc2b7fe5 (diff)
tty: Preset lock subclass for nested tty locks
Eliminate the requirement of specifying the tty lock nesting at lock time; instead, set the lock subclass for slave ptys at pty install (normal ttys and master ptys use subclass 0). Signed-off-by: Peter Hurley <peter@hurleysoftware.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/tty/pty.c')
-rw-r--r--drivers/tty/pty.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/tty/pty.c b/drivers/tty/pty.c
index bdb8fd1a2026..11db7dc8676b 100644
--- a/drivers/tty/pty.c
+++ b/drivers/tty/pty.c
@@ -399,6 +399,8 @@ static int pty_common_install(struct tty_driver *driver, struct tty_struct *tty,
399 if (!o_tty) 399 if (!o_tty)
400 goto err_put_module; 400 goto err_put_module;
401 401
402 tty_set_lock_subclass(o_tty);
403
402 if (legacy) { 404 if (legacy) {
403 /* We always use new tty termios data so we can do this 405 /* We always use new tty termios data so we can do this
404 the easy way .. */ 406 the easy way .. */