FreeBSD/Linux Kernel Cross Reference
sys/sqt/slicreg.h
1 /*
2 * Mach Operating System
3 * Copyright (c) 1991 Carnegie Mellon University
4 * Copyright (c) 1991 Sequent Computer Systems
5 * All Rights Reserved.
6 *
7 * Permission to use, copy, modify and distribute this software and its
8 * documentation is hereby granted, provided that both the copyright
9 * notice and this permission notice appear in all copies of the
10 * software, derivative works or modified versions, and any portions
11 * thereof, and that both notices appear in supporting documentation.
12 *
13 * CARNEGIE MELLON AND SEQUENT COMPUTER SYSTEMS ALLOW FREE USE OF
14 * THIS SOFTWARE IN ITS "AS IS" CONDITION. CARNEGIE MELLON AND
15 * SEQUENT COMPUTER SYSTEMS DISCLAIM ANY LIABILITY OF ANY KIND FOR
16 * ANY DAMAGES WHATSOEVER RESULTING FROM THE USE OF THIS SOFTWARE.
17 *
18 * Carnegie Mellon requests users of this software to return to
19 *
20 * Software Distribution Coordinator or Software.Distribution@CS.CMU.EDU
21 * School of Computer Science
22 * Carnegie Mellon University
23 * Pittsburgh PA 15213-3890
24 *
25 * any improvements or extensions that they make and grant Carnegie Mellon
26 * the rights to redistribute these changes.
27 */
28
29 /*
30 * HISTORY
31 * $Log: slicreg.h,v $
32 * Revision 2.3 91/07/31 18:04:07 dbg
33 * Changed copyright.
34 * [91/07/31 dbg]
35 *
36 * Revision 2.2 91/05/08 12:59:55 dbg
37 * Added, from Sequent SYMMETRY sources.
38 * [91/02/26 dbg]
39 *
40 */
41
42 /*
43 * $Header: slicreg.h,v 2.3 91/07/31 18:04:07 dbg Exp $
44 *
45 * slicreg.h
46 * SLIC registers and their contents.
47 */
48
49 /*
50 * Revision 1.1 89/07/19 14:48:55 kak
51 * Initial revision
52 *
53 * Revision 2.23 88/10/10 15:07:43 rto
54 * Added 532-specific definitions in support of a common inter-project
55 * build environment.
56 *
57 * Revision 2.22 88/10/06 09:32:27 rto
58 * 532port: Added support for 532-specific configuration options.
59 *
60 * Revision 2.22 88/09/28 11:29:35 corene
61 * added new defines for Wombat (3167 Weitek FPA)
62 *
63 * Revision 2.20 88/09/22 08:58:35 gak
64 * Add extra SL_P2_SPEED values.
65 *
66 * Revision 2.19 88/03/24 10:42:07 dilip
67 * Corrected values for SL_P2_386_D, SL_P2_387_C and renamed
68 * WEITEK define.
69 *
70 * Revision 2.18 88/03/23 06:57:14 gak
71 * Add new bits to Symmetry proc config proms.
72 *
73 */
74
75 #ifndef _SQT_SLIREG_H_
76 #define _SQT_SLIREG_H_
77
78 /* General registers */
79 #define SL_G_BOARDTYPE 0
80 #define SLB_PROCBOARD 0x0
81 #define SLB_MEMBOARD 0x1
82 #define SLB_MBABOARD 0x2
83 #define SLB_SCSIBOARD 0x3
84 #define SLB_ZDCBOARD 0x4
85 #define SLB_CLKARBBOARD 0x5
86 #define SLB_SGSPROCBOARD 0x6
87 #define SLB_SSMBOARD 0x8
88 #define SLB_532PROCBOARD 0x9
89 #define SLB_SGSMEMBOARD 0x7
90 #define SLB_FOUNDBOARD 0x40
91 #define SLB_GFDEBOARD 0x41
92 #define SLB_KXXBOARD 0x80
93
94 #define SL_G_VARIATION 1 /* board variation */
95 #define SL_G_HGENERATION 2 /* h/w board generation */
96 #define SL_G_SGENERATION 3 /* s/w board generation */
97 #define SL_G_LAST_SEQ 20 /* last Sequent-reserved location */
98 #define SL_G_NONZERO55 29 /* this register should always be 55 */
99 #define SL_G_NONZEROAA 30 /* this register should always be AA */
100 #define SL_G_CHKSUM 31 /* checksum for slave reg PROM */
101 #define SL_G_BERR 32 /* bus error reg */
102 #define SLB_IBE 0x01 /* initiated bus transfer */
103 #define SLB_RBE 0x02 /* received bus transfer */
104 #define SLB_SBE 0x04 /* saw "bus error" signal */
105 #define SLB_DBE 0x08 /* detected bus error */
106 #define SLB_ISE 0x10 /* initiated SLIC transfer */
107 #define SLB_RSE 0x20 /* received SLIC transfer */
108 #define SLB_SSE 0x40 /* saw "SLIC ERROR" signal */
109 #define SLB_DSE 0x80 /* detected SLIC error */
110 #define SL_G_ACCERR 33 /* only on initiator boards */
111 #define SL_G_ACCERR0 SL_G_ACCERR /* Channel 0 Access Error Register */
112 #define SL_G_ACCERR1 34 /* Channel 1 Access Error Register */
113 #define SL_G_ACCERR2 35 /* Channel 2 Access Error Register */
114 #define SL_G_ACCERR3 36 /* Channel 3 Access Error Register */
115 #define SLB_AEMSK 0x3F /* useful bits in this reg */
116 #define SLB_ATMSK 0x07 /* mask for access type */
117 #define SLB_ACCERR 0x20 /* access error seen */
118 #define SLB_AEIO 0x10 /* IO response */
119 #define SLB_AERD 0x08 /* read response */
120 #define SLB_AETIMOUT 0x00 /* bus timeout (128 cycles) */
121 #define SLB_AEFATAL 0x03 /* fatal error */
122 #define SLB_AENONFAT 0x05 /* non fatal error */
123 #define SLB_AEOK 0x06 /* access completed OK */
124 #define SL_G_CHAN0 37 /* Channel 0 Control Register */
125 #define SL_G_CHAN1 38 /* Channel 1 Control Register */
126 #define SL_G_CHAN2 39 /* Channel 2 Control Register */
127 #define SL_G_CHAN3 40 /* Channel 3 Control Register */
128 #define SLB_TVAL 0x0F /* Throttle Value */
129 #define SLB_TH_ENB 0x10 /* Throttle Enable */
130 #define SLB_AS_REQ 0x20 /* Asynchronous Request Inputs */
131 #define SLB_EXT_RD 0x40 /* External Read Responses */
132 #define SLB_RESPONDER 0x80 /* Responder Channel */
133 #define SL_G_POLICY 41 /* Policy Register */
134 #define SLB_ENBERR 0x01 /* Enable Bus Error */
135 #define SLB_ENNFE 0x02 /* Enable Non-Fatal Error */
136 #define SLB_PDEPTH 0x04 /* Pipe Depth Value */
137 #define SLB_FIXEDPRI 0x08 /* Fixed Pri = 1, Round-robin = 0 */
138 #define SLB_ENBD 0x80 /* Enable Board */
139
140 /* Processor Board specific registers */
141 #define SL_P_PCCHS 34 /* proc control and cache hit status */
142 #define SLB_RES 0x01 /* reset processor */
143 #define SLB_PAUSE 0x02 /* pause processor */
144 #define SLB_HIT0 0x04 /* cache hit set 0 */
145 #define SLB_HIT1 0x08 /* cache hit set 1 */
146 #define SL_P_CACHEPAR 35 /* cache parity error status */
147 #define SLB_CPARMSK 0x3F /* useful bits in this reg */
148 #define SLB_B0ERR 0x01 /* byte 0 error */
149 #define SLB_B1ERR 0x02 /* byte 1 error */
150 #define SLB_B2ERR 0x04 /* byte 2 error */
151 #define SLB_B3ERR 0x08 /* byte 3 error */
152 #define SLB_SET0ERR 0x10 /* set 0 error */
153 #define SLB_SET1ERR 0x20 /* set 1 error */
154 #define SL_P_CLCACHE 36 /* clear cache match bits */
155 #define SL_P_CONTROL 37 /* control bits */
156 #define SLB_ENB0 0x01 /* enable set 0 */
157 #define SLB_ENB1 0x02 /* enable set 1 */
158 #define SLB_INV0 0x04 /* invalidate set 0 (neg) */
159 #define SLB_INV1 0x08 /* invalidate set 1 (neg) */
160 #define SLB_E_WR_BUF 0x10 /* enable write buffer */
161 #define SLB_E_NMI 0x20 /* enable NMIs */
162 #define SLB_IGNOR_BE 0x40 /* ignore bus error */
163 #define SLB_DIS_BE 0x80 /* disable bus error */
164 #define SL_P_LIGHTON 38 /* read ==> turn ON processor LED */
165 #define SL_P_LIGHTOFF 39 /* read ==> turn OFF processor LED */
166
167 /* Symmetry Series processor-specific registers (subject to change) */
168 #define SL_P2_SPEED 4 /* clock speed in MHz */
169 #define SLP_16MHZ 16
170 #define SLP_20MHZ 20
171 #define SLP_25MHZ 25
172 #define SLP_30MHZ 30
173 #define SL_P2_FP_TYPE 5 /* floating-pt type */
174 #define SLP_381 0x01 /* has ns32381 fpu */
175 #define SLP_387 0x01 /* has 80387 (else none) */
176 #define SLP_FPA 0x02 /* has Weitek FPA (else no FPA) */
177 #define SLP_3167 0x08 /* Wombat (3167) (else 1167) */
178 #define SL_P2_BUS_WIDTH 6 /* bus width in bits */
179 #define SL_P2_CACHE_SETS 7 /* no. of cache sets */
180 #define SL_P2_SET_SIZE 8 /* size of each cache set */
181 #define SL_P2_SET_4K 0x03 /* 4Kbyte cache sets */
182 #define SL_P2_SET_8K 0x04 /* 8Kbyte cache sets */
183 #define SL_P2_SET_16K 0x05 /* 16Kbyte cache sets */
184 #define SL_P2_SET_32K 0x06 /* 32Kbyte cache sets */
185 #define SL_P2_SET_64K 0x07 /* 64Kbyte cache sets */
186 #define SL_P2_SET_128K 0x08 /* 128Kbyte cache sets */
187 #define SL_P2_SET_256K 0x09 /* 256Kbyte cache sets */
188 #define SL_P2_CUSTOM 9 /* custom settings for Symmetry */
189 #define SL_P2_BIC_SYNC 0x01 /* force synchronous BIC */
190 #define SL_P2_CMC_FAST 0x02 /* force CMC fast */
191 #define SL_P2_CMC_SYNC 0x04 /* force CMC synchronous */
192 #define SL_P2_FRC_EXT 0x08 /* force extended mode in proc BIC */
193 #define SL_P2_SUB_BLOCK 0x30 /* sub-blocking style */
194 #define SL_P2_NO_SBLOCK 0x00 /* no sub-blocking */
195 #define SL_P2_SBLOCK_8 0x10 /* 8-byte sub-blocking */
196 #define SL_P2_SBLOCK_16 0x20 /* 16-byte sub-blocking */
197 #define SL_P2_BLOCK_32 0x40 /* 32-byte blocks */
198 #define SL_P2_COMPAT 0x80 /* jumper for compatibility mode */
199 #define SL_P2_CUSTOM2 10 /* more custom settings */
200 #define SL_P2_MODELB 0x01 /* this is a model B processor board */
201 #define SL_P2_NO_Q_BD 0x02 /* old layout without Q board */
202 #define SL_P2_INTEL_VER 11 /* version of Intel parts in board */
203 #define SL_P2_NATNL_VER 11 /* same location for Natnl chip revs */
204
205 /* chip version numbers encoded in the config prom */
206 #define SL_P2_WEITEK_VER(slic) (rdslave((slic), SL_P2_CUSTOM)>>4 & 0xF)
207 #define SL_P2_1167 0x00 /* 1163A, 1164, 1165 */
208 #define SL_P2_3167 0x01 /* 3167 (Wombat) */
209
210 #define SL_P2_386_VER(slic) (rdslave((slic),SL_P2_INTEL_VER) & 0xF)
211 #define SL_P2_386_B 0x00 /* B stepping of 386 */
212 #define SL_P2_386_D 0x01 /* D stepping of 386 */
213
214 #define SL_P2_387_VER(slic) (rdslave((slic),SL_P2_INTEL_VER)>>4 & 0xF)
215 #define SL_P2_387_B3 0x00 /* B3 stepping of 387 */
216 #define SL_P2_387_C 0x01 /* C stepping of 387 */
217
218 #define SL_P2_532_VER(slic) (rdslave((slic),SL_P2_NATNL_VER) & 0xF)
219 #define SL_P2_532_B3 0x00 /* B3 stepping of 532 */
220
221 #define SL_P2_381_VER(slic) (rdslave((slic),SL_P2_NATNL_VER)>>4 & 0xF)
222 #define SL_P2_381_B2 0x00 /* B2 stepping of 381 */
223
224 /* Memory Board specific registers */
225 #define SL_M_BSIZE SL_G_VARIATION /* onboard RAM size and type */
226 #define SLB_LTYPE 0x01 /* set == 64k technology */
227 #define SLB_LSIZE 0x30 /* size of onboard RAM */
228 #define SL_M_ACPTB 4 /* accept expansion board patterns */
229 #define SL_M_NUMACPT 8 /* number of accept registers */
230 #define SL_M_ENABLES 33 /* board enables register */
231 #define SLB_MEM_ENB 0x01 /* enable memory array */
232 #define SLB_BE_ENB 0x02 /* bus error enable */
233 #define SLB_REF_ENB 0x10 /* enable memory refresh */
234 #define SLB_INTLV 0x20 /* interleave */
235 #define SL_M_EXP 34 /* expansion board register */
236 #define SLB_R64K 0x01 /* expansion is 64k chips */
237 #define SLB_RTYPE 0x0F /* type of expansion board */
238 #define SLB_RSIZE 0x30 /* size of memory off board */
239 #define SL_M_ECC 35 /* ECC control register */
240 #define SLB_EN_UCE_LOG 0x80 /* enable ECC and UCE log */
241 #define SLB_UCE_OV 0x40 /* UCE overflow */
242 #define SLB_UCE 0x20 /* uncorrectable error */
243 #define SLB_REP_UCE 0x10 /* report UCEs */
244 #define SLB_EN_CE_LOG 0x08 /* enable ECC and CE log */
245 #define SLB_CE_OV 0x04 /* CE overflow */
246 #define SLB_CE 0x02 /* correctable error */
247 #define SLB_REP_CE 0x01 /* report CEs */
248 #define SL_M_MISC 36 /* misc error register */
249 #define SLB_ECC_SWAP 0x80 /* swap in check bits */
250 #define SLB_FLIP_CYCLE 0x10 /* flip cycle type parity */
251 #define SLB_FLIP_B3 0x08 /* flip parity byte 0 */
252 #define SLB_FLIP_B2 0x04 /* flip parity byte 0 */
253 #define SLB_FLIP_B1 0x02 /* flip parity byte 0 */
254 #define SLB_FLIP_B0 0x01 /* flip parity byte 0 */
255 #define SL_M_ADDR 37 /* base address */
256 #define SL_M_REFRESH 38 /* refresh slot */
257 #define SLB_REF0 255 /* immediate refresh */
258 #define SLB_REFL 177 /* refresh last slot */
259 #define SL_M_EADD_L 40 /* address of error */
260 #define SLB_ROW 0x3 /* row address */
261 #define SLB_CNTRL 0x3 /* Controller board */
262 #define SL_M_EADD_M 41
263 #define SL_M_EADD_H 42
264 #define SL_M_ES 43 /* error status */
265 #define SLB_CT 0x07 /* cycle type */
266 #define SLB_BM 0xF0 /* byte marks */
267 #define SL_M_SYNDR 44 /* error syndrome */
268
269 #define REF 7
270 #define WA8 6
271 #define RA4 5
272 #define RA8 4
273 #define WA4H 3
274 #define WA4L 2
275 #define WAPH 1
276 #define WAPL 0
277
278 /* Symmetry Series memory controller registers (subject to change) */
279 #define SL_M2_TOTAL_MB 4 /* total size in Mbytes */
280 #define SL_M2_BUS_WIDTH 5 /* bus width in bits */
281 #define SL_M2_RAM 6 /* ram info */
282 #define SL_M2_RAM_DENS 0x01 /* ram density mask */
283 #define SL_M2_RAM_1MB 0x00 /* 1 Mbit chips */
284 #define SL_M2_RAM_4MB 0x01 /* 4 Mbit chips */
285 #define SL_M2_RAM_POP 0x80 /* ram population mask */
286 #define SL_M2_RAM_FULL 0x00 /* populated by full-banks */
287 #define SL_M2_RAM_HALF 0x80 /* populated by half-banks */
288 #define SL_M2_FILLED 7 /* number of banks filled */
289 #define SL_M2_ACPTB 8 /* first register defining good exp */
290 #define SL_M2_LAST_ACPTB 11 /* last register defining good exp */
291 #define SL_M2_NUMACPT (SL_M2_LAST_ACPTB-SL_M2_ACPTB+1)
292
293 #define SL_M2_ACPTB_VAL1(x) (((x) << 4) & MEM_EXP_CHECK)
294 #define SL_M2_ACPTB_VAL2(x) ((x) & MEM_EXP_CHECK)
295
296 /* Multibus Adaptor specific registers */
297 #define SL_A_CSR 34
298 #define SLB_S0 0x01 /* select 1/4Mb range of Multibus mem */
299 #define SLB_S1 0x02
300 #define SLB_A0 0x04 /* select MB of I/O space */
301 #define SLB_A1 0x08
302 #define SLB_EN_BERR 0x10 /* disable bus errors */
303 #define SLB_EN_MBA 0x20 /* enable MBIF resp; no bus affect */
304
305 /* SCSI/E board specific registers */
306 #define SL_S_ETH_CRC0 4 /* LSB of Ether CRC */
307 #define SL_S_ETH_CRC1 5 /* MSB of Ether CRC */
308 #define SL_S_ETH_ADD0 6 /* LSB of Ether Address */
309 #define SL_S_ETH_ADD1 7 /* 5th MSB of Ether Address */
310 #define SL_S_ETH_ADD2 8 /* 4th MSB of Ether Address */
311 #define SL_S_ETH_ADD3 9 /* 3rd MSB of Ether Address */
312 #define SL_S_ETH_ADD4 10 /* 2nd MSB of Ether Address */
313 #define SL_S_ETH_ADD5 11 /* MSB of Ether Address */
314 #define SL_S_FLAGS 12 /* slave register of flags */
315 #define SLF_FUJITSU 0x01 /* Fujitsu 8795B on SCED */
316 #define SL_S_DIAG_STAT 34 /* diagnostic status register */
317 #define SL_S_RESET 35 /* hard reset of SCSI/Ether board */
318
319 /* Clock/Arbitration board specific registers */
320 #define SL_C_TRIG 34 /* W scope trigger */
321 #define SL_C_FPTYPE 36 /* Front panel type */
322 #define SL_C_DIAG_CTRL 37 /* Diagnostics and control register */
323 #define SLB_DCMASK 0x0F /* Mask for useful bits */
324 #define SLB_EN_BE 0x01 /* Enable bus error reporting */
325 #define SLB_OPT_PRI 0x02 /* Use optional slot priorities */
326 #define SLB_EN_DIAG 0x04 /* Enable diagnostic bus requests */
327 #define SLB_DIAG_VGNT 0x08 /* Valid grant clock for diagnostics */
328 #define SL_C_LOPRI_GNT 38 /* Encoded low-priority bus grant */
329 #define SLB_GNTMASK 0x0F /* Mask for encoded grants */
330 #define SLB_UPPERGNT 0x08 /* Select upper eight grants */
331 #define SLB_GSEL 0x10 /* This priority's group select */
332 #define SLB_XPENABLE 0x20 /* This priority's enable - INVERTED! */
333 #define SLB_LOWERGNT 0x40 /* Select lower eight grants */
334 #define SLB_XPEQUAL 0x80 /* This priority's equal - INVERTED! */
335 #define SL_C_HIPRI_GNT 39 /* Encoded high-priority bus grant */
336 /* Uses same bit masks as register 38 */
337 #define SL_C_LOPRI_REQ0 40 /* Low-priority bus requests 0-7 */
338 #define SL_C_LOPRI_REQ1 41 /* Low-priority bus requests 8-15 */
339 #define SL_C_HIPRI_REQ0 42 /* High-priority bus requests 0-7 */
340 #define SL_C_HIPRI_REQ1 43 /* High-priority bus requests 8-15 */
341 #define SL_C_DM_START0 44 /* Start data mover using table 0 */
342 #define SL_C_DM_START1 45 /* Start data mover using table 1 */
343 #define SL_C_DM_BA0 46 /* LSB data mover base address */
344 #define SL_C_DM_BA1 47 /* MSB data mover base address */
345
346 #define SL_C_SYSID0 56 /* LSB of system ID number */
347 #define SL_C_SYSID1 57 /* 3rd MSB of system ID number */
348 #define SL_C_SYSID2 58 /* 2nd MSB of system ID number */
349 #define SL_C_SYSID3 59 /* MSB of system ID number */
350 #define SL_C_BP55 60 /* Should always be 0x55 */
351 #define SL_C_BPAA 61 /* Should always be 0xAA */
352 #define SL_C_CHKSUM 62 /* 2's comp checksum of SYSID prom */
353 /*
354 * There are 48 leds starting at slic address SL_C_FP_LIGHT
355 * Each pair of addresses represent 1 led. The even turns off the led.
356 * The odd turns on the led.
357 */
358 #define SL_C_FP_LIGHT 128 /* Front panel led array */
359 #define SL_C_IO_ACTIVE 229 /* I/O (disk) activity led */
360 #define SL_C_IO_ONLINE 225 /* I/O (disk) online led */
361 #define SL_C_IO_ERROR 227 /* I/O (disk) error led */
362
363 /* ZDC board specific registers */
364 #define SL_Z_VERSION 4 /* FW Generation */
365 #define SL_Z_CNTRL 64 /* SLIC to HSC Control register */
366 #define SLB_COMM 0x0F /* mask for comm lines */
367 #define SLB_UNRESET 0x10 /* 0 - reset, 1 - unreset */
368 #define SLB_MODEMASK 0xC0 /* HSC Mode mask */
369 #define SLB_STOP_EW 0x40 /* Stop, enable WREG on YBUS */
370 #define SLB_RUN_SP 0x80 /* Run, Stop on Pause */
371 #define SLB_RUN_RP 0xC0 /* Run, Run on Pause */
372 #define SL_Z_STATUS SL_Z_CNTRL /* SLIC Status register */
373 #define SLB_ZPARERR 0x10 /* ZDC Parity Error */
374 #define SLB_HSCRUNNING 0x20 /* HSC Running */
375 #define SLB_COMM0 0x40 /* Comm0 to HSC */
376 #define SLB_EEREADY 0x80 /* EEPROM Ready */
377 #define SL_Z_UPC0_3 65 /* 2910 uPC address bits 0-3 */
378 #define SL_Z_UPC4_A 66 /* 2910 uPC address bits 4-10 */
379 #define SL_Z_EEBANK 67 /* Most significant address bits 7-14 */
380 #define SL_Z_WREG0_3 69 /* WREG address bits 0-3 */
381 #define SL_Z_WREG4_A 70 /* WREG address bits 4-10 */
382 #define SL_Z_SCANSR 96 /* SCAN Shift Register */
383 #define SL_Z_SHADTOWCS 97 /* Shadow to WCS command */
384 #define SL_Z_PREGTOSHAD 98 /* PREG to Shadow command */
385 #define SL_Z_KBUSTOSHAD 99 /* KBUS to Shadow command */
386 #define SL_Z_SHADTOPREG 101 /* Shadow to PREG command */
387 #define SL_Z_WCSTOPREG 102 /* WCS data to PREG command */
388 #define SL_Z_STARTHSC 103 /* Start HSC command */
389 #define SL_Z_EEWINDOW 128 /* Base 128 byte window into EEPROM */
390
391 #endif /* _SQT_SLIREG_H_ */
Cache object: 4fd03862d8445e3ed63bf74cf8ef96e2
|