Commit | Line | Data |
---|---|---|
cb1c44c2 | 1 | /* |
1810611d | 2 | * Copyright (c) 1980, 1986 Regents of the University of California. |
cb1c44c2 KM |
3 | * All rights reserved. The Berkeley software License Agreement |
4 | * specifies the terms and conditions for redistribution. | |
5 | * | |
1810611d | 6 | * @(#)netisr.h 7.1 (Berkeley) %G% |
cb1c44c2 | 7 | */ |
a9f97ede BJ |
8 | |
9 | /* | |
10 | * The networking code runs off software interrupts. | |
11 | * | |
12 | * You can switch into the network by doing splnet() and return by splx(). | |
13 | * The software interrupt level for the network is higher than the software | |
14 | * level for the clock (so you can enter the network in routines called | |
15 | * at timeout time). | |
16 | */ | |
39c78b00 | 17 | #ifdef vax |
a9f97ede | 18 | #define setsoftnet() mtpr(SIRR, 12) |
ddccffcc | 19 | #endif |
a9f97ede BJ |
20 | |
21 | /* | |
22 | * Each ``pup-level-1'' input queue has a bit in a ``netisr'' status | |
23 | * word which is used to de-multiplex a single software | |
24 | * interrupt used for scheduling the network code to calls | |
25 | * on the lowest level routine of each protocol. | |
26 | */ | |
27 | #define NETISR_RAW 0 /* same as AF_UNSPEC */ | |
28 | #define NETISR_IP 2 /* same as AF_INET */ | |
e3d5e8b3 | 29 | #define NETISR_IMP 3 /* same as AF_IMPLINK */ |
a9f97ede BJ |
30 | #define NETISR_NS 6 /* same as AF_NS */ |
31 | ||
32 | #define schednetisr(anisr) { netisr |= 1<<(anisr); setsoftnet(); } | |
33 | ||
34 | #ifndef LOCORE | |
35 | #ifdef KERNEL | |
36 | int netisr; /* scheduling bits for network */ | |
37 | #endif | |
38 | #endif |