From: Jorrit Herder Date: Tue, 31 May 2005 14:44:49 +0000 (+0000) Subject: *** empty log message *** X-Git-Tag: v3.1.0~794 X-Git-Url: http://zhaoyanbai.com/repos/%22/xml/v3/status/static/gitweb.js?a=commitdiff_plain;h=f0af8d85e7776f0fe047c2ed882f13d07eadf662;p=minix.git *** empty log message *** --- diff --git a/lib/utils/get_upt.c b/lib/utils/get_upt.c new file mode 100644 index 000000000..06f94179a --- /dev/null +++ b/lib/utils/get_upt.c @@ -0,0 +1,22 @@ +#include "utils.h" + +/*===========================================================================* + * getuptime * + *===========================================================================*/ +PUBLIC int getuptime(ticks) +clock_t *ticks; /* uptime in ticks */ +{ + message m; + int s; + + m.m_type = SYS_TIMES; /* request time information */ + m.T_PROC_NR = NONE; /* ignore process times */ + s = _taskcall(SYSTASK, SYS_TIMES, &m); + *ticks = m.T_BOOT_TICKS; + return(s); +} + + + + +