summaryrefslogtreecommitdiff
path: root/sys/arch/sparc64/dev/pci_machdep.c
diff options
context:
space:
mode:
Diffstat (limited to 'sys/arch/sparc64/dev/pci_machdep.c')
-rw-r--r--sys/arch/sparc64/dev/pci_machdep.c11
1 files changed, 8 insertions, 3 deletions
diff --git a/sys/arch/sparc64/dev/pci_machdep.c b/sys/arch/sparc64/dev/pci_machdep.c
index 8e48222337e..c4c01bd2cbe 100644
--- a/sys/arch/sparc64/dev/pci_machdep.c
+++ b/sys/arch/sparc64/dev/pci_machdep.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: pci_machdep.c,v 1.12 2003/05/10 21:11:14 deraadt Exp $ */
+/* $OpenBSD: pci_machdep.c,v 1.13 2003/05/16 06:59:12 henric Exp $ */
/* $NetBSD: pci_machdep.c,v 1.22 2001/07/20 00:07:13 eeh Exp $ */
/*
@@ -415,7 +415,11 @@ pci_intr_map(pa, ihp)
/* XXXX -- we use the ino. What if there is a valid IGN? */
*ihp = interrupts;
- return (0);
+
+ if (pa->pa_pc->intr_map)
+ return ((*pa->pa_pc->intr_map)(pa, ihp));
+ else
+ return (0);
}
const char *
@@ -454,7 +458,8 @@ pci_intr_establish(pc, ih, level, func, arg, what)
void *cookie;
struct psycho_pbm *pp = (struct psycho_pbm *)pc->cookie;
- DPRINTF(SPDB_INTR, ("pci_intr_establish: ih %lu; level %d", (u_long)ih, level));
+ DPRINTF(SPDB_INTR, ("pci_intr_establish: ih %lu; level %d",
+ (u_long)ih, level));
cookie = bus_intr_establish(pp->pp_memt, ih, level, 0, func, arg);
DPRINTF(SPDB_INTR, ("; returning handle %p\n", cookie));