6 #include <minix/config.h>
7 #include <minix/const.h>
19 if((r
=sys_getinfo(GET_HZ
, &Hz
, sizeof(Hz
), 0, 0)) != OK
) {
21 printf("sys_hz: can not get HZ: error %d.\nUsing default HZ = %u\n",
22 r
, (unsigned int) Hz
);
30 micros_to_ticks(u32_t micros
)
34 ticks
= (u32_t
)(((u64_t
)micros
* sys_hz()) / 1000000);
35 if(ticks
< 1) ticks
= 1;