xref: /csrg-svn/sys/tahoe/vba/vbaparam.h (revision 25930)
1 /*	vbaparam.h	1.1	86/01/21	*/
2 
3 /*
4  * Parameters related to the VERSAbus i/o configuration.
5  */
6 
7 /*
8  * VERSAbus i/o devices use either memory mapped interfaces
9  * or mapped i/o register banks, or some of both.  Page tables
10  * are allocated at boot time by each device driver, as needed.
11  * VMEMmap is used to map a fixed size portion of the VERSAbus
12  * i/o space, while VMEMmap1 maps dynamically defined portions
13  * for devices which utilize shared i/o memory.  VBmap is used
14  * for mapping kernel intermediate buffers for DMA devices which
15  * are incapable of utilizing user virtual addresses or which
16  * require page aligned i/o buffers.  The size of the VMEMmap1
17  * VBmap tables must be large enough for the needs of all devices
18  * in the system.
19  */
20 extern	struct pte VMEMmap[], VMEMmap1[];
21 extern	caddr_t	vmem1, vmemend;
22 extern	struct pte VBmap[];
23 extern	caddr_t vbbase, vbend;
24 
25 /*
26  * The following constants define the fixed size map of the
27  * VERSAbus i/o space.  The values should reflect the range
28  * of i/o addresses used by all the controllers handled in
29  * the system as specified in the ubminit structure in ioconf.c.
30  */
31 #define VBIOBASE	0xfff00000	/* base of VERSAbus address space */
32 #define VBIOEND		0xffffee45	/* last address in mapped space */
33 /* number of entries in the system page pable for i/o space */
34 #define VBIOSIZE	btoc(VBIOEND-VBIOBASE)
35 
36 /*
37  * Page table map sizes.
38  *
39  * Current VBmap allotments are:
40  *	4 vd controllers	32+1 pte's
41  *	2 cy controllers	32+1 pte's
42  * Current VBMEMmap allotments are:
43  *	2 ace controllers	32+1 pte's
44  */
45 #define	VBPTSIZE	(((4*(32+1))+2*(32+1)+3) &~ 3)
46 #define	VBMEMSIZE	((2*(32+1)+3) &~ 3)
47