diff options
author | 2000-11-08 13:58:19 +0000 | |
---|---|---|
committer | 2000-11-08 13:58:19 +0000 | |
commit | f096c1035b1331f92ab10914e9b4e12ed94d9374 (patch) | |
tree | 0f7a3b6cc9a1674f864250bfc0efc429a06cf0b0 /sys | |
parent | Opps. (diff) | |
download | wireguard-openbsd-f096c1035b1331f92ab10914e9b4e12ed94d9374.tar.xz wireguard-openbsd-f096c1035b1331f92ab10914e9b4e12ed94d9374.zip |
Use netisr_dispatch.
Diffstat (limited to 'sys')
-rw-r--r-- | sys/arch/sparc/sparc/intr.c | 49 |
1 files changed, 7 insertions, 42 deletions
diff --git a/sys/arch/sparc/sparc/intr.c b/sys/arch/sparc/sparc/intr.c index 5fcaec1ec91..e5e18eea5c9 100644 --- a/sys/arch/sparc/sparc/intr.c +++ b/sys/arch/sparc/sparc/intr.c @@ -77,9 +77,6 @@ #include <netinet6/ip6_var.h> #endif -#include "ppp.h" -#include "bridge.h" - void strayintr __P((struct clockframe *)); int soft01intr __P((void *)); @@ -125,11 +122,6 @@ soft01intr(fp) if (rom_console_input && cnrom()) cnrint(); if (sir.sir_any) { - /* - * XXX this is bogus: should just have a list of - * routines to call, a la timeouts. Mods to - * netisr are not atomic and must be protected (gah). - */ if (sir.sir_which[SIR_NET]) { int n, s; @@ -138,40 +130,13 @@ soft01intr(fp) netisr = 0; splx(s); sir.sir_which[SIR_NET] = 0; -#ifdef INET - if (n & (1 << NETISR_ARP)) - arpintr(); - if (n & (1 << NETISR_IP)) - ipintr(); -#endif -#ifdef INET6 - if (n & (1 << NETISR_IPV6)) - ip6intr(); -#endif -#ifdef NETATALK - if (n & (1 << NETISR_ATALK)) - atintr(); -#endif -#ifdef NS - if (n & (1 << NETISR_NS)) - nsintr(); -#endif -#ifdef ISO - if (n & (1 << NETISR_ISO)) - clnlintr(); -#endif -#ifdef NATM - if (n & (1 << NETISR_NATM)) - natmintr(); -#endif -#if NPPP > 0 - if (n & (1 << NETISR_PPP)) - pppintr(); -#endif -#if NBRIDGE > 0 - if (n & (1 << NETISR_BRIDGE)) - bridgeintr(); -#endif +#define DONETISR(bit, fn) \ + do { \ + if (n & (1 << bit)) \ + fn(); \ + } while (0) +#include <net/netisr_dispatch.h> +#undef DONETISR } if (sir.sir_which[SIR_CLOCK]) { sir.sir_which[SIR_CLOCK] = 0; |