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