diff options
author | Alan Cox <alan@linux.intel.com> | 2012-05-03 23:24:08 +0200 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2012-05-05 01:58:47 +0200 |
commit | d29f3ef39be4eec0362b985305fc526d9be318cf (patch) | |
tree | 35da6af15a899ca767841b864cb1ef290a0f3d4a /drivers/tty/serial/crisv10.c | |
parent | pty: Lock the devpts bits privately (diff) | |
download | linux-d29f3ef39be4eec0362b985305fc526d9be318cf.tar.xz 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/serial/crisv10.c')
-rw-r--r-- | drivers/tty/serial/crisv10.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/tty/serial/crisv10.c b/drivers/tty/serial/crisv10.c index 80b6b1b1f725..b431a5164f45 100644 --- a/drivers/tty/serial/crisv10.c +++ b/drivers/tty/serial/crisv10.c @@ -4052,9 +4052,9 @@ block_til_ready(struct tty_struct *tty, struct file * filp, printk("block_til_ready blocking: ttyS%d, count = %d\n", info->line, info->count); #endif - tty_unlock(); + tty_unlock(tty); schedule(); - tty_lock(); + tty_lock(tty); } set_current_state(TASK_RUNNING); remove_wait_queue(&info->open_wait, &wait); |