Make delay values unsigned
There is no reason for negative delays in our use cases:
- We don't need it (to work around any quirks).
- sleep() (POSIX) uses an unsigned argument.
- usleep() (POSIX) uses an unsigned argument.
- Sleep() (Windows) uses an unsigned argument.
Change all callees as well (without any complications).
Corresponding to flashrom svn r1782.
Signed-off-by: Stefan Tauner <stefan.tauner@alumni.tuwien.ac.at>
Acked-by: Stefan Tauner <stefan.tauner@alumni.tuwien.ac.at>
diff --git a/flashrom.c b/flashrom.c
index 092572e..23728f6 100644
--- a/flashrom.c
+++ b/flashrom.c
@@ -485,7 +485,7 @@
flash->pgm->par.chip_readn(flash, buf, addr, len);
}
-void programmer_delay(int usecs)
+void programmer_delay(unsigned int usecs)
{
if (usecs > 0)
programmer_table[programmer].delay(usecs);