[PATCH] net/farsync: add set_current_state() before schedule_timeout()

Insert set_current_state() before schedule_timeout() so the
function delays as expected. Without the addition, schedule_timeout()
will return immediately.

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>
This commit is contained in:
Nishanth Aravamudan 2005-06-20 23:54:25 +02:00 committed by Jeff Garzik
parent a26c074c1c
commit 0da8b14548
1 changed files with 1 additions and 0 deletions

View File

@ -981,6 +981,7 @@ fst_issue_cmd(struct fst_port_info *port, unsigned short cmd)
/* Wait for any previous command to complete */
while (mbval > NAK) {
spin_unlock_irqrestore(&card->card_lock, flags);
set_current_state(TASK_UNINTERRUPTIBLE);
schedule_timeout(1);
spin_lock_irqsave(&card->card_lock, flags);