diff options
author | Paolo Bonzini <pbonzini@redhat.com> | 2015-11-24 13:34:40 -0500 |
---|---|---|
committer | Paolo Bonzini <pbonzini@redhat.com> | 2015-11-24 13:34:40 -0500 |
commit | 8bd142c01648cdb33e9bcafa0448ba2c20ed814c (patch) | |
tree | 9197c60d3f9d4036f38f281a183e94750ceea1d7 /drivers/tty/tty_io.c | |
parent | d792abacaf1a1a8dfea353fab699b97fa6251c2a (diff) | |
parent | fbb4574ce9a37e15a9872860bf202f2be5bdf6c4 (diff) |
Merge tag 'kvm-arm-for-v4.4-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/kvmarm/kvmarm into kvm-master
KVM/ARM Fixes for v4.4-rc3.
Includes some timer fixes, properly unmapping PTEs, an errata fix, and two
tweaks to the EL2 panic code.
Diffstat (limited to 'drivers/tty/tty_io.c')
-rw-r--r-- | drivers/tty/tty_io.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/tty/tty_io.c b/drivers/tty/tty_io.c index 0c41dbcb90b8..bcc8e1e8bb72 100644 --- a/drivers/tty/tty_io.c +++ b/drivers/tty/tty_io.c | |||
@@ -1282,18 +1282,22 @@ int tty_send_xchar(struct tty_struct *tty, char ch) | |||
1282 | int was_stopped = tty->stopped; | 1282 | int was_stopped = tty->stopped; |
1283 | 1283 | ||
1284 | if (tty->ops->send_xchar) { | 1284 | if (tty->ops->send_xchar) { |
1285 | down_read(&tty->termios_rwsem); | ||
1285 | tty->ops->send_xchar(tty, ch); | 1286 | tty->ops->send_xchar(tty, ch); |
1287 | up_read(&tty->termios_rwsem); | ||
1286 | return 0; | 1288 | return 0; |
1287 | } | 1289 | } |
1288 | 1290 | ||
1289 | if (tty_write_lock(tty, 0) < 0) | 1291 | if (tty_write_lock(tty, 0) < 0) |
1290 | return -ERESTARTSYS; | 1292 | return -ERESTARTSYS; |
1291 | 1293 | ||
1294 | down_read(&tty->termios_rwsem); | ||
1292 | if (was_stopped) | 1295 | if (was_stopped) |
1293 | start_tty(tty); | 1296 | start_tty(tty); |
1294 | tty->ops->write(tty, &ch, 1); | 1297 | tty->ops->write(tty, &ch, 1); |
1295 | if (was_stopped) | 1298 | if (was_stopped) |
1296 | stop_tty(tty); | 1299 | stop_tty(tty); |
1300 | up_read(&tty->termios_rwsem); | ||
1297 | tty_write_unlock(tty); | 1301 | tty_write_unlock(tty); |
1298 | return 0; | 1302 | return 0; |
1299 | } | 1303 | } |