diff options
| author | Vito Caputo <vcaputo@pengaru.com> | 2021-09-09 19:25:41 -0700 | 
|---|---|---|
| committer | Vito Caputo <vcaputo@pengaru.com> | 2021-09-09 19:40:15 -0700 | 
| commit | b2d4629d1776dbdef9924a0ded29e733de150ccc (patch) | |
| tree | dffbd58a579ec25081b60cb61dc3b6a8cf2ddc09 /src/libvmon/vmon.h | |
| parent | eac2122b04b68f4abf09d2584f96c8fd8c67a144 (diff) | |
lbvmon: expose clock_gettime(CLOCK_BOOTTIME)
Exposed as VMON_SYS_STAT_BOOTTIME, so part of VMON_WANT_SYS_STAT,
in units of ticks to normalize with SYS_STAT_CPU* times.
This also introduces vmon->ticks_per_sec, which callers can access
as well for convenience since vmon_t is all public and this library
doesn't aspire to keep anything private.  It's initialized via
sysconf(_SC_CLK_TCK) @ vmon_init().
Diffstat (limited to 'src/libvmon/vmon.h')
| -rw-r--r-- | src/libvmon/vmon.h | 1 | 
1 files changed, 1 insertions, 0 deletions
| diff --git a/src/libvmon/vmon.h b/src/libvmon/vmon.h index 56c7b56..cefcb43 100644 --- a/src/libvmon/vmon.h +++ b/src/libvmon/vmon.h @@ -276,6 +276,7 @@ typedef struct _vmon_t {  	vmon_flags_t		flags;				/* instance flags */  	vmon_sys_wants_t	sys_wants;			/* system-wide wants mask */  	vmon_proc_wants_t	proc_wants;			/* inherited per-process wants mask */ +	long			ticks_per_sec;			/* sysconf(_SC_CLK_TCK) */  								/* function tables for mapping of wants bits to functions (sys-wide and per-process) */  	int			(*sys_funcs[VMON_STORE_SYS_NR])(struct _vmon_t *, void **); | 
