>I think we can instead do this:
>
> signed long timeout = HZ;
> ^^^^^^
> do {
> timeout = schedule_timeout(timeout);
> } while (timeout>0)
> ^^
Forget this example I upgraded the patch and not the example. Now we can
simply check for timeout != 0 since schedule_timeout() never return a
number < 0.
The timeout signed still make sense (but it' s not strictly needed as in
the example above).
>+ return timeout < 0 ? 0 : timeout;
Andrea Arcangeli
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/