diff options
-rw-r--r-- | sys/arch/alpha/dev/shared_intr.c | 10 | ||||
-rw-r--r-- | sys/arch/i386/isa/isa_machdep.c | 8 | ||||
-rw-r--r-- | sys/dev/isa/i82365_isa.c | 4 | ||||
-rw-r--r-- | sys/dev/isa/i82365_isasubr.c | 4 |
4 files changed, 17 insertions, 9 deletions
diff --git a/sys/arch/alpha/dev/shared_intr.c b/sys/arch/alpha/dev/shared_intr.c index d2b31d27cf1..5d3302bc491 100644 --- a/sys/arch/alpha/dev/shared_intr.c +++ b/sys/arch/alpha/dev/shared_intr.c @@ -1,4 +1,4 @@ -/* $OpenBSD: shared_intr.c,v 1.4 1998/12/27 00:27:18 deraadt Exp $ */ +/* $OpenBSD: shared_intr.c,v 1.5 1998/12/31 09:17:58 deraadt Exp $ */ /* $NetBSD: shared_intr.c,v 1.1 1996/11/17 02:03:08 cgd Exp $ */ /* @@ -115,6 +115,12 @@ alpha_shared_intr_dispatch(intr, num) return (handled); } +/* + * Just check to see if an IRQ is available/can be shared. + * 0 = interrupt not available + * 1 = interrupt shareable + * 2 = interrupt all to ourself + */ int alpha_shared_intr_check(intr, num, type) struct alpha_shared_intr *intr; @@ -131,7 +137,7 @@ alpha_shared_intr_check(intr, num, type) case IST_LEVEL: if (type != intr[num].intr_sharetype) return (0); - return (2); + return (1); case IST_EDGE: case IST_PULSE: if ((type != IST_NONE) && (intr[num].intr_q.tqh_first != NULL)) diff --git a/sys/arch/i386/isa/isa_machdep.c b/sys/arch/i386/isa/isa_machdep.c index 2193fddeb99..79019138dc7 100644 --- a/sys/arch/i386/isa/isa_machdep.c +++ b/sys/arch/i386/isa/isa_machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: isa_machdep.c,v 1.32 1998/12/27 00:27:16 deraadt Exp $ */ +/* $OpenBSD: isa_machdep.c,v 1.33 1998/12/31 09:17:52 deraadt Exp $ */ /* $NetBSD: isa_machdep.c,v 1.22 1997/06/12 23:57:32 thorpej Exp $ */ #define ISA_DMA_STATS @@ -446,7 +446,9 @@ isa_intr_alloc(ic, mask, type, irq) /* * Just check to see if an IRQ is available/can be shared. - * 0 = no match, 1 = ok match, 2 = great match + * 0 = interrupt not available + * 1 = interrupt shareable + * 2 = interrupt all to ourself */ int isa_intr_check(ic, irq, type) @@ -464,7 +466,7 @@ isa_intr_check(ic, irq, type) case IST_LEVEL: if (type != intrtype[irq]) return (0); - return (2); + return (1); break; case IST_EDGE: case IST_PULSE: diff --git a/sys/dev/isa/i82365_isa.c b/sys/dev/isa/i82365_isa.c index 1bd07bead49..5275da4d448 100644 --- a/sys/dev/isa/i82365_isa.c +++ b/sys/dev/isa/i82365_isa.c @@ -1,4 +1,4 @@ -/* $OpenBSD: i82365_isa.c,v 1.2 1998/12/27 00:27:18 deraadt Exp $ */ +/* $OpenBSD: i82365_isa.c,v 1.3 1998/12/31 09:17:43 deraadt Exp $ */ /* $NetBSD: i82365_isa.c,v 1.11 1998/06/09 07:25:00 thorpej Exp $ */ /* @@ -212,7 +212,7 @@ pcic_isa_attach(parent, self, aux) if (isa_intr_check(ic, pcic_isa_intr_list[i], ist) == 2) goto found; for (i = 0; i < npcic_isa_intr_list; i++) - if (isa_intr_check(ic, pcic_isa_intr_list[i], ist)) + if (isa_intr_check(ic, pcic_isa_intr_list[i], ist) == 1) goto found; printf("\n%s: can't allocate interrupt\n", sc->dev.dv_xname); return; diff --git a/sys/dev/isa/i82365_isasubr.c b/sys/dev/isa/i82365_isasubr.c index a4c853500ca..5c335864e97 100644 --- a/sys/dev/isa/i82365_isasubr.c +++ b/sys/dev/isa/i82365_isasubr.c @@ -1,4 +1,4 @@ -/* $OpenBSD: i82365_isasubr.c,v 1.3 1998/12/27 00:27:18 deraadt Exp $ */ +/* $OpenBSD: i82365_isasubr.c,v 1.4 1998/12/31 09:17:44 deraadt Exp $ */ /* $NetBSD: i82365_isasubr.c,v 1.1 1998/06/07 18:28:31 sommerfe Exp $ */ /* @@ -226,7 +226,7 @@ pcic_isa_chip_intr_establish(pch, pf, ipl, fct, arg) if (isa_intr_check(ic, pcic_isa_intr_list[i], ist) == 2) goto found; for (i = 0; i < npcic_isa_intr_list; i++) - if (isa_intr_check(ic, pcic_isa_intr_list[i], ist)) + if (isa_intr_check(ic, pcic_isa_intr_list[i], ist) == 1) goto found; return (NULL); |