-
- Downloads
clock: Use new clock APIs in BSD time functions
Reimplement the BSD functions getmicrotime(9), getmicrouptime(9) and variable "ticks", using the new clock APIs. getmicrotime() returns the system time ("wall clock"), while getmicrouptime and ticks return the time since boot. I believe this is the correct implementation according to the FreeBSD documentation, but our previous implementation didn't quite do this and it also worked ;-) The previous implementation pretended, according to getmicrouptime() and get_ticks(), that the system is up since 1970, and yet the variable "time_uptime" (which FreeBSD has) is never updated, and is fixed at 1 second :-) Reviewed-by:Glauber Costa <glommer@cloudius-systems.com> Signed-off-by:
Nadav Har'El <nyh@cloudius-systems.com> Signed-off-by:
Pekka Enberg <penberg@cloudius-systems.com>
Loading
Please register or sign in to comment