xref: /csrg-svn/sys/stand.att/saio.h (revision 325)
1*325Sbill /*	saio.h	1.1	06/28/80	*/
2*325Sbill 
3*325Sbill /*
4*325Sbill  * header file for standalone package
5*325Sbill  */
6*325Sbill 
7*325Sbill /*
8*325Sbill  * io block: includes an
9*325Sbill  * inode, cells for the use of seek, etc,
10*325Sbill  * and a buffer.
11*325Sbill  */
12*325Sbill struct	iob {
13*325Sbill 	char	i_flgs;
14*325Sbill 	struct	inode i_ino;
15*325Sbill 	int	i_unit;
16*325Sbill 	daddr_t	i_boff;
17*325Sbill 	daddr_t	i_cyloff;
18*325Sbill 	off_t	i_offset;
19*325Sbill 	daddr_t	i_bn;
20*325Sbill 	char	*i_ma;
21*325Sbill 	int	i_cc;
22*325Sbill 	char	i_buf[BSIZE];
23*325Sbill };
24*325Sbill 
25*325Sbill #define F_READ	01
26*325Sbill #define F_WRITE	02
27*325Sbill #define F_ALLOC	04
28*325Sbill #define F_FILE	010
29*325Sbill 
30*325Sbill /*
31*325Sbill  * dev switch
32*325Sbill  */
33*325Sbill struct devsw {
34*325Sbill 	char	*dv_name;
35*325Sbill 	int	(*dv_strategy)();
36*325Sbill 	int	(*dv_open)();
37*325Sbill 	int	(*dv_close)();
38*325Sbill };
39*325Sbill 
40*325Sbill struct devsw devsw[];
41*325Sbill 
42*325Sbill /*
43*325Sbill  * request codes. Must be the same a F_XXX above
44*325Sbill  */
45*325Sbill #define	READ	1
46*325Sbill #define	WRITE	2
47*325Sbill 
48*325Sbill #define	NBUFS	4
49*325Sbill 
50*325Sbill char	b[NBUFS][BSIZE];
51*325Sbill daddr_t	blknos[NBUFS];
52*325Sbill 
53*325Sbill #define NFILES	4
54*325Sbill struct	iob iob[NFILES];
55*325Sbill 
56*325Sbill #define	PHYSUBA0	0x20006000
57*325Sbill #define	PHYSMBA0	0x20010000
58*325Sbill #define	PHYSMBA1	0x20012000
59*325Sbill #define	PHYSUMEM	0x2013e000
60