diff options
Diffstat (limited to 'drivers/net/wireless/ipw2100.c')
-rw-r--r-- | drivers/net/wireless/ipw2100.c | 17 |
1 files changed, 6 insertions, 11 deletions
diff --git a/drivers/net/wireless/ipw2100.c b/drivers/net/wireless/ipw2100.c index 2414e6493aa5..e5cdb5bfabc8 100644 --- a/drivers/net/wireless/ipw2100.c +++ b/drivers/net/wireless/ipw2100.c | |||
@@ -800,8 +800,7 @@ static int ipw2100_hw_send_command(struct ipw2100_priv *priv, | |||
800 | * doesn't seem to have as many firmware restart cycles... | 800 | * doesn't seem to have as many firmware restart cycles... |
801 | * | 801 | * |
802 | * As a test, we're sticking in a 1/100s delay here */ | 802 | * As a test, we're sticking in a 1/100s delay here */ |
803 | set_current_state(TASK_UNINTERRUPTIBLE); | 803 | schedule_timeout_uninterruptible(msecs_to_jiffies(10)); |
804 | schedule_timeout(HZ / 100); | ||
805 | 804 | ||
806 | return 0; | 805 | return 0; |
807 | 806 | ||
@@ -1256,8 +1255,7 @@ static int ipw2100_start_adapter(struct ipw2100_priv *priv) | |||
1256 | IPW_DEBUG_FW("Waiting for f/w initialization to complete...\n"); | 1255 | IPW_DEBUG_FW("Waiting for f/w initialization to complete...\n"); |
1257 | i = 5000; | 1256 | i = 5000; |
1258 | do { | 1257 | do { |
1259 | set_current_state(TASK_UNINTERRUPTIBLE); | 1258 | schedule_timeout_uninterruptible(msecs_to_jiffies(40)); |
1260 | schedule_timeout(40 * HZ / 1000); | ||
1261 | /* Todo... wait for sync command ... */ | 1259 | /* Todo... wait for sync command ... */ |
1262 | 1260 | ||
1263 | read_register(priv->net_dev, IPW_REG_INTA, &inta); | 1261 | read_register(priv->net_dev, IPW_REG_INTA, &inta); |
@@ -1411,8 +1409,7 @@ static int ipw2100_hw_phy_off(struct ipw2100_priv *priv) | |||
1411 | (val2 & IPW2100_COMMAND_PHY_OFF)) | 1409 | (val2 & IPW2100_COMMAND_PHY_OFF)) |
1412 | return 0; | 1410 | return 0; |
1413 | 1411 | ||
1414 | set_current_state(TASK_UNINTERRUPTIBLE); | 1412 | schedule_timeout_uninterruptible(HW_PHY_OFF_LOOP_DELAY); |
1415 | schedule_timeout(HW_PHY_OFF_LOOP_DELAY); | ||
1416 | } | 1413 | } |
1417 | 1414 | ||
1418 | return -EIO; | 1415 | return -EIO; |
@@ -1466,7 +1463,7 @@ fail_up: | |||
1466 | 1463 | ||
1467 | static int ipw2100_hw_stop_adapter(struct ipw2100_priv *priv) | 1464 | static int ipw2100_hw_stop_adapter(struct ipw2100_priv *priv) |
1468 | { | 1465 | { |
1469 | #define HW_POWER_DOWN_DELAY (HZ / 10) | 1466 | #define HW_POWER_DOWN_DELAY (msecs_to_jiffies(100)) |
1470 | 1467 | ||
1471 | struct host_command cmd = { | 1468 | struct host_command cmd = { |
1472 | .host_command = HOST_PRE_POWER_DOWN, | 1469 | .host_command = HOST_PRE_POWER_DOWN, |
@@ -1520,10 +1517,8 @@ static int ipw2100_hw_stop_adapter(struct ipw2100_priv *priv) | |||
1520 | printk(KERN_WARNING DRV_NAME ": " | 1517 | printk(KERN_WARNING DRV_NAME ": " |
1521 | "%s: Power down command failed: Error %d\n", | 1518 | "%s: Power down command failed: Error %d\n", |
1522 | priv->net_dev->name, err); | 1519 | priv->net_dev->name, err); |
1523 | else { | 1520 | else |
1524 | set_current_state(TASK_UNINTERRUPTIBLE); | 1521 | schedule_timeout_uninterruptible(HW_POWER_DOWN_DELAY); |
1525 | schedule_timeout(HW_POWER_DOWN_DELAY); | ||
1526 | } | ||
1527 | } | 1522 | } |
1528 | 1523 | ||
1529 | priv->status &= ~STATUS_ENABLED; | 1524 | priv->status &= ~STATUS_ENABLED; |