summaryrefslogtreecommitdiffstats
path: root/sys/mips
diff options
context:
space:
mode:
authoradrian <adrian@FreeBSD.org>2011-04-30 12:07:15 +0000
committeradrian <adrian@FreeBSD.org>2011-04-30 12:07:15 +0000
commit6ab4da9340c3ae6f29e1949c8b8b83e0b16fba78 (patch)
treed799af59d217b16662bd9adfcb9a1927480b9b3c /sys/mips
parentd8b9be857cca2184a1a4ff457ee2523bcface1d0 (diff)
downloadFreeBSD-src-6ab4da9340c3ae6f29e1949c8b8b83e0b16fba78.zip
FreeBSD-src-6ab4da9340c3ae6f29e1949c8b8b83e0b16fba78.tar.gz
The AR724x SoC's require the irq status line to be acked/cleared.
This allows console IO to occur correctly once the kernel is in multi-user mode. Submitted by: Luiz Otavio O Souza
Diffstat (limited to 'sys/mips')
-rw-r--r--sys/mips/atheros/apb.c15
1 files changed, 15 insertions, 0 deletions
diff --git a/sys/mips/atheros/apb.c b/sys/mips/atheros/apb.c
index c004741..42c0157 100644
--- a/sys/mips/atheros/apb.c
+++ b/sys/mips/atheros/apb.c
@@ -42,6 +42,7 @@ __FBSDID("$FreeBSD$");
#include <mips/atheros/apbvar.h>
#include <mips/atheros/ar71xxreg.h>
+#include <mips/atheros/ar71xx_setup.h>
#undef APB_DEBUG
#ifdef APB_DEBUG
@@ -337,6 +338,20 @@ apb_intr(void *arg)
reg = ATH_READ_REG(AR71XX_MISC_INTR_STATUS);
for (irq = 0; irq < APB_NIRQS; irq++) {
if (reg & (1 << irq)) {
+
+ switch (ar71xx_soc) {
+ case AR71XX_SOC_AR7240:
+ case AR71XX_SOC_AR7241:
+ case AR71XX_SOC_AR7242:
+ /* Ack/clear the irq on status register for AR724x */
+ ATH_WRITE_REG(AR71XX_MISC_INTR_STATUS,
+ reg & ~(1 << irq));
+ break;
+ default:
+ /* fallthrough */
+ break;
+ }
+
event = sc->sc_eventstab[irq];
if (!event || TAILQ_EMPTY(&event->ie_handlers)) {
/* Ignore timer interrupts */
OpenPOWER on IntegriCloud