1 /* 2 * config.h 1.5 81/05/22 3 * Definitions that everybody needs to know 4 */ 5 6 #define eq(a,b) (strcmp(a,b) == 0) 7 #define TRUE 1 8 #define FALSE 0 9 #define DRIVER 1 10 #define NORMAL 2 11 #define INVISIBLE 3 12 13 #define TO_NEXUS -1 14 15 struct file_list { 16 char *f_fn; 17 int f_type; 18 char *f_next; 19 char *f_needs; 20 }; 21 22 struct idlst { 23 char *id; 24 struct idlst *id_next; 25 }; 26 27 typedef char bool; 28 29 struct device { 30 int d_type; /* CONTROLLER, DEVICE, UBA or MBA */ 31 struct device *d_conn; /* What it is connected to */ 32 char *d_name; /* Name of device (e.g. rk11) */ 33 struct idlist *d_vec; /* Interrupt vectors */ 34 int d_addr; /* Address of csr */ 35 int d_unit; /* Unit number */ 36 int d_drive; /* Drive number */ 37 int d_slave; /* Slave number */ 38 #define QUES -1 /* -1 means '?' */ 39 #define UNKNOWN -2 /* -2 means not set yet */ 40 bool d_dk; /* if init 1 set to number for iostat */ 41 int d_flags; /* Flags for device init */ 42 struct device *d_next; /* Next one in list */ 43 }; 44 45 struct config { 46 char *c_dev; 47 char *s_sysname; 48 }; 49 50 struct cputype { 51 char *cpu_name; 52 struct cputype *cpu_next; 53 } *cputype; 54 struct opt { 55 char *op_name; 56 struct cputype *op_next; 57 } *opt; 58 char *ident, *ns(), *malloc(), *tc(), *qu(); 59 bool do_trace, seen_mba, seen_uba; 60 struct device *connect(); 61 struct device *dtab; 62 char errbuf[80]; 63 int yyline; 64 struct file_list *ftab, *conf_list, *confp; 65 char *PREFIX; 66 int hz, timezone, hadtz, maxusers, dst; 67