[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:
parent
a26c074c1c
commit
0da8b14548
|
@ -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);
|
||||
|
||||
|
|
Loading…
Reference in New Issue