summaryrefslogtreecommitdiff
path: root/drivers/net/3c505.c
diff options
context:
space:
mode:
authorDomen Puncer <domen@coderock.org>2005-05-12 22:21:51 -0400
committerJeff Garzik <jgarzik@pobox.com>2005-05-12 22:21:51 -0400
commitc56943e655b0778d3a8517ae165ad4db15557b97 (patch)
tree66756bd2284a99617f7c0a5e7ee6164b3df0f7ff /drivers/net/3c505.c
parent10a87fcf40ce8cee1e85d936cd6d7662943c804e (diff)
[PATCH] net/3c505: replace schedule_timeout() with msleep()
Use msleep() instead of schedule_timeout() to guarantee the task delays as expected. Signed-off-by: Nishanth Aravamudan <nacc@us.ibm.com> Acked-by: Phil Blundell <pb@nexus.co.uk> Signed-off-by: Maximilian Attems <janitor@sternwelten.at> Signed-off-by: Domen Puncer <domen@coderock.org> Signed-off-by: Jeff Garzik <jgarzik@pobox.com>
Diffstat (limited to 'drivers/net/3c505.c')
-rw-r--r--drivers/net/3c505.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/drivers/net/3c505.c b/drivers/net/3c505.c
index 76fa8cc24085..ad17f17e8e7a 100644
--- a/drivers/net/3c505.c
+++ b/drivers/net/3c505.c
@@ -1317,8 +1317,7 @@ static int __init elp_sense(struct net_device *dev)
if (orig_HSR & DIR) {
/* If HCR.DIR is up, we pull it down. HSR.DIR should follow. */
outb(0, dev->base_addr + PORT_CONTROL);
- set_current_state(TASK_UNINTERRUPTIBLE);
- schedule_timeout(30*HZ/100);
+ msleep(300);
if (inb_status(addr) & DIR) {
if (elp_debug > 0)
printk(notfound_msg, 2);
@@ -1327,8 +1326,7 @@ static int __init elp_sense(struct net_device *dev)
} else {
/* If HCR.DIR is down, we pull it up. HSR.DIR should follow. */
outb(DIR, dev->base_addr + PORT_CONTROL);
- set_current_state(TASK_UNINTERRUPTIBLE);
- schedule_timeout(30*HZ/100);
+ msleep(300);
if (!(inb_status(addr) & DIR)) {
if (elp_debug > 0)
printk(notfound_msg, 3);