This is defined behaviour. On processors where gettimeofday can be
called more than once in a microsecond (SMP systems, and fast
systems), the kernel is required to keep a last-time-returned, and
increment it and return that if the value calculated is below the
stored value.
If you have the results from two gettimeofday calls, you can always
subtract them and divide by the result without checking for zero.
That's what the spec says.
A kernel will get into trouble if you keep on calling gettimeofday
more than a million times a second.....
Roger.
-- | The secret of success is sincerity. Once you can |R.E.Wolff@BitWizard.nl | fake that, you've got it made. -- Jean Giraudoux | phone: +31-15-2137555 We write Linux device drivers for any device you may have! fax: ..-2138217- 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/faq.html