diff options
author | jhb <jhb@FreeBSD.org> | 2008-08-19 21:30:36 +0000 |
---|---|---|
committer | jhb <jhb@FreeBSD.org> | 2008-08-19 21:30:36 +0000 |
commit | 67b02c52de29cfb44eea11a7c46f7bf5de57bf36 (patch) | |
tree | 46a6b9c4299efa74349c2c72fe125414690cb591 /lib/libkvm/Makefile | |
parent | 10e058a3a20b6ed4f8c0fe21dbadb75ad69ff6b7 (diff) | |
download | FreeBSD-src-67b02c52de29cfb44eea11a7c46f7bf5de57bf36.zip FreeBSD-src-67b02c52de29cfb44eea11a7c46f7bf5de57bf36.tar.gz |
Add a new routine kvm_getcptime(3) for fetching the equivalent of
'kern.cp_time'. For a live kernel it uses the sysctl. For a crashdump,
it first checks to see if the kernel has a 'cp_time' global symbol. If
it does, it uses that. If that doesn't work, when it uses the recently
added kvm_getmaxcpu(3) and kvm_getpcpu(3) routines to walk all the CPUs
and sum up their counters.
MFC after: 1 week
Diffstat (limited to 'lib/libkvm/Makefile')
-rw-r--r-- | lib/libkvm/Makefile | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/lib/libkvm/Makefile b/lib/libkvm/Makefile index 1204217..3ca8427 100644 --- a/lib/libkvm/Makefile +++ b/lib/libkvm/Makefile @@ -9,15 +9,16 @@ CFLAGS+=-DLIBC_SCCS -I${.CURDIR} CFLAGS+=-DSUN4V .endif -SRCS= kvm.c kvm_${MACHINE_ARCH}.c kvm_file.c kvm_getloadavg.c \ +SRCS= kvm.c kvm_${MACHINE_ARCH}.c kvm_cptime.c kvm_file.c kvm_getloadavg.c \ kvm_getswapinfo.c kvm_pcpu.c kvm_proc.c .if ${MACHINE_ARCH} == "amd64" || ${MACHINE_ARCH} == "i386" SRCS+= kvm_minidump_${MACHINE_ARCH}.c .endif INCS= kvm.h -MAN= kvm.3 kvm_geterr.3 kvm_getfiles.3 kvm_getloadavg.3 kvm_getpcpu.3 \ - kvm_getprocs.3 kvm_getswapinfo.3 kvm_nlist.3 kvm_open.3 +MAN= kvm.3 kvm_getcptime.3 kvm_geterr.3 kvm_getfiles.3 kvm_getloadavg.3 \ + kvm_getpcpu.3 kvm_getprocs.3 kvm_getswapinfo.3 kvm_nlist.3 kvm_open.3 \ + kvm_read.3 MLINKS+=kvm_getpcpu.3 kvm_getmaxcpu.3 MLINKS+=kvm_getprocs.3 kvm_getargv.3 kvm_getprocs.3 kvm_getenvv.3 |