aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/tty/tty_io.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/tty/tty_io.c b/drivers/tty/tty_io.c
index 3f4ad9885430..6556f7452ba6 100644
--- a/drivers/tty/tty_io.c
+++ b/drivers/tty/tty_io.c
@@ -962,12 +962,14 @@ static ssize_t tty_read(struct file *file, char __user *buf, size_t count,
962} 962}
963 963
964void tty_write_unlock(struct tty_struct *tty) 964void tty_write_unlock(struct tty_struct *tty)
965 __releases(&tty->atomic_write_lock)
965{ 966{
966 mutex_unlock(&tty->atomic_write_lock); 967 mutex_unlock(&tty->atomic_write_lock);
967 wake_up_interruptible_poll(&tty->write_wait, POLLOUT); 968 wake_up_interruptible_poll(&tty->write_wait, POLLOUT);
968} 969}
969 970
970int tty_write_lock(struct tty_struct *tty, int ndelay) 971int tty_write_lock(struct tty_struct *tty, int ndelay)
972 __acquires(&tty->atomic_write_lock)
971{ 973{
972 if (!mutex_trylock(&tty->atomic_write_lock)) { 974 if (!mutex_trylock(&tty->atomic_write_lock)) {
973 if (ndelay) 975 if (ndelay)