summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorderaadt <deraadt@openbsd.org>2007-05-10 17:59:23 +0000
committerderaadt <deraadt@openbsd.org>2007-05-10 17:59:23 +0000
commit1c7f7befe1f7910840abee2792d84b553dc98ac3 (patch)
treede2618d569ce0a7df79df9548ddca9a64e973865
parentDon't skip channels that don't have the WDCF_IRQ_WAIT flag set. Apparently (diff)
downloadwireguard-openbsd-1c7f7befe1f7910840abee2792d84b553dc98ac3.tar.xz
wireguard-openbsd-1c7f7befe1f7910840abee2792d84b553dc98ac3.zip
evcnt & friends were replaced by a proper interrupt counting mechanism 3 years ago; ok miod
-rw-r--r--sys/arch/amd64/amd64/genassym.cf3
-rw-r--r--sys/arch/amd64/amd64/intr.c34
-rw-r--r--sys/arch/amd64/amd64/ipi.c3
-rw-r--r--sys/arch/amd64/amd64/vector.S6
-rw-r--r--sys/arch/amd64/include/cpu.h4
-rw-r--r--sys/arch/amd64/include/intr.h3
-rw-r--r--sys/arch/arm/arm/softintr.c10
-rw-r--r--sys/arch/arm/include/softintr.h3
-rw-r--r--sys/arch/armish/dev/iq80321_pci.c11
-rw-r--r--sys/arch/hppa/dev/mongoosevar.h3
-rw-r--r--sys/arch/sh/include/intr.h3
-rw-r--r--sys/arch/sh/sh/interrupt.c12
-rw-r--r--sys/arch/vax/bi/bivar.h4
-rw-r--r--sys/arch/vax/bi/if_ni.c8
-rw-r--r--sys/arch/vax/bi/kdb.c8
-rw-r--r--sys/arch/vax/mba/mbavar.h3
-rw-r--r--sys/arch/vax/qbus/if_de.c5
-rw-r--r--sys/arch/vax/vax/intvec.s4
-rw-r--r--sys/arch/vax/vax/subr.s6
-rw-r--r--sys/sys/device.h13
20 files changed, 25 insertions, 121 deletions
diff --git a/sys/arch/amd64/amd64/genassym.cf b/sys/arch/amd64/amd64/genassym.cf
index fdfbdee976d..638ea1e5ffc 100644
--- a/sys/arch/amd64/amd64/genassym.cf
+++ b/sys/arch/amd64/amd64/genassym.cf
@@ -1,4 +1,4 @@
-# $OpenBSD: genassym.cf,v 1.10 2007/05/07 19:10:31 kettenis Exp $
+# $OpenBSD: genassym.cf,v 1.11 2007/05/10 17:59:23 deraadt Exp $
# Written by Artur Grabowski art@openbsd.org, Public Domain
include <sys/param.h>
@@ -111,7 +111,6 @@ member CPU_INFO_GDT ci_gdt
struct intrsource
member is_recurse
member is_resume
-member is_evcnt
member is_handlers
member is_pic
member is_flags
diff --git a/sys/arch/amd64/amd64/intr.c b/sys/arch/amd64/amd64/intr.c
index 1d62077f8bd..c127cdbf12b 100644
--- a/sys/arch/amd64/amd64/intr.c
+++ b/sys/arch/amd64/amd64/intr.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: intr.c,v 1.13 2007/01/15 23:19:05 jsg Exp $ */
+/* $OpenBSD: intr.c,v 1.14 2007/05/10 17:59:23 deraadt Exp $ */
/* $NetBSD: intr.c,v 1.3 2003/03/03 22:16:20 fvdl Exp $ */
/*
@@ -232,10 +232,6 @@ intr_allocate_slot_cpu(struct cpu_info *ci, struct pic *pic, int pin,
memset(isp, 0, sizeof(struct intrsource));
snprintf(isp->is_evname, sizeof (isp->is_evname),
"pin %d", pin);
-#if notyet
- evcnt_attach_dynamic(&isp->is_evcnt, EVCNT_TYPE_INTR, NULL,
- pic->pic_dev.dv_xname, isp->is_evname);
-#endif
ci->ci_isources[slot] = isp;
}
simple_unlock(&ci->ci_slock);
@@ -286,10 +282,6 @@ intr_allocate_slot(struct pic *pic, int legacy_irq, int pin, int level,
snprintf(isp->is_evname, sizeof (isp->is_evname),
"pin %d", pin);
-#if notyet
- evcnt_attach_dynamic(&isp->is_evcnt, EVCNT_TYPE_INTR,
- NULL, pic->pic_dev.dv_xname, isp->is_evname);
-#endif
simple_lock(&ci->ci_slock);
ci->ci_isources[slot] = isp;
simple_unlock(&ci->ci_slock);
@@ -528,9 +520,6 @@ intr_disestablish(struct intrhand *ih)
#endif
if (source->is_handlers == NULL) {
-#if notyet
- evcnt_detach(&source->is_evcnt);
-#endif
FREE(source, M_DEVBUF);
ci->ci_isources[ih->ih_slot] = NULL;
if (pic != &i8259_pic)
@@ -582,10 +571,6 @@ cpu_intr_init(struct cpu_info *ci)
isp->is_handlers = &fake_softclock_intrhand;
isp->is_pic = &softintr_pic;
ci->ci_isources[SIR_CLOCK] = isp;
-#if notyet
- evcnt_attach_dynamic(&isp->is_evcnt, EVCNT_TYPE_INTR, NULL,
- ci->ci_dev->dv_xname, "softclock");
-#endif
MALLOC(isp, struct intrsource *, sizeof (struct intrsource), M_DEVBUF,
M_WAITOK);
if (isp == NULL)
@@ -597,10 +582,6 @@ cpu_intr_init(struct cpu_info *ci)
isp->is_handlers = &fake_softnet_intrhand;
isp->is_pic = &softintr_pic;
ci->ci_isources[SIR_NET] = isp;
-#if notyet
- evcnt_attach_dynamic(&isp->is_evcnt, EVCNT_TYPE_INTR, NULL,
- ci->ci_dev->dv_xname, "softnet");
-#endif
MALLOC(isp, struct intrsource *, sizeof (struct intrsource), M_DEVBUF,
M_WAITOK);
if (isp == NULL)
@@ -612,10 +593,6 @@ cpu_intr_init(struct cpu_info *ci)
isp->is_handlers = &fake_softserial_intrhand;
isp->is_pic = &softintr_pic;
ci->ci_isources[SIR_SERIAL] = isp;
-#if notyet
- evcnt_attach_dynamic(&isp->is_evcnt, EVCNT_TYPE_INTR, NULL,
- ci->ci_dev->dv_xname, "softserial");
-#endif
#if NLAPIC > 0
MALLOC(isp, struct intrsource *, sizeof (struct intrsource), M_DEVBUF,
M_WAITOK);
@@ -628,10 +605,6 @@ cpu_intr_init(struct cpu_info *ci)
isp->is_handlers = &fake_timer_intrhand;
isp->is_pic = &local_pic;
ci->ci_isources[LIR_TIMER] = isp;
-#if notyet
- evcnt_attach_dynamic(&isp->is_evcnt, EVCNT_TYPE_INTR, NULL,
- ci->ci_dev->dv_xname, "timer");
-#endif
#ifdef MULTIPROCESSOR
MALLOC(isp, struct intrsource *, sizeof (struct intrsource), M_DEVBUF,
M_WAITOK);
@@ -645,11 +618,6 @@ cpu_intr_init(struct cpu_info *ci)
isp->is_pic = &local_pic;
ci->ci_isources[LIR_IPI] = isp;
-#ifdef notyet
- for (i = 0; i < X86_NIPI; i++)
- evcnt_attach_dynamic(&ci->ci_ipi_events[i], EVCNT_TYPE_INTR,
- NULL, ci->ci_dev->dv_xname, x86_ipi_names[i]);
-#endif
#endif
#endif
diff --git a/sys/arch/amd64/amd64/ipi.c b/sys/arch/amd64/amd64/ipi.c
index 32dd38f8bd3..30054c80fee 100644
--- a/sys/arch/amd64/amd64/ipi.c
+++ b/sys/arch/amd64/amd64/ipi.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ipi.c,v 1.5 2006/03/10 21:21:08 brad Exp $ */
+/* $OpenBSD: ipi.c,v 1.6 2007/05/10 17:59:23 deraadt Exp $ */
/* $NetBSD: ipi.c,v 1.2 2003/03/01 13:05:37 fvdl Exp $ */
/*-
@@ -125,7 +125,6 @@ x86_ipi_handler(void)
for (bit = 0; bit < X86_NIPI && pending; bit++) {
if (pending & (1<<bit)) {
pending &= ~(1<<bit);
- ci->ci_ipi_events[bit].ev_count++;
(*ipifunc[bit])(ci);
ipi_count.ec_count++;
}
diff --git a/sys/arch/amd64/amd64/vector.S b/sys/arch/amd64/amd64/vector.S
index 60fa6215af3..e77ef0a45b7 100644
--- a/sys/arch/amd64/amd64/vector.S
+++ b/sys/arch/amd64/amd64/vector.S
@@ -1,4 +1,4 @@
-/* $OpenBSD: vector.S,v 1.7 2005/10/09 17:09:34 fgsch Exp $ */
+/* $OpenBSD: vector.S,v 1.8 2007/05/10 17:59:23 deraadt Exp $ */
/* $NetBSD: vector.S,v 1.5 2004/06/28 09:13:11 fvdl Exp $ */
/*
@@ -394,7 +394,6 @@ IDTVEC(intr_/**/name/**/num) ;\
cmpl %ebx,%r13d ;\
jae 10f /* currently masked; hold it */ ;\
incl MY_COUNT+V_INTR /* statistical info */ ;\
- incq IS_EVCNT(%r14) ;\
1: \
pushq %r13 ;\
movl %ebx,CPUVAR(ILEVEL) ;\
@@ -742,7 +741,6 @@ IDTVEC(softserial)
call _C_LABEL(x86_softintlock)
#endif
movq CPUVAR(ISOURCES) + SIR_SERIAL * 8, %r12
- incq IS_EVCNT(%r12)
movl $X86_SOFTINTR_SOFTSERIAL,%edi
call _C_LABEL(softintr_dispatch)
#ifdef MULTIPROCESSOR
@@ -759,7 +757,6 @@ IDTVEC(softnet)
call _C_LABEL(x86_softintlock)
#endif
movq CPUVAR(ISOURCES) + SIR_NET * 8, %r12
- incq IS_EVCNT(%r12)
xorq %r12,%r12
xchgl _C_LABEL(netisr),%r12d
@@ -789,7 +786,6 @@ IDTVEC(softclock)
call _C_LABEL(x86_softintlock)
#endif
movq CPUVAR(ISOURCES) + SIR_CLOCK * 8, %r12
- incq IS_EVCNT(%r12)
movl $X86_SOFTINTR_SOFTCLOCK,%edi
call _C_LABEL(softintr_dispatch)
diff --git a/sys/arch/amd64/include/cpu.h b/sys/arch/amd64/include/cpu.h
index 4d5d5c9a211..ef0bce98095 100644
--- a/sys/arch/amd64/include/cpu.h
+++ b/sys/arch/amd64/include/cpu.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: cpu.h,v 1.28 2007/05/07 19:10:31 kettenis Exp $ */
+/* $OpenBSD: cpu.h,v 1.29 2007/05/10 17:59:24 deraadt Exp $ */
/* $NetBSD: cpu.h,v 1.1 2003/04/26 18:39:39 fvdl Exp $ */
/*-
@@ -127,8 +127,6 @@ struct cpu_info {
struct x86_64_tss ci_doubleflt_tss;
char *ci_doubleflt_stack;
-
- struct evcnt ci_ipi_events[X86_NIPI];
};
#define CPUF_BSP 0x0001 /* CPU is the original BSP */
diff --git a/sys/arch/amd64/include/intr.h b/sys/arch/amd64/include/intr.h
index 0aadd1e8edf..9e4e0188241 100644
--- a/sys/arch/amd64/include/intr.h
+++ b/sys/arch/amd64/include/intr.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: intr.h,v 1.8 2007/05/06 03:37:08 gwk Exp $ */
+/* $OpenBSD: intr.h,v 1.9 2007/05/10 17:59:24 deraadt Exp $ */
/* $NetBSD: intr.h,v 1.2 2003/05/04 22:01:56 fvdl Exp $ */
/*-
@@ -78,7 +78,6 @@ struct intrsource {
struct pic *is_pic; /* originating PIC */
void *is_recurse; /* entry for spllower */
void *is_resume; /* entry for doreti */
- struct evcnt is_evcnt; /* interrupt counter */
char is_evname[32]; /* event counter name */
int is_flags; /* see below */
int is_type; /* level, edge */
diff --git a/sys/arch/arm/arm/softintr.c b/sys/arch/arm/arm/softintr.c
index 029e70b56a4..ead314a56ea 100644
--- a/sys/arch/arm/arm/softintr.c
+++ b/sys/arch/arm/arm/softintr.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: softintr.c,v 1.2 2004/02/15 17:21:30 drahn Exp $ */
+/* $OpenBSD: softintr.c,v 1.3 2007/05/10 17:59:24 deraadt Exp $ */
/* $NetBSD: softintr.c,v 1.2 2003/07/15 00:24:39 lukem Exp $ */
/*
@@ -60,19 +60,12 @@ void netintr(void);
void
softintr_init(void)
{
-#if 0
- static const char *softintr_names[] = SI_QUEUENAMES;
-#endif
struct soft_intrq *siq;
int i;
for (i = 0; i < SI_NQUEUES; i++) {
siq = &soft_intrq[i];
TAILQ_INIT(&siq->siq_list);
-#if 0
- evcnt_attach_dynamic(&siq->siq_evcnt, EVCNT_TYPE_INTR,
- NULL, "soft", softintr_names[i]);
-#endif
siq->siq_si = i;
}
@@ -97,7 +90,6 @@ softintr_dispatch(int si)
struct soft_intrhand *sih;
int oldirqstate;
- siq->siq_evcnt.ev_count++;
for (;;) {
oldirqstate = disable_interrupts(I32_bit);
sih = TAILQ_FIRST(&siq->siq_list);
diff --git a/sys/arch/arm/include/softintr.h b/sys/arch/arm/include/softintr.h
index fdd618dc841..8fde322797c 100644
--- a/sys/arch/arm/include/softintr.h
+++ b/sys/arch/arm/include/softintr.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: softintr.h,v 1.1 2004/02/01 05:09:49 drahn Exp $ */
+/* $OpenBSD: softintr.h,v 1.2 2007/05/10 17:59:24 deraadt Exp $ */
/* $NetBSD: softintr.h,v 1.1 2002/01/29 22:54:14 thorpej Exp $ */
/*
@@ -72,7 +72,6 @@ struct soft_intrhand {
struct soft_intrq {
TAILQ_HEAD(, soft_intrhand) siq_list;
- struct evcnt siq_evcnt;
int siq_si;
};
diff --git a/sys/arch/armish/dev/iq80321_pci.c b/sys/arch/armish/dev/iq80321_pci.c
index 683e0b19549..382f96f0740 100644
--- a/sys/arch/armish/dev/iq80321_pci.c
+++ b/sys/arch/armish/dev/iq80321_pci.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: iq80321_pci.c,v 1.8 2006/06/16 06:24:12 drahn Exp $ */
+/* $OpenBSD: iq80321_pci.c,v 1.9 2007/05/10 17:59:24 deraadt Exp $ */
/* $NetBSD: iq80321_pci.c,v 1.5 2005/12/11 12:17:09 christos Exp $ */
/*
@@ -57,7 +57,6 @@
int iq80321_pci_intr_map(struct pci_attach_args *, pci_intr_handle_t *);
const char *iq80321_pci_intr_string(void *, pci_intr_handle_t);
-const struct evcnt *iq80321_pci_intr_evcnt(void *, pci_intr_handle_t);
void *iq80321_pci_intr_establish(void *, pci_intr_handle_t,
int, int (*func)(void *), void *, char *);
void iq80321_pci_intr_disestablish(void *, void *);
@@ -267,14 +266,6 @@ iq80321_pci_intr_string(void *v, pci_intr_handle_t ih)
return (irqname);
}
-const struct evcnt *
-iq80321_pci_intr_evcnt(void *v, pci_intr_handle_t ih)
-{
-
- /* XXX For now. */
- return (NULL);
-}
-
void *
iq80321_pci_intr_establish(void *v, pci_intr_handle_t ih, int ipl,
int (*func)(void *), void *arg, char *name)
diff --git a/sys/arch/hppa/dev/mongoosevar.h b/sys/arch/hppa/dev/mongoosevar.h
index e512dbcd71a..87c0660545b 100644
--- a/sys/arch/hppa/dev/mongoosevar.h
+++ b/sys/arch/hppa/dev/mongoosevar.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: mongoosevar.h,v 1.1 2004/10/29 20:23:37 miod Exp $ */
+/* $OpenBSD: mongoosevar.h,v 1.2 2007/05/10 17:59:24 deraadt Exp $ */
/*
* Copyright (c) 1998-2003 Michael Shalayeff
@@ -32,7 +32,6 @@ struct hppa_isa_iv {
void *iv_arg;
int iv_pri;
- struct evcnt iv_evcnt;
/* don't do sharing, we won't have many slots anyway
struct hppa_isa_iv *iv_next;
*/
diff --git a/sys/arch/sh/include/intr.h b/sys/arch/sh/include/intr.h
index 283dc96bc60..6fdf1e7caf8 100644
--- a/sys/arch/sh/include/intr.h
+++ b/sys/arch/sh/include/intr.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: intr.h,v 1.2 2006/10/23 19:44:54 drahn Exp $ */
+/* $OpenBSD: intr.h,v 1.3 2007/05/10 17:59:26 deraadt Exp $ */
/* $NetBSD: intr.h,v 1.22 2006/01/24 23:51:42 uwe Exp $ */
/*-
@@ -108,7 +108,6 @@ struct sh_soft_intrhand {
struct sh_soft_intr {
TAILQ_HEAD(, sh_soft_intrhand) softintr_q;
- struct evcnt softintr_evcnt;
struct simplelock softintr_slock;
unsigned long softintr_ipl;
};
diff --git a/sys/arch/sh/sh/interrupt.c b/sys/arch/sh/sh/interrupt.c
index 93a557634b7..bd6dc40a4d7 100644
--- a/sys/arch/sh/sh/interrupt.c
+++ b/sys/arch/sh/sh/interrupt.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: interrupt.c,v 1.4 2006/11/05 18:58:50 miod Exp $ */
+/* $OpenBSD: interrupt.c,v 1.5 2007/05/10 17:59:26 deraadt Exp $ */
/* $NetBSD: interrupt.c,v 1.18 2006/01/25 00:02:57 uwe Exp $ */
/*-
@@ -578,9 +578,6 @@ intpri_intr_disable(int evtcode)
void
softintr_init(void)
{
-#if 0
- static const char *softintr_names[] = IPL_SOFTNAMES;
-#endif
struct sh_soft_intr *asi;
int i;
@@ -590,10 +587,6 @@ softintr_init(void)
asi->softintr_ipl = IPL_SOFT + i;
simple_lock_init(&asi->softintr_slock);
-#if 0
- evcnt_attach_dynamic(&asi->softintr_evcnt, EVCNT_TYPE_INTR,
- NULL, "soft", softintr_names[i]);
-#endif
}
/* XXX Establish legacy soft interrupt handlers. */
@@ -618,9 +611,6 @@ softintr_dispatch(int ipl)
asi = &sh_soft_intrs[ipl - IPL_SOFT];
- if (TAILQ_FIRST(&asi->softintr_q) != NULL)
- asi->softintr_evcnt.ev_count++;
-
while ((sih = TAILQ_FIRST(&asi->softintr_q)) != NULL) {
TAILQ_REMOVE(&asi->softintr_q, sih, sih_q);
sih->sih_pending = 0;
diff --git a/sys/arch/vax/bi/bivar.h b/sys/arch/vax/bi/bivar.h
index ebd21677460..06ce7375958 100644
--- a/sys/arch/vax/bi/bivar.h
+++ b/sys/arch/vax/bi/bivar.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: bivar.h,v 1.6 2002/06/11 09:36:23 hugh Exp $ */
+/* $OpenBSD: bivar.h,v 1.7 2007/05/10 17:59:26 deraadt Exp $ */
/* $NetBSD: bivar.h,v 1.8 2000/07/26 12:41:40 ragge Exp $ */
/*
* Copyright (c) 1996, 1999 Ludd, University of Lule}, Sweden.
@@ -78,4 +78,4 @@ struct bi_list {
/* Prototype */
void bi_attach (struct bi_softc *);
-void bi_intr_establish (void *, int, void (*)(void *), void *, struct evcnt *);
+void bi_intr_establish (void *, int, void (*)(void *), void *);
diff --git a/sys/arch/vax/bi/if_ni.c b/sys/arch/vax/bi/if_ni.c
index 5dc1aecfec8..29760c45872 100644
--- a/sys/arch/vax/bi/if_ni.c
+++ b/sys/arch/vax/bi/if_ni.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: if_ni.c,v 1.8 2006/03/25 22:41:41 djm Exp $ */
+/* $OpenBSD: if_ni.c,v 1.9 2007/05/10 17:59:26 deraadt Exp $ */
/* $NetBSD: if_ni.c,v 1.15 2002/05/22 16:03:14 wiz Exp $ */
/*
* Copyright (c) 2000 Ludd, University of Lule}, Sweden. All rights reserved.
@@ -119,7 +119,6 @@
struct ni_softc {
struct device sc_dev; /* Configuration common part */
- struct evcnt sc_intrcnt; /* Interrupt counting */
struct ethercom sc_ec; /* Ethernet common part */
#define sc_if sc_ec.ec_if /* network-visible interface */
bus_space_tag_t sc_iot;
@@ -246,10 +245,7 @@ niattach(parent, self, aux)
sc->sc_ioh = ba->ba_ioh;
sc->sc_dmat = ba->ba_dmat;
- bi_intr_establish(ba->ba_icookie, ba->ba_ivec,
- niintr, sc, &sc->sc_intrcnt);
- evcnt_attach_dynamic(&sc->sc_intrcnt, EVCNT_TYPE_INTR, NULL,
- sc->sc_dev.dv_xname, "intr");
+ bi_intr_establish(ba->ba_icookie, ba->ba_ivec, niintr, sc);
ni_getpgs(sc, sizeof(struct ni_gvppqb), (caddr_t *)&sc->sc_gvppqb,
(paddr_t *)&sc->sc_pgvppqb);
diff --git a/sys/arch/vax/bi/kdb.c b/sys/arch/vax/bi/kdb.c
index 2998bcac84a..6fb2415a3c5 100644
--- a/sys/arch/vax/bi/kdb.c
+++ b/sys/arch/vax/bi/kdb.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: kdb.c,v 1.9 2006/01/17 20:26:14 miod Exp $ */
+/* $OpenBSD: kdb.c,v 1.10 2007/05/10 17:59:26 deraadt Exp $ */
/* $NetBSD: kdb.c,v 1.26 2001/11/13 12:51:34 lukem Exp $ */
/*
* Copyright (c) 1996 Ludd, University of Lule}, Sweden.
@@ -76,7 +76,6 @@
*/
struct kdb_softc {
struct device sc_dev; /* Autoconfig info */
- struct evcnt sc_intrcnt; /* Interrupt counting */
caddr_t sc_kdb; /* Struct for kdb communication */
struct mscp_softc *sc_softc; /* MSCP info (per mscpvar.h) */
bus_dma_tag_t sc_dmat;
@@ -151,10 +150,7 @@ kdbattach(parent, self, aux)
bus_dma_segment_t seg;
printf("\n");
- bi_intr_establish(ba->ba_icookie, ba->ba_ivec,
- kdbintr, sc, &sc->sc_intrcnt);
- evcnt_attach_dynamic(&sc->sc_intrcnt, EVCNT_TYPE_INTR, NULL,
- sc->sc_dev.dv_xname, "intr");
+ bi_intr_establish(ba->ba_icookie, ba->ba_ivec, kdbintr, sc);
sc->sc_iot = ba->ba_iot;
sc->sc_ioh = ba->ba_ioh;
diff --git a/sys/arch/vax/mba/mbavar.h b/sys/arch/vax/mba/mbavar.h
index 0dca256e5c2..c2653f38f3e 100644
--- a/sys/arch/vax/mba/mbavar.h
+++ b/sys/arch/vax/mba/mbavar.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: mbavar.h,v 1.6 2002/06/11 09:36:24 hugh Exp $ */
+/* $OpenBSD: mbavar.h,v 1.7 2007/05/10 17:59:26 deraadt Exp $ */
/* $NetBSD: mbavar.h,v 1.7 2000/06/04 18:04:39 ragge Exp $ */
/*
* Copyright (c) 1994 Ludd, University of Lule}, Sweden
@@ -108,7 +108,6 @@ struct mba_softc {
struct device sc_dev;
bus_space_tag_t sc_iot;
bus_space_handle_t sc_ioh;
- struct evcnt sc_intrcnt;
struct mba_device *sc_first, *sc_last;
enum sc_state sc_state;
struct mba_device *sc_md[MAXMBADEV];
diff --git a/sys/arch/vax/qbus/if_de.c b/sys/arch/vax/qbus/if_de.c
index c9bad964a39..d1e69e421e4 100644
--- a/sys/arch/vax/qbus/if_de.c
+++ b/sys/arch/vax/qbus/if_de.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: if_de.c,v 1.7 2006/03/25 22:41:42 djm Exp $ */
+/* $OpenBSD: if_de.c,v 1.8 2007/05/10 17:59:26 deraadt Exp $ */
/* $NetBSD: if_de.c,v 1.11 2001/11/13 07:11:24 lukem Exp $ */
/*
@@ -112,7 +112,6 @@ struct de_cdata {
*/
struct de_softc {
struct device sc_dev; /* Configuration common part */
- struct evcnt sc_intrcnt; /* Interrupt counting */
struct ethercom sc_ec; /* Ethernet common part */
#define sc_if sc_ec.ec_if /* network-visible interface */
bus_space_tag_t sc_iot;
@@ -225,8 +224,6 @@ deattach(struct device *parent, struct device *self, void *aux)
uba_intr_establish(ua->ua_icookie, ua->ua_cvec, deintr, sc,
&sc->sc_intrcnt);
uba_reset_establish(dereset, &sc->sc_dev);
- evcnt_attach_dynamic(&sc->sc_intrcnt, EVCNT_TYPE_INTR, ua->ua_evcnt,
- sc->sc_dev.dv_xname, "intr");
strlcpy(ifp->if_xname, sc->sc_dev.dv_xname, sizeof ifp->if_xname);
ifp->if_softc = sc;
diff --git a/sys/arch/vax/vax/intvec.s b/sys/arch/vax/vax/intvec.s
index b09cd26c915..a2b569e3f23 100644
--- a/sys/arch/vax/vax/intvec.s
+++ b/sys/arch/vax/vax/intvec.s
@@ -1,4 +1,4 @@
-/* $OpenBSD: intvec.s,v 1.20 2004/12/24 22:50:31 miod Exp $ */
+/* $OpenBSD: intvec.s,v 1.21 2007/05/10 17:59:27 deraadt Exp $ */
/* $NetBSD: intvec.s,v 1.39 1999/06/28 08:20:48 itojun Exp $ */
/*
@@ -302,8 +302,6 @@ ENTRY(netint)
.globl hardclock
hardclock: mtpr $0xc1,$PR_ICCS # Reset interrupt flag
pushr $0x3f
- incl _clock_intrcnt+EC_COUNT # count the number of clock interrupts
- adwc $0,_clock_intrcnt+EC_COUNT+4
#ifdef VAX46
cmpl _vax_boardtype,$VAX_BTYP_46
bneq 1f
diff --git a/sys/arch/vax/vax/subr.s b/sys/arch/vax/vax/subr.s
index a88552f9c24..3c3e9124974 100644
--- a/sys/arch/vax/vax/subr.s
+++ b/sys/arch/vax/vax/subr.s
@@ -1,4 +1,4 @@
-/* $OpenBSD: subr.s,v 1.24 2006/11/06 21:31:37 miod Exp $ */
+/* $OpenBSD: subr.s,v 1.25 2007/05/10 17:59:27 deraadt Exp $ */
/* $NetBSD: subr.s,v 1.32 1999/03/25 00:41:48 mrg Exp $ */
/*
@@ -130,12 +130,12 @@ _idsptch: pushr $0x3f
.long _cmn_idsptch # the absolute address
.long 0 # the callback interrupt routine
.long 0 # its argument
- .long 0 # ptr to correspond evcnt struct
+ .long 0 # ptr to correspond evcount struct
_eidsptch:
_cmn_idsptch:
movl (sp)+,r0 # get pointer to idspvec
- movl 8(r0),r1 # get evcnt pointer
+ movl 8(r0),r1 # get evcount pointer
beql 1f # no ptr, skip increment
incl EC_COUNT(r1) # increment low longword
adwc $0,EC_COUNT+4(r1) # add any carry to hi longword
diff --git a/sys/sys/device.h b/sys/sys/device.h
index d59f3d2e23b..026b5dedb45 100644
--- a/sys/sys/device.h
+++ b/sys/sys/device.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: device.h,v 1.34 2007/05/04 19:30:55 deraadt Exp $ */
+/* $OpenBSD: device.h,v 1.35 2007/05/10 17:59:27 deraadt Exp $ */
/* $NetBSD: device.h,v 1.15 1996/04/09 20:55:24 cgd Exp $ */
/*
@@ -85,15 +85,6 @@ struct device {
TAILQ_HEAD(devicelist, device);
-/* `event' counters (use zero or more per device instance, as needed) */
-struct evcnt {
- TAILQ_ENTRY(evcnt) ev_list; /* entry on list of all counters */
- struct device *ev_dev; /* associated device */
- int ev_count; /* how many have occurred */
- char ev_name[8]; /* what to call them (systat display) */
-};
-TAILQ_HEAD(evcntlist, evcnt);
-
/*
* Configuration data (i.e., data placed in ioconf.c).
*/
@@ -181,7 +172,6 @@ struct cftable {
TAILQ_HEAD(cftable_head, cftable);
extern struct devicelist alldevs; /* list of all devices */
-extern struct evcntlist allevents; /* list of all event counters */
extern int autoconf_verbose;
extern __volatile int config_pending; /* semaphore for mountroot */
@@ -202,7 +192,6 @@ int config_activate_children(struct device *, enum devact);
struct device *config_make_softc(struct device *parent,
struct cfdata *cf);
void config_defer(struct device *, void (*)(struct device *));
-void evcnt_attach(struct device *, const char *, struct evcnt *);
void config_pending_incr(void);
void config_pending_decr(void);