X-Git-Url: http://git.rot13.org/?a=blobdiff_plain;f=drivers%2Fsbus%2Fchar%2Faurora.c;h=d96cc47de5668e203cbb49a4d77c85c2d72c1485;hb=2d610b80e954045ccfc27558f84e482709e5e5b7;hp=650d5e924f4714c1d0c00f4777c1fad58559c645;hpb=16a789c11df5069576ef89f817348dbc6f3bd87e;p=powerpc.git diff --git a/drivers/sbus/char/aurora.c b/drivers/sbus/char/aurora.c index 650d5e924f..d96cc47de5 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); }