summaryrefslogtreecommitdiffstats
path: root/drivers/tty/cyclades.c
diff options
context:
space:
mode:
authorAlan Cox <alan@linux.intel.com>2012-05-03 22:24:08 +0100
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2012-05-04 16:58:47 -0700
commitd29f3ef39be4eec0362b985305fc526d9be318cf (patch)
tree35da6af15a899ca767841b864cb1ef290a0f3d4a /drivers/tty/cyclades.c
parentd739e65bb21d34f0f5d3bf4048410e534fbec148 (diff)
downloadlinux-d29f3ef39be4eec0362b985305fc526d9be318cf.tar.gz
linux-d29f3ef39be4eec0362b985305fc526d9be318cf.tar.bz2
linux-d29f3ef39be4eec0362b985305fc526d9be318cf.zip
tty_lock: Localise the lock
In each remaining case the tty_lock is associated with a specific tty. This means we can now lock on a per tty basis. We do need tty_lock_pair() for the pty case. Uglier but still a step in the right direction. [fixed up calls in 3 missing drivers - gregkh] Signed-off-by: Alan Cox <alan@linux.intel.com> Acked-by: Arnd Bergmann <arnd@arndb.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/tty/cyclades.c')
-rw-r--r--drivers/tty/cyclades.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/tty/cyclades.c b/drivers/tty/cyclades.c
index e61cabdd69df..6984e1a2686a 100644
--- a/drivers/tty/cyclades.c
+++ b/drivers/tty/cyclades.c
@@ -1599,7 +1599,7 @@ static int cy_open(struct tty_struct *tty, struct file *filp)
* If the port is the middle of closing, bail out now
*/
if (tty_hung_up_p(filp) || (info->port.flags & ASYNC_CLOSING)) {
- wait_event_interruptible_tty(info->port.close_wait,
+ wait_event_interruptible_tty(tty, info->port.close_wait,
!(info->port.flags & ASYNC_CLOSING));
return (info->port.flags & ASYNC_HUP_NOTIFY) ? -EAGAIN: -ERESTARTSYS;
}