summaryrefslogtreecommitdiffstats
path: root/sys/i386/include/intr_machdep.h
diff options
context:
space:
mode:
authorjhb <jhb@FreeBSD.org>2004-05-04 20:07:46 +0000
committerjhb <jhb@FreeBSD.org>2004-05-04 20:07:46 +0000
commit9f40cdcc06c7f78ceca9eb169b02429fde9d7354 (patch)
tree67edc778374e48c5791b24e8e4456ccda702d3f7 /sys/i386/include/intr_machdep.h
parent4784e0360d2e3464543727002f2dba185b9ff1f9 (diff)
downloadFreeBSD-src-9f40cdcc06c7f78ceca9eb169b02429fde9d7354.zip
FreeBSD-src-9f40cdcc06c7f78ceca9eb169b02429fde9d7354.tar.gz
Add a simple mini-driver for the ELCR register. Originally, the ELCR
register controlled the trigger mode and polarity of EISA interrupts. However, it appears that most (all?) PCI systems use the ELCR to manage the trigger mode and polarity of ISA interrupts as well since ISA IRQs used to route PCI interrupts need to be level triggered with active low polarity. We check to see if the ELCR exists by sanity checking the value we get back ensuring that IRQS 0 (8254), 1 (atkbd), 2 (the link from the slave PIC), and 8 (RTC) are all clear indicating edge trigger and active high polarity. This mini-driver will be used by the atpic driver to manage the trigger and polarity of ISA IRQs. Also, the mptable parsing code will use this mini driver rather than examining the ELCR directly.
Diffstat (limited to 'sys/i386/include/intr_machdep.h')
-rw-r--r--sys/i386/include/intr_machdep.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/sys/i386/include/intr_machdep.h b/sys/i386/include/intr_machdep.h
index 0aacd91..6794751 100644
--- a/sys/i386/include/intr_machdep.h
+++ b/sys/i386/include/intr_machdep.h
@@ -77,6 +77,11 @@ struct intrframe;
extern struct mtx icu_lock;
+/* XXX: The elcr_* prototypes probably belong somewhere else. */
+int elcr_probe(void);
+enum intr_trigger elcr_read_trigger(u_int irq);
+void elcr_resume(void);
+void elcr_write_trigger(u_int irq, enum intr_trigger trigger);
int intr_add_handler(const char *name, int vector, driver_intr_t handler,
void *arg, enum intr_type flags, void **cookiep);
void intr_execute_handlers(struct intsrc *isrc, struct intrframe *iframe);
OpenPOWER on IntegriCloud