aboutsummaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorNishanth Aravamudan <nacc@us.ibm.com>2005-07-24 19:34:19 -0700
committerDavid S. Miller <davem@davemloft.net>2005-07-24 19:34:19 -0700
commit70c83375bb47cadd60fdb923ad913d4f4be75aba (patch)
tree3453e8fb3622dfd56f6d41ca1f405a037b3306de /drivers
parent[SPARC]: Remvoe APM_RTC_IS_GMT from config. (diff)
downloadlinux-dev-70c83375bb47cadd60fdb923ad913d4f4be75aba.tar.xz
linux-dev-70c83375bb47cadd60fdb923ad913d4f4be75aba.zip
[SPARC]: sbus/aurora: replace schedule_timeout() with msleep_interruptible()
Use msleep_interruptible() instead of schedule_timeout() to guarantee the task delays as expected. Signed-off-by: Nishanth Aravamudan <nacc@us.ibm.com> Signed-off-by: Maximilian Attems <janitor@sternwelten.at> Signed-off-by: Domen Puncer <domen@coderock.org>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/sbus/char/aurora.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/drivers/sbus/char/aurora.c b/drivers/sbus/char/aurora.c
index 650d5e924f47..d96cc47de566 100644
--- a/drivers/sbus/char/aurora.c
+++ b/drivers/sbus/char/aurora.c
@@ -1515,8 +1515,7 @@ static void aurora_close(struct tty_struct * tty, struct file * filp)
*/
timeout = jiffies+HZ;
while(port->SRER & SRER_TXEMPTY) {
- current->state = TASK_INTERRUPTIBLE;
- schedule_timeout(port->timeout);
+ msleep_interruptible(jiffies_to_msecs(port->timeout));
if (time_after(jiffies, timeout))
break;
}
@@ -1533,8 +1532,7 @@ static void aurora_close(struct tty_struct * tty, struct file * filp)
port->tty = 0;
if (port->blocked_open) {
if (port->close_delay) {
- current->state = TASK_INTERRUPTIBLE;
- schedule_timeout(port->close_delay);
+ msleep_interruptible(jiffies_to_msecs(port->close_delay));
}
wake_up_interruptible(&port->open_wait);
}