diff options
Diffstat (limited to 'sys')
-rw-r--r-- | sys/arch/alpha/include/types.h | 3 | ||||
-rw-r--r-- | sys/arch/amd64/include/types.h | 3 | ||||
-rw-r--r-- | sys/arch/arm/include/types.h | 3 | ||||
-rw-r--r-- | sys/arch/hp300/include/types.h | 3 | ||||
-rw-r--r-- | sys/arch/hppa/include/types.h | 3 | ||||
-rw-r--r-- | sys/arch/i386/include/types.h | 3 | ||||
-rw-r--r-- | sys/arch/m88k/include/types.h | 4 | ||||
-rw-r--r-- | sys/arch/mips64/include/types.h | 3 | ||||
-rw-r--r-- | sys/arch/mvme68k/include/types.h | 4 | ||||
-rw-r--r-- | sys/arch/powerpc/include/types.h | 4 | ||||
-rw-r--r-- | sys/arch/sparc/include/types.h | 4 | ||||
-rw-r--r-- | sys/arch/sparc64/include/types.h | 3 | ||||
-rw-r--r-- | sys/arch/vax/include/types.h | 3 | ||||
-rw-r--r-- | sys/kern/kern_sysctl.c | 44 | ||||
-rw-r--r-- | sys/kern/subr_evcount.c | 6 |
15 files changed, 15 insertions, 78 deletions
diff --git a/sys/arch/alpha/include/types.h b/sys/arch/alpha/include/types.h index 00f205d85c6..4d199673f2e 100644 --- a/sys/arch/alpha/include/types.h +++ b/sys/arch/alpha/include/types.h @@ -1,4 +1,4 @@ -/* $OpenBSD: types.h,v 1.14 2004/11/02 21:20:58 miod Exp $ */ +/* $OpenBSD: types.h,v 1.15 2004/11/26 21:23:03 miod Exp $ */ /* $NetBSD: types.h,v 1.6 1996/12/05 00:13:47 cgd Exp $ */ /*- @@ -73,6 +73,5 @@ typedef long register_t; #define __BROKEN_INDIRECT_CONFIG #define __HAVE_DEVICE_REGISTER -#define __HAVE_EVCOUNT #endif /* _MACHTYPES_H_ */ diff --git a/sys/arch/amd64/include/types.h b/sys/arch/amd64/include/types.h index 5cf8dfc72f6..b51734f476b 100644 --- a/sys/arch/amd64/include/types.h +++ b/sys/arch/amd64/include/types.h @@ -1,4 +1,4 @@ -/* $OpenBSD: types.h,v 1.6 2004/11/02 21:20:59 miod Exp $ */ +/* $OpenBSD: types.h,v 1.7 2004/11/26 21:23:04 miod Exp $ */ /*- * Copyright (c) 1990 The Regents of the University of California. @@ -69,7 +69,6 @@ typedef long register_t; #define __HAVE_GENERIC_SOFT_INTERRUPTS #define __HAVE_CPUINFO -#define __HAVE_EVCOUNT #define __HAVE_MUTEX #endif /* _MACHTYPES_H_ */ diff --git a/sys/arch/arm/include/types.h b/sys/arch/arm/include/types.h index efe1f03647c..38fb6218272 100644 --- a/sys/arch/arm/include/types.h +++ b/sys/arch/arm/include/types.h @@ -1,4 +1,4 @@ -/* $OpenBSD: types.h,v 1.2 2004/08/06 19:29:10 drahn Exp $ */ +/* $OpenBSD: types.h,v 1.3 2004/11/26 21:23:04 miod Exp $ */ /* $NetBSD: types.h,v 1.4 2002/02/28 03:17:25 simonb Exp $ */ /* @@ -64,7 +64,6 @@ typedef vm_size_t vsize_t; #endif #define __HAVE_MINIMAL_EMUL -#define __HAVE_EVCOUNT /* * Basic integral types. Omit the typedef if diff --git a/sys/arch/hp300/include/types.h b/sys/arch/hp300/include/types.h index 36b6de4792e..e5d87f9fa78 100644 --- a/sys/arch/hp300/include/types.h +++ b/sys/arch/hp300/include/types.h @@ -1,4 +1,4 @@ -/* $OpenBSD: types.h,v 1.4 2004/09/29 07:35:54 miod Exp $ */ +/* $OpenBSD: types.h,v 1.5 2004/11/26 21:23:04 miod Exp $ */ /* $NetBSD: types.h,v 1.8 1996/12/17 08:11:50 thorpej Exp $ */ #ifndef _MACHINE_TYPES_H_ @@ -7,6 +7,5 @@ #include <m68k/types.h> #define __HAVE_DEVICE_REGISTER -#define __HAVE_EVCOUNT #endif diff --git a/sys/arch/hppa/include/types.h b/sys/arch/hppa/include/types.h index f287ba9f068..7f5eb5ba8aa 100644 --- a/sys/arch/hppa/include/types.h +++ b/sys/arch/hppa/include/types.h @@ -1,4 +1,4 @@ -/* $OpenBSD: types.h,v 1.10 2004/06/30 21:01:08 mickey Exp $ */ +/* $OpenBSD: types.h,v 1.11 2004/11/26 21:23:05 miod Exp $ */ /*- * Copyright (c) 1990, 1993 @@ -83,6 +83,5 @@ typedef unsigned long uint64_t; typedef int32_t register_t; #define __HAVE_DEVICE_REGISTER -#define __HAVE_EVCOUNT #endif /* _MACHINE_TYPES_H_ */ diff --git a/sys/arch/i386/include/types.h b/sys/arch/i386/include/types.h index f280ad6a9cf..05449d122b8 100644 --- a/sys/arch/i386/include/types.h +++ b/sys/arch/i386/include/types.h @@ -1,5 +1,5 @@ /* $NetBSD: types.h,v 1.12 1995/12/24 01:08:03 mycroft Exp $ */ -/* $OpenBSD: types.h,v 1.17 2004/11/02 21:20:59 miod Exp $ */ +/* $OpenBSD: types.h,v 1.18 2004/11/26 21:23:05 miod Exp $ */ /*- * Copyright (c) 1990 The Regents of the University of California. @@ -71,7 +71,6 @@ typedef unsigned long long uint64_t; typedef int32_t register_t; -#define __HAVE_EVCOUNT #define __HAVE_CPUINFO #define __HAVE_MUTEX diff --git a/sys/arch/m88k/include/types.h b/sys/arch/m88k/include/types.h index ca32e668798..25dc0d1dc0d 100644 --- a/sys/arch/m88k/include/types.h +++ b/sys/arch/m88k/include/types.h @@ -1,5 +1,5 @@ /* $NetBSD: types.h,v 1.7 1995/07/05 17:46:11 pk Exp $ */ -/* $OpenBSD: types.h,v 1.2 2004/07/02 14:00:38 miod Exp $ */ +/* $OpenBSD: types.h,v 1.3 2004/11/26 21:23:05 miod Exp $ */ /* * Copyright (c) 1992, 1993 @@ -77,6 +77,4 @@ typedef unsigned long long uint64_t; typedef int32_t register_t; -#define __HAVE_EVCOUNT - #endif /* _M88K_TYPES_H_ */ diff --git a/sys/arch/mips64/include/types.h b/sys/arch/mips64/include/types.h index 33f53a9bcc7..9446daa1889 100644 --- a/sys/arch/mips64/include/types.h +++ b/sys/arch/mips64/include/types.h @@ -1,4 +1,4 @@ -/* $OpenBSD: types.h,v 1.4 2004/09/24 14:22:49 deraadt Exp $ */ +/* $OpenBSD: types.h,v 1.5 2004/11/26 21:23:05 miod Exp $ */ /*- * Copyright (c) 1992, 1993 @@ -93,6 +93,5 @@ typedef struct label_t { /* XXX check why this still has to be defined. pmap.c issue? */ #define __SWAP_BROKEN -#define __HAVE_EVCOUNT #endif /* !_MIPS_TYPES_H_ */ diff --git a/sys/arch/mvme68k/include/types.h b/sys/arch/mvme68k/include/types.h index be742115858..18a9df75115 100644 --- a/sys/arch/mvme68k/include/types.h +++ b/sys/arch/mvme68k/include/types.h @@ -1,5 +1,3 @@ -/* $OpenBSD: types.h,v 1.6 2004/07/30 09:50:17 miod Exp $ */ +/* $OpenBSD: types.h,v 1.7 2004/11/26 21:23:05 miod Exp $ */ #include <m68k/types.h> - -#define __HAVE_EVCOUNT diff --git a/sys/arch/powerpc/include/types.h b/sys/arch/powerpc/include/types.h index d92e17ddbe3..e2782605670 100644 --- a/sys/arch/powerpc/include/types.h +++ b/sys/arch/powerpc/include/types.h @@ -1,5 +1,5 @@ /* $NetBSD: types.h,v 1.1 1996/09/30 16:34:36 ws Exp $ */ -/* $OpenBSD: types.h,v 1.13 2004/06/28 02:49:10 aaron Exp $ */ +/* $OpenBSD: types.h,v 1.14 2004/11/26 21:23:05 miod Exp $ */ /*- * Copyright (C) 1995 Wolfgang Solfrank. @@ -67,6 +67,4 @@ typedef struct label_t { #define __BROKEN_INDIRECT_CONFIG -#define __HAVE_EVCOUNT - #endif /* _POWERPC_TYPES_H_ */ diff --git a/sys/arch/sparc/include/types.h b/sys/arch/sparc/include/types.h index 49aed91e298..4b69daefe1e 100644 --- a/sys/arch/sparc/include/types.h +++ b/sys/arch/sparc/include/types.h @@ -1,4 +1,4 @@ -/* $OpenBSD: types.h,v 1.15 2004/09/29 07:35:13 miod Exp $ */ +/* $OpenBSD: types.h,v 1.16 2004/11/26 21:23:05 miod Exp $ */ /* $NetBSD: types.h,v 1.11 1996/12/10 23:19:38 pk Exp $ */ /* @@ -77,6 +77,4 @@ typedef unsigned long long uint64_t; typedef int32_t register_t; -#define __HAVE_EVCOUNT - #endif /* _MACHTYPES_H_ */ diff --git a/sys/arch/sparc64/include/types.h b/sys/arch/sparc64/include/types.h index cfb53ca1831..9952385e6b4 100644 --- a/sys/arch/sparc64/include/types.h +++ b/sys/arch/sparc64/include/types.h @@ -1,4 +1,4 @@ -/* $OpenBSD: types.h,v 1.8 2004/11/02 21:20:59 miod Exp $ */ +/* $OpenBSD: types.h,v 1.9 2004/11/26 21:23:06 miod Exp $ */ /* $NetBSD: types.h,v 1.17 2001/05/12 22:42:07 kleink Exp $ */ /* @@ -67,6 +67,5 @@ typedef paddr_t psize_t; #define __HAVE_DEVICE_REGISTER #define __HAVE_GENERIC_SOFT_INTERRUPTS -#define __HAVE_EVCOUNT #endif /* _MACHTYPES_H_ */ diff --git a/sys/arch/vax/include/types.h b/sys/arch/vax/include/types.h index 8d16a7246b8..448661fd32d 100644 --- a/sys/arch/vax/include/types.h +++ b/sys/arch/vax/include/types.h @@ -1,4 +1,4 @@ -/* $OpenBSD: types.h,v 1.13 2004/07/07 23:10:45 deraadt Exp $ */ +/* $OpenBSD: types.h,v 1.14 2004/11/26 21:23:06 miod Exp $ */ /* $NetBSD: types.h,v 1.14 1998/08/13 02:10:49 eeh Exp $ */ /*- @@ -74,6 +74,5 @@ typedef unsigned long long u_int64_t; typedef int32_t register_t; #define __HAVE_DEVICE_REGISTER -#define __HAVE_EVCOUNT #endif /* _MACHTYPES_H_ */ diff --git a/sys/kern/kern_sysctl.c b/sys/kern/kern_sysctl.c index 8daac01f67a..c3215ed5d7f 100644 --- a/sys/kern/kern_sysctl.c +++ b/sys/kern/kern_sysctl.c @@ -1,4 +1,4 @@ -/* $OpenBSD: kern_sysctl.c,v 1.121 2004/10/14 17:10:17 mickey Exp $ */ +/* $OpenBSD: kern_sysctl.c,v 1.122 2004/11/26 21:23:06 miod Exp $ */ /* $NetBSD: kern_sysctl.c,v 1.17 1996/05/20 17:49:05 mrg Exp $ */ /*- @@ -65,9 +65,7 @@ #ifdef __HAVE_TIMECOUNTER #include <sys/timetc.h> #endif -#ifdef __HAVE_EVCOUNT #include <sys/evcount.h> -#endif #include <sys/mount.h> #include <sys/syscallargs.h> @@ -285,9 +283,7 @@ kern_sysctl(name, namelen, oldp, oldlenp, newp, newlen, p) case KERN_INTRCNT: case KERN_WATCHDOG: case KERN_EMUL: -#ifdef __HAVE_EVCOUNT case KERN_EVCOUNT: -#endif #ifdef __HAVE_TIMECOUNTER case KERN_TIMECOUNTER: #endif @@ -529,11 +525,9 @@ kern_sysctl(name, namelen, oldp, oldlenp, newp, newlen, p) if (!error) nmbclust_update(); return (error); -#ifdef __HAVE_EVCOUNT case KERN_EVCOUNT: return (evcount_sysctl(name + 1, namelen - 1, oldp, oldlenp, newp, newlen)); -#endif #ifdef __HAVE_TIMECOUNTER case KERN_TIMECOUNTER: return (sysctl_tc(name + 1, namelen - 1, oldp, oldlenp, @@ -1784,43 +1778,7 @@ sysctl_sysvipc(name, namelen, where, sizep) int sysctl_intrcnt(int *name, u_int namelen, void *oldp, size_t *oldlenp) { -#ifdef __HAVE_EVCOUNT return (evcount_sysctl(name, namelen, oldp, oldlenp, NULL, 0)); -#else - extern int intrcnt[], eintrcnt[]; - extern char intrnames[], eintrnames[]; - char *intrname; - int nintr, i; - - nintr = (off_t)(eintrcnt - intrcnt); - - if (name[0] != KERN_INTRCNT_NUM) { - if (namelen != 2) - return (ENOTDIR); - if (name[1] < 0 || name[1] >= nintr) - return (EINVAL); - i = name[1]; - } - - switch (name[0]) { - case KERN_INTRCNT_NUM: - return (sysctl_rdint(oldp, oldlenp, NULL, nintr)); - break; - case KERN_INTRCNT_CNT: - return (sysctl_rdquad(oldp, oldlenp, NULL, intrcnt[i])); - case KERN_INTRCNT_NAME: - intrname = intrnames; - while (i > 0) { - intrname += strlen(intrname) + 1; - i--; - if (intrname > eintrnames) - return (EINVAL); - } - return (sysctl_rdstring(oldp, oldlenp, NULL, intrname)); - default: - return (EOPNOTSUPP); - } -#endif } int nsensors = 0; diff --git a/sys/kern/subr_evcount.c b/sys/kern/subr_evcount.c index 3b0ca7223b3..76fe02019aa 100644 --- a/sys/kern/subr_evcount.c +++ b/sys/kern/subr_evcount.c @@ -1,4 +1,4 @@ -/* $OpenBSD: subr_evcount.c,v 1.4 2004/09/29 07:37:04 miod Exp $ */ +/* $OpenBSD: subr_evcount.c,v 1.5 2004/11/26 21:23:06 miod Exp $ */ /* * Copyright (c) 2004 Artur Grabowski <art@openbsd.org> * Copyright (c) 2004 Aaron Campbell <aaron@openbsd.org> @@ -32,8 +32,6 @@ #include <sys/systm.h> #include <sys/sysctl.h> -#ifdef __HAVE_EVCOUNT - static TAILQ_HEAD(,evcount) evcount_list; static struct evcount *evcount_next_sync; @@ -149,5 +147,3 @@ evcount_sysctl(name, namelen, oldp, oldlenp, newp, newlen) return (error); } - -#endif /* __HAVE_EVCOUNT */ |