Ver Fonte

be2net: fix mbox polling for signal reception

Sending mbox cmds require multiple steps of writing to the DB register and polling
for an ack. Gettting interrupted in the middle by a signal breaks the mbox protocol.
Use msleep() to not get interrupted.

Signed-off-by: Sathya Perla <sathya.perla@emulex.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Sathya Perla há 14 anos atrás
pai
commit
1dbf53a282
1 ficheiros alterados com 1 adições e 2 exclusões
  1. 1 2
      drivers/net/benet/be_cmds.c

+ 1 - 2
drivers/net/benet/be_cmds.c

@@ -298,8 +298,7 @@ static int be_mbox_db_ready_wait(struct be_adapter *adapter, void __iomem *db)
 			return -1;
 		}
 
-		set_current_state(TASK_INTERRUPTIBLE);
-		schedule_timeout(msecs_to_jiffies(1));
+		msleep(1);
 		msecs++;
 	} while (true);