[patch 3/9] block/cciss: replace schedule_timeout() with msleep_interruptible()

From: janitor
Date: Thu Sep 23 2004 - 20:51:31 EST





Any comments would be appreciated. This is a re-push of a patch I
submitted 19 July which hasn't been merged as of
2.6.9-rc1-mm5/2.6.9-rc2.

Description: msleep_interruptible() is used instead of schedule_timeout()
to guarantee the task delays as expected.

Signed-off-by: Nishanth Aravamudan <nacc@xxxxxxxxxx>

Signed-off-by: Maximilian Attems <janitor@xxxxxxxxxxxxxx>
---

linux-2.6.9-rc2-bk7-max/drivers/block/cciss.c | 3 +--
1 files changed, 1 insertion(+), 2 deletions(-)

diff -puN drivers/block/cciss.c~msleep_interruptible-drivers_block_cciss drivers/block/cciss.c
--- linux-2.6.9-rc2-bk7/drivers/block/cciss.c~msleep_interruptible-drivers_block_cciss 2004-09-21 21:07:51.000000000 +0200
+++ linux-2.6.9-rc2-bk7-max/drivers/block/cciss.c 2004-09-21 21:07:51.000000000 +0200
@@ -2381,8 +2381,7 @@ static int cciss_pci_init(ctlr_info_t *c
scratchpad = readl(c->vaddr + SA5_SCRATCHPAD_OFFSET);
if (scratchpad == CCISS_FIRMWARE_READY)
break;
- set_current_state(TASK_INTERRUPTIBLE);
- schedule_timeout(HZ / 10); /* wait 100ms */
+ msleep_interruptible(100);
}
if (scratchpad != CCISS_FIRMWARE_READY) {
printk(KERN_WARNING "cciss: Board not ready. Timed out.\n");
_
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/