avoid overflows in kernel/time.c