* Using conditional compilation instead of simply deleting source code, to

ensure interrupts are disabled only once per interrupt event.
* Coding style cleanup.


git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@34819 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Colin Günther
2009-12-29 23:46:42 +00:00
parent 75b892d51f
commit c006bb2735
2 changed files with 13 additions and 1 deletions
@@ -589,6 +589,18 @@ wi_intr(void *arg)
WI_LOCK(sc);
#if !defined(__HAIKU__)
if (sc->wi_gone || !sc->sc_enabled || (ifp->if_flags & IFF_UP) == 0) {
CSR_WRITE_2(sc, WI_INT_EN, 0);
CSR_WRITE_2(sc, WI_EVENT_ACK, 0xFFFF);
WI_UNLOCK(sc);
return;
}
/* Disable interrupts. */
CSR_WRITE_2(sc, WI_INT_EN, 0);
#endif
status = CSR_READ_2(sc, WI_EVENT_STAT);
if (status & WI_EV_RX)
wi_rx_intr(sc);
@@ -38,8 +38,8 @@ HAIKU_CHECK_DISABLE_INTERRUPTS(device_t dev)
return 0;
}
/* Disable interrupts. */
CSR_WRITE_2(sc, WI_INT_EN, 0);
// Disable interrupts.
return 1;
}