summaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
authorMiod Vallat <miod@cvs.openbsd.org>2007-11-06 18:20:08 +0000
committerMiod Vallat <miod@cvs.openbsd.org>2007-11-06 18:20:08 +0000
commitdd838b51078f756afaa734f2538934eeb5e37f9c (patch)
tree789e2f69556f57c26d8f5eb4c57a89129d1759ea /sys
parentdf76969fb647e534e79ce275cca3c4c643905d7c (diff)
Get rid of TC_IPL_xxx values and tc_intrlevel_t, and use IPL_xxx and int.
No functional change.
Diffstat (limited to 'sys')
-rw-r--r--sys/arch/alpha/tc/cfb.c4
-rw-r--r--sys/arch/alpha/tc/ioasic.c6
-rw-r--r--sys/arch/alpha/tc/scc.c4
-rw-r--r--sys/arch/alpha/tc/tc_3000_300.c4
-rw-r--r--sys/arch/alpha/tc/tc_3000_500.c6
-rw-r--r--sys/arch/alpha/tc/tc_conf.h6
-rw-r--r--sys/dev/tc/if_fta.c4
-rw-r--r--sys/dev/tc/if_le_ioasic.c4
-rw-r--r--sys/dev/tc/if_le_tc.c4
-rw-r--r--sys/dev/tc/tcds.c4
-rw-r--r--sys/dev/tc/tcvar.h22
11 files changed, 24 insertions, 44 deletions
diff --git a/sys/arch/alpha/tc/cfb.c b/sys/arch/alpha/tc/cfb.c
index fd9f4eb7280..f99dc77252e 100644
--- a/sys/arch/alpha/tc/cfb.c
+++ b/sys/arch/alpha/tc/cfb.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: cfb.c,v 1.18 2006/11/29 12:13:51 miod Exp $ */
+/* $OpenBSD: cfb.c,v 1.19 2007/11/06 18:20:05 miod Exp $ */
/* $NetBSD: cfb.c,v 1.7 1996/12/05 01:39:39 cgd Exp $ */
/*
@@ -219,7 +219,7 @@ cfbattach(parent, self, aux)
sc->sc_dc->dc_depth);
/* Establish an interrupt handler, and clear any pending interrupts */
- tc_intr_establish(parent, ta->ta_cookie, TC_IPL_TTY, cfbintr, sc);
+ tc_intr_establish(parent, ta->ta_cookie, IPL_TTY, cfbintr, sc);
*(volatile u_int32_t *)(sc->sc_dc->dc_vaddr + CFB_IREQCTRL_OFFSET) = 0;
/* initialize the raster */
diff --git a/sys/arch/alpha/tc/ioasic.c b/sys/arch/alpha/tc/ioasic.c
index ae84d535e64..c8452a13eb3 100644
--- a/sys/arch/alpha/tc/ioasic.c
+++ b/sys/arch/alpha/tc/ioasic.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ioasic.c,v 1.12 2006/03/04 12:33:17 miod Exp $ */
+/* $OpenBSD: ioasic.c,v 1.13 2007/11/06 18:20:05 miod Exp $ */
/* $NetBSD: ioasic.c,v 1.34 2000/07/18 06:10:06 thorpej Exp $ */
/*-
@@ -207,7 +207,7 @@ ioasicattach(parent, self, aux)
evcount_attach(&ioasicintrs[i].iai_count,
ioasicintrs[i].iai_name, NULL, &evcount_intr);
}
- tc_intr_establish(parent, ta->ta_cookie, TC_IPL_NONE, ioasic_intr, sc);
+ tc_intr_establish(parent, ta->ta_cookie, IPL_NONE, ioasic_intr, sc);
/*
* Try to configure each device.
@@ -219,7 +219,7 @@ void
ioasic_intr_establish(ioa, cookie, level, func, arg)
struct device *ioa;
void *cookie, *arg;
- tc_intrlevel_t level;
+ int level;
int (*func)(void *);
{
struct ioasic_softc *sc = (void *)ioasic_cd.cd_devs[0];
diff --git a/sys/arch/alpha/tc/scc.c b/sys/arch/alpha/tc/scc.c
index 00aa9a6b1e2..335a0dea65c 100644
--- a/sys/arch/alpha/tc/scc.c
+++ b/sys/arch/alpha/tc/scc.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: scc.c,v 1.20 2004/09/19 21:34:42 mickey Exp $ */
+/* $OpenBSD: scc.c,v 1.21 2007/11/06 18:20:05 miod Exp $ */
/* $NetBSD: scc.c,v 1.58 2002/03/17 19:40:27 atatat Exp $ */
/*
@@ -309,7 +309,7 @@ sccattach(parent, self, aux)
#endif
/* Register the interrupt handler. */
- ioasic_intr_establish(parent, d->iada_cookie, TC_IPL_TTY,
+ ioasic_intr_establish(parent, d->iada_cookie, IPL_TTY,
sccintr, (void *)sc);
/*
diff --git a/sys/arch/alpha/tc/tc_3000_300.c b/sys/arch/alpha/tc/tc_3000_300.c
index fe6940fa6f9..8260f51a230 100644
--- a/sys/arch/alpha/tc/tc_3000_300.c
+++ b/sys/arch/alpha/tc/tc_3000_300.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: tc_3000_300.c,v 1.12 2006/03/04 12:33:17 miod Exp $ */
+/* $OpenBSD: tc_3000_300.c,v 1.13 2007/11/06 18:20:05 miod Exp $ */
/* $NetBSD: tc_3000_300.c,v 1.26 2001/07/27 00:25:21 thorpej Exp $ */
/*
@@ -117,7 +117,7 @@ void
tc_3000_300_intr_establish(tcadev, cookie, level, func, arg)
struct device *tcadev;
void *cookie, *arg;
- tc_intrlevel_t level;
+ int level;
int (*func)(void *);
{
volatile u_int32_t *imskp;
diff --git a/sys/arch/alpha/tc/tc_3000_500.c b/sys/arch/alpha/tc/tc_3000_500.c
index 10b7807f481..d82ec73b8e9 100644
--- a/sys/arch/alpha/tc/tc_3000_500.c
+++ b/sys/arch/alpha/tc/tc_3000_500.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: tc_3000_500.c,v 1.13 2006/03/04 12:33:17 miod Exp $ */
+/* $OpenBSD: tc_3000_500.c,v 1.14 2007/11/06 18:20:05 miod Exp $ */
/* $NetBSD: tc_3000_500.c,v 1.24 2001/07/27 00:25:21 thorpej Exp $ */
/*
@@ -50,7 +50,7 @@ extern int sfb_cnattach(tc_addr_t);
void tc_3000_500_intr_setup(void);
void tc_3000_500_intr_establish(struct device *, void *,
- tc_intrlevel_t, int (*)(void *), void *);
+ int, int (*)(void *), void *);
void tc_3000_500_intr_disestablish(struct device *, void *);
void tc_3000_500_iointr(void *, unsigned long);
@@ -141,7 +141,7 @@ void
tc_3000_500_intr_establish(tcadev, cookie, level, func, arg)
struct device *tcadev;
void *cookie, *arg;
- tc_intrlevel_t level;
+ int level;
int (*func)(void *);
{
u_long dev = (u_long)cookie;
diff --git a/sys/arch/alpha/tc/tc_conf.h b/sys/arch/alpha/tc/tc_conf.h
index b4391d67ef8..3f813b708ab 100644
--- a/sys/arch/alpha/tc/tc_conf.h
+++ b/sys/arch/alpha/tc/tc_conf.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: tc_conf.h,v 1.8 2004/06/28 02:28:43 aaron Exp $ */
+/* $OpenBSD: tc_conf.h,v 1.9 2007/11/06 18:20:05 miod Exp $ */
/* $NetBSD: tc_conf.h,v 1.10 2000/06/04 19:14:29 cgd Exp $ */
/*
@@ -39,7 +39,7 @@ extern void tc_3000_500_intr_setup(void);
extern void tc_3000_500_iointr(void *, unsigned long);
extern void tc_3000_500_intr_establish(struct device *, void *,
- tc_intrlevel_t, int (*)(void *), void *);
+ int, int (*)(void *), void *);
extern void tc_3000_500_intr_disestablish(struct device *, void *);
extern int tc_3000_500_nslots;
@@ -57,7 +57,7 @@ extern void tc_3000_300_intr_setup(void);
extern void tc_3000_300_iointr(void *, unsigned long);
extern void tc_3000_300_intr_establish(struct device *, void *,
- tc_intrlevel_t, int (*)(void *), void *);
+ int, int (*)(void *), void *);
extern void tc_3000_300_intr_disestablish(struct device *, void *);
extern int tc_3000_300_nslots;
diff --git a/sys/dev/tc/if_fta.c b/sys/dev/tc/if_fta.c
index 1d1aff54bfd..343f8893240 100644
--- a/sys/dev/tc/if_fta.c
+++ b/sys/dev/tc/if_fta.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: if_fta.c,v 1.13 2007/04/12 17:05:20 miod Exp $ */
+/* $OpenBSD: if_fta.c,v 1.14 2007/11/06 18:20:07 miod Exp $ */
/* $NetBSD: if_fta.c,v 1.7 1996/10/22 21:37:26 cgd Exp $ */
/*-
@@ -113,7 +113,7 @@ pdq_tc_attach(parent, self, aux)
sc->sc_arpcom.ac_enaddr, 6);
pdq_ifattach(sc, NULL);
- tc_intr_establish(parent, ta->ta_cookie, TC_IPL_NET,
+ tc_intr_establish(parent, ta->ta_cookie, IPL_NET,
(int (*)(void *)) pdq_interrupt, sc->sc_pdq);
sc->sc_ats = shutdownhook_establish((void (*)(void *)) pdq_hwreset,
diff --git a/sys/dev/tc/if_le_ioasic.c b/sys/dev/tc/if_le_ioasic.c
index 2f770263063..b239b4b9af9 100644
--- a/sys/dev/tc/if_le_ioasic.c
+++ b/sys/dev/tc/if_le_ioasic.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: if_le_ioasic.c,v 1.13 2007/06/18 21:24:43 jasper Exp $ */
+/* $OpenBSD: if_le_ioasic.c,v 1.14 2007/11/06 18:20:07 miod Exp $ */
/* $NetBSD: if_le_ioasic.c,v 1.18 2001/11/13 06:26:10 lukem Exp $ */
/*
@@ -163,7 +163,7 @@ le_ioasic_attach(struct device *parent, struct device *self, void *aux)
(u_char *)((struct ioasic_softc *)parent)->sc_base
+ IOASIC_SLOT_2_START);
- ioasic_intr_establish(parent, d->iada_cookie, TC_IPL_NET,
+ ioasic_intr_establish(parent, d->iada_cookie, IPL_NET,
am7990_intr, sc);
return;
diff --git a/sys/dev/tc/if_le_tc.c b/sys/dev/tc/if_le_tc.c
index 4d44baa2059..e8beb43b655 100644
--- a/sys/dev/tc/if_le_tc.c
+++ b/sys/dev/tc/if_le_tc.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: if_le_tc.c,v 1.8 2007/06/17 21:20:47 jasper Exp $ */
+/* $OpenBSD: if_le_tc.c,v 1.9 2007/11/06 18:20:07 miod Exp $ */
/* $NetBSD: if_le_tc.c,v 1.12 2001/11/13 06:26:10 lukem Exp $ */
/*
@@ -105,5 +105,5 @@ le_tc_attach(struct device *parent, struct device *self, void *aux)
dec_le_common_attach(&lesc->sc_am7990,
(u_char *)(d->ta_addr + LE_OFFSET_ROM + 2));
- tc_intr_establish(parent, d->ta_cookie, TC_IPL_NET, am7990_intr, sc);
+ tc_intr_establish(parent, d->ta_cookie, IPL_NET, am7990_intr, sc);
}
diff --git a/sys/dev/tc/tcds.c b/sys/dev/tc/tcds.c
index 22aeaeebf2d..1eeadf27ade 100644
--- a/sys/dev/tc/tcds.c
+++ b/sys/dev/tc/tcds.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: tcds.c,v 1.4 2004/06/28 02:28:43 aaron Exp $ */
+/* $OpenBSD: tcds.c,v 1.5 2007/11/06 18:20:07 miod Exp $ */
/* $NetBSD: tcds.c,v 1.3 2001/11/13 06:26:10 lukem Exp $ */
/*-
@@ -206,7 +206,7 @@ tcdsattach(parent, self, aux)
sc->sc_cookie = ta->ta_cookie;
- tc_intr_establish(parent, sc->sc_cookie, TC_IPL_BIO, tcds_intr, sc);
+ tc_intr_establish(parent, sc->sc_cookie, IPL_BIO, tcds_intr, sc);
/*
* XXX
diff --git a/sys/dev/tc/tcvar.h b/sys/dev/tc/tcvar.h
index 6d7319a01ea..5c1d72fbf1d 100644
--- a/sys/dev/tc/tcvar.h
+++ b/sys/dev/tc/tcvar.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: tcvar.h,v 1.12 2004/06/28 02:28:43 aaron Exp $ */
+/* $OpenBSD: tcvar.h,v 1.13 2007/11/06 18:20:07 miod Exp $ */
/* $NetBSD: tcvar.h,v 1.17 2000/06/04 19:15:15 cgd Exp $ */
/*
@@ -43,26 +43,6 @@
*/
#include <machine/tc_machdep.h>
-/*
- * In the long run, the following block will go completely away.
- * For now, the MI TC code still uses the old TC_IPL_ names
- * and not the new IPL_ names.
- */
-#if 1
-/*
- * Map the new definitions to the old.
- */
-#include <machine/intr.h>
-
-#define tc_intrlevel_t int
-
-#define TC_IPL_NONE IPL_NONE
-#define TC_IPL_BIO IPL_BIO
-#define TC_IPL_NET IPL_NET
-#define TC_IPL_TTY IPL_TTY
-#define TC_IPL_CLOCK IPL_CLOCK
-#endif /* 1 */
-
struct tc_softc {
struct device sc_dv;