I would appreciate any comments from the janitors list. This is one (of
a few) places where I had to make a decision to set the state before the
call to
schedule_timeout();
This of course affected any decision to replace the code with msleep()
or not. Please inform if the other state from the one I used is desired.
Thanks,
Nish
Applys-to: 2.6.7
Description: Uses msleep() instead of schedule_timeout() to guarantee
the task delays the requested time.
Signed-off-by: Nishanth Aravamudan <nacc@xxxxxxxxxx>
--- linux-vanilla/drivers/i2c/busses/scx200_acb.c 2004-06-16
05:19:23.000000000 +0000
+++ linux-dev/drivers/i2c/busses/scx200_acb.c 2004-07-21 16:55:39.000000000
+0000
@@ -32,6 +32,7 @@
#include <linux/i2c.h>
#include <linux/smp_lock.h>
#include <linux/pci.h>
+#include <linux/delay.h>
#include <asm/io.h>
#include <linux/scx200.h>
@@ -254,7 +255,7 @@ static void scx200_acb_poll(struct scx20
scx200_acb_machine(iface, status);
return;
}
- schedule_timeout(HZ/100+1);
+ msleep(10); /* sleep 10ms */
}
scx200_acb_timeout(iface);
_______________________________________________
Kernel-janitors mailing list
Kernel-janitors@xxxxxxxxxxxxxx
http://lists.osdl.org/mailman/listinfo/kernel-janitors
|