xref: /original-bsd/sys/hp300/dev/fhpibreg.h (revision 2e5c0888)
1 /*
2  * Copyright (c) 1982, 1990 The Regents of the University of California.
3  * All rights reserved.
4  *
5  * %sccs.include.redist.c%
6  *
7  *	@(#)fhpibreg.h	7.1 (Berkeley) 05/08/90
8  */
9 
10 #define	vu_char	volatile u_char
11 
12 struct	fhpibdevice {
13 	u_char	hpib_pad0;
14 	vu_char	hpib_cid;
15 	u_char	hpib_pad1;
16 #define	hpib_ie		hpib_ids
17 	vu_char	hpib_ids;
18 	u_char	hpib_pad2;
19 	vu_char	hpib_ctrl2;
20 	u_char	hpib_pad3;
21 	vu_char	hpib_latch;
22 	u_char	hpib_pad4[9];
23 	vu_char	hpib_intr;
24 	u_char	hpib_pad5;
25 	vu_char	hpib_imask;
26 	u_char	hpib_pad6;
27 	vu_char	hpib_data;
28 	u_char	hpib_pad7;
29 	vu_char	hpib_stat;
30 	u_char	hpib_pad8;
31 	vu_char	hpib_cmd;
32 	u_char	hpib_pad9;
33 	vu_char	hpib_ar;
34 	u_char	hpib_pad10;
35 	vu_char	hpib_pmask;
36 	u_char	hpib_pad11;
37 	vu_char	hpib_psense;
38 };
39 
40 /* status bits */
41 #define	ST_READ0        0xC0
42 #define	ST_READ1	0x80
43 #define	ST_IENAB	0x80
44 #define	ST_EOI		0x80
45 #define	ST_ATN		0x40
46 #define	ST_WRITE	0x00
47 
48 /* control bits */
49 #define	CT_8BIT		0x80
50 #define	CT_REN		0x20
51 #define	CT_IFC		0x10
52 #define	CT_FIFOSEL	0x02
53 #define	CT_INITFIFO	0x01
54 
55 #define	IM_PABORT	0x40
56 #define	IM_PPRESP	0x20
57 #define	IM_ROOM		0x08
58 #define	IM_BYTE		0x04
59 #define	IM_IDLE		0x02
60 
61 #define	AR_ARONC	0x80
62