source: trunk/minix/lib/sysutil/getuptime.c@ 20

Last change on this file since 20 was 9, checked in by Mattia Monga, 14 years ago

Minix 3.1.2a

File size: 539 bytes
Line 
1#include "sysutil.h"
2
3/*===========================================================================*
4 * getuptime *
5 *===========================================================================*/
6PUBLIC int getuptime(ticks)
7clock_t *ticks; /* uptime in ticks */
8{
9 message m;
10 int s;
11
12 m.m_type = SYS_TIMES; /* request time information */
13 m.T_ENDPT = NONE; /* ignore process times */
14 s = _taskcall(SYSTASK, SYS_TIMES, &m);
15 *ticks = m.T_BOOT_TICKS;
16 return(s);
17}
18
19
20
21
22
Note: See TracBrowser for help on using the repository browser.