]> git.hungrycats.org Git - linux/commitdiff
[PATCH] ieee1394: replace schedule_timeout() with msleep_interruptible()
authorMaximilian Attems <janitor@sternwelten.at>
Tue, 19 Oct 2004 01:22:53 +0000 (18:22 -0700)
committerLinus Torvalds <torvalds@ppc970.osdl.org>
Tue, 19 Oct 2004 01:22:53 +0000 (18:22 -0700)
Signed-off-by: Nishanth Aravamudan <nacc@us.ibm.com>
Signed-off-by: Maximilian Attems <janitor@sternwelten.at>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
drivers/ieee1394/nodemgr.c
drivers/ieee1394/sbp2.c

index cc9c999f9a8bc565d8311620569431248d7dfb1c..2a9ff6f0229bff99ec67f33aa206b828f91080b9 100644 (file)
@@ -70,8 +70,7 @@ static int nodemgr_bus_read(struct csr1212_csr *csr, u64 addr, u16 length,
                if (!ret)
                        break;
 
-               set_current_state(TASK_INTERRUPTIBLE);
-               if (schedule_timeout (HZ/3))
+               if (msleep_interruptible(334))
                        return -EINTR;
        }
 
@@ -1496,7 +1495,7 @@ static int nodemgr_host_thread(void *__hi)
                 * to make sure things settle down. */
                for (i = 0; i < 4 ; i++) {
                        set_current_state(TASK_INTERRUPTIBLE);
-                       if (schedule_timeout(HZ/16)) {
+                       if (msleep_interruptible(63)) {
                                up(&nodemgr_serialize);
                                goto caught_signal;
                        }
index 47de79f2179700696b21e0d23793986bd4fe60a0..935f0e1546d176109e2f18e22e0d6acb1f6273af 100644 (file)
@@ -357,8 +357,7 @@ static int sbp2util_down_timeout(atomic_t *done, int timeout)
        int i;
 
        for (i = timeout; (i > 0 && atomic_read(done) == 0); i-= HZ/10) {
-               set_current_state(TASK_INTERRUPTIBLE);
-               if (schedule_timeout(HZ/10))    /* 100ms */
+               if (msleep_interruptible(100))  /* 100ms */
                        return(1);
        }
        return ((i > 0) ? 0:1);