summaryrefslogtreecommitdiff
path: root/sys/arch/alpha/pci/pci_6600.c
diff options
context:
space:
mode:
authorMichael Shalayeff <mickey@cvs.openbsd.org>2001-08-17 22:26:59 +0000
committerMichael Shalayeff <mickey@cvs.openbsd.org>2001-08-17 22:26:59 +0000
commit5f794f8c1c7a349faa97c6ef092a96fcf48ca094 (patch)
treee2511d92dc642fc35e0925f4f7f3681fafc8f75f /sys/arch/alpha/pci/pci_6600.c
parent0c3296d28b7e353e842dc384702aebc7653387c5 (diff)
provide a way to get the number used for irq line, not only a string
representation, this is needed for devices like cbb which pass the interrupt line down to the cardbus attachment and not getting the right line before pci_intr_map() has done it's dirty deed. tested on i386 by jason@, compiles on alpha by art@. ppc and mveppc are to be test-compiled, but should work (;
Diffstat (limited to 'sys/arch/alpha/pci/pci_6600.c')
-rw-r--r--sys/arch/alpha/pci/pci_6600.c19
1 files changed, 18 insertions, 1 deletions
diff --git a/sys/arch/alpha/pci/pci_6600.c b/sys/arch/alpha/pci/pci_6600.c
index f875d9da4a9..69e3e9e9ffc 100644
--- a/sys/arch/alpha/pci/pci_6600.c
+++ b/sys/arch/alpha/pci/pci_6600.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: pci_6600.c,v 1.4 2001/06/25 22:02:08 csapuntz Exp $ */
+/* $OpenBSD: pci_6600.c,v 1.5 2001/08/17 22:26:58 mickey Exp $ */
/* $NetBSD: pci_6600.c,v 1.5 2000/06/06 00:50:15 thorpej Exp $ */
/*-
@@ -81,6 +81,7 @@ void dec_6600_intr_disestablish __P((void *, void *));
void *dec_6600_intr_establish __P((
void *, pci_intr_handle_t, int, int (*func)(void *), void *, char *));
const char *dec_6600_intr_string __P((void *, pci_intr_handle_t));
+int dec_6600_intr_line __P((void *, pci_intr_handle_t));
const struct evcnt *dec_6600_intr_evcnt __P((void *, pci_intr_handle_t));
int dec_6600_intr_map __P((void *, pcitag_t, int, int, pci_intr_handle_t *));
void *dec_6600_pciide_compat_intr_establish __P((void *, struct device *,
@@ -107,6 +108,7 @@ pci_6600_pickintr(pcp)
pc->pc_intr_v = pcp;
pc->pc_intr_map = dec_6600_intr_map;
pc->pc_intr_string = dec_6600_intr_string;
+ pc->pc_intr_line = dec_6600_intr_line;
#if 0
pc->pc_intr_evcnt = dec_6600_intr_evcnt;
#endif
@@ -211,6 +213,21 @@ dec_6600_intr_string(acv, ih)
return (irqstr);
}
+int
+dec_6600_intr_line(acv, ih)
+ void *acv;
+ pci_intr_handle_t ih;
+{
+
+#if NSIO
+ if (DEC_6600_LINE_IS_ISA(ih))
+ return (sio_intr_line(NULL /*XXX*/,
+ DEC_6600_LINE_ISA_IRQ(ih)));
+#endif
+
+ return (ih);
+}
+
#if 0
const struct evcnt *
dec_6600_intr_evcnt(acv, ih)