| 1 | /* param.c 4.6 81/10/29 */ |
| 2 | |
| 3 | #include "../h/param.h" |
| 4 | #include "../h/systm.h" |
| 5 | #ifdef BBNNET |
| 6 | #include "../bbnnet/net.h" |
| 7 | #include "../bbnnet/imp.h" |
| 8 | #include "../bbnnet/ucb.h" |
| 9 | #endif BBNNET |
| 10 | #include "../h/dir.h" |
| 11 | #include "../h/user.h" |
| 12 | #include "../h/proc.h" |
| 13 | #include "../h/text.h" |
| 14 | #include "../h/inode.h" |
| 15 | #include "../h/file.h" |
| 16 | #include "../h/callout.h" |
| 17 | #include "../h/clist.h" |
| 18 | #include "../h/cmap.h" |
| 19 | #include "../h/port.h" |
| 20 | /* |
| 21 | * System parameter formulae. |
| 22 | * |
| 23 | * This file is copied into each directory where we compile |
| 24 | * the kernel; it should be modified there to suit local taste |
| 25 | * if necessary. |
| 26 | * |
| 27 | * Compiled with -DHZ=xx -DTIMEZONE=x -DDST=x -DMAXUSERS=xx |
| 28 | */ |
| 29 | |
| 30 | int hz = HZ; |
| 31 | int timezone = TIMEZONE; |
| 32 | int dstflag = DST; |
| 33 | #define NPROC (20 + 8 * MAXUSERS) |
| 34 | int nproc = NPROC; |
| 35 | int ntext = 24 + MAXUSERS; |
| 36 | int ninode = (NPROC + 16 + MAXUSERS) + 32; |
| 37 | int nfile = 8 * (NPROC + 16 + MAXUSERS) / 10 + 32; |
| 38 | int ncallout = 16 + MAXUSERS; |
| 39 | int nclist = 100 + 16 * MAXUSERS; |
| 40 | int nport = NPROC / 2; |
| 41 | #ifdef BBNNET |
| 42 | int nnetpages = NNETPAGES; |
| 43 | int nnetcon = NCON; |
| 44 | int nhost = NHOST; |
| 45 | #endif BBNNET |
| 46 | |
| 47 | /* |
| 48 | * These are initialized at bootstrap time |
| 49 | * to values dependent on memory size |
| 50 | */ |
| 51 | int nbuf, nswbuf; |
| 52 | |
| 53 | /* |
| 54 | * These have to be allocated somewhere; allocating |
| 55 | * them here forces loader errors if this file is omitted. |
| 56 | */ |
| 57 | struct proc *proc, *procNPROC; |
| 58 | struct text *text, *textNTEXT; |
| 59 | struct inode *inode, *inodeNINODE; |
| 60 | struct file *file, *fileNFILE; |
| 61 | struct callout *callout; |
| 62 | struct cblock *cfree; |
| 63 | struct buf *buf, *swbuf; |
| 64 | short *swsize; |
| 65 | int *swpf; |
| 66 | char *buffers; |
| 67 | struct cmap *cmap, *ecmap; |
| 68 | #ifdef BBNNET |
| 69 | struct ucb *contab, *conNCON; |
| 70 | struct host *host, *hostNHOST; |
| 71 | struct net netcb; |
| 72 | struct net_stat netstat; |
| 73 | struct impstat imp_stat; |
| 74 | #endif BBNNET |