diff options
author | Mark Brown <broonie@kernel.org> | 2014-11-14 17:56:04 +0000 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2014-11-14 17:56:04 +0000 |
commit | 8eb52971d4749c0192358e1942ca83d8dc7e686b (patch) | |
tree | 418db997d718e14be2d5d9436d50985a4616156d /drivers/tty | |
parent | d91fd220833b8a6250ff6abf86c7e66a75655ee7 (diff) | |
parent | be70188832b22a8f1a49d0e3a3eb2209f9cfdc8a (diff) |
Merge tag 'v3.10.60' into linux-linaro-lsk
This is the 3.10.60 stable release
Diffstat (limited to 'drivers/tty')
-rw-r--r-- | drivers/tty/serial/serial_core.c | 2 | ||||
-rw-r--r-- | drivers/tty/tty_io.c | 7 |
2 files changed, 7 insertions, 2 deletions
diff --git a/drivers/tty/serial/serial_core.c b/drivers/tty/serial/serial_core.c index 0f1cc2c8c22a..1fabb22ae615 100644 --- a/drivers/tty/serial/serial_core.c +++ b/drivers/tty/serial/serial_core.c @@ -359,7 +359,7 @@ uart_get_baud_rate(struct uart_port *port, struct ktermios *termios, * The spd_hi, spd_vhi, spd_shi, spd_warp kludge... * Die! Die! Die! */ - if (baud == 38400) + if (try == 0 && baud == 38400) baud = altbaud; /* diff --git a/drivers/tty/tty_io.c b/drivers/tty/tty_io.c index 3723c0ebb316..d35afccdb6c9 100644 --- a/drivers/tty/tty_io.c +++ b/drivers/tty/tty_io.c @@ -1698,6 +1698,7 @@ int tty_release(struct inode *inode, struct file *filp) int pty_master, tty_closing, o_tty_closing, do_sleep; int idx; char buf[64]; + long timeout = 0; if (tty_paranoia_check(tty, inode, __func__)) return 0; @@ -1782,7 +1783,11 @@ int tty_release(struct inode *inode, struct file *filp) __func__, tty_name(tty, buf)); tty_unlock_pair(tty, o_tty); mutex_unlock(&tty_mutex); - schedule(); + schedule_timeout_killable(timeout); + if (timeout < 120 * HZ) + timeout = 2 * timeout + 1; + else + timeout = MAX_SCHEDULE_TIMEOUT; } /* |