1*3266Swnj /* savax.h 4.1 81/03/15 */ 2*3266Swnj 3*3266Swnj /* 4*3266Swnj * Standalone definitions peculiar to vaxen 5*3266Swnj * The mba devices in the standalone system are addressed as 6*3266Swnj * xx(unit,section) 7*3266Swnj * where unit is 8*3266Swnj * 8*mbanum+drive 9*3266Swnj * The mbadrv macro gives the address of the device registers 10*3266Swnj * for the specified unit; the mbamba macro gives the address of the 11*3266Swnj * mba registers themselves. 12*3266Swnj * 13*3266Swnj * The uba devices are also addressed by giving, as unit, 14*3266Swnj * 8*ubanum+drive 15*3266Swnj * The ubamem macro converts a specified unibus address (ala pdp-11) 16*3266Swnj * into a unibus memory address space address. 17*3266Swnj */ 18*3266Swnj 19*3266Swnj int cpu; /* see <sys/cpu.h> */ 20*3266Swnj 21*3266Swnj #define MAXNMBA 4 22*3266Swnj struct mba_regs **mbaddr; 23*3266Swnj int mbaact; 24*3266Swnj caddr_t *umaddr; 25*3266Swnj struct uba_regs **ubaddr; 26*3266Swnj 27*3266Swnj #define UNITTOMBA(unit) ((unit)>>3) 28*3266Swnj #define UNITTODRIVE(unit) ((unit)&07) 29*3266Swnj 30*3266Swnj #define mbamba(unit) (mbaddr[UNITTOMBA(unit)]) 31*3266Swnj #define mbadrv(unit) (&mbamba(unit)->mba_drv[UNITTODRIVE(unit)]) 32*3266Swnj 33*3266Swnj #define UNITTOUBA(unit) ((unit)>>3) 34*3266Swnj #define ubauba(unit) (ubaddr[UNITTOUBA(unit)]) 35*3266Swnj #define ubamem(unit, off) \ 36*3266Swnj ((struct device *)(umaddr[UNITTOUBA(unit)]+(off&017777))) 37