Skip to content
Commit d9f960e9 authored by Gregory Nutt's avatar Gregory Nutt
Browse files

Fix a problem in clock_systimer64 that occurs when (1) the 64-bit system time...

Fix a problem in clock_systimer64 that occurs when (1) the 64-bit system time is enabled, and (2) the value of CONFIG_USEC_PER_TICK is less than 1 millisconds (such as when using the tickless mode of operation).  In that case, the convertion of time to 64-bit millisecond value in clock_systmer64() causes some bad times to be returned.  Time was converted to milliseconds, then to configured ticks.  Precision was lost in the millisecond convertion.

The fix is to first convert time to a 64-bit microsecond value, then to the configured tick value.

Noted by David Sidrane.
parent e7470e08
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment