1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19 #ifndef _BCM1480_SCD_H
20 #define _BCM1480_SCD_H
21
22 #include <asm/sibyte/sb1250_defs.h>
23
24
25
26
27
28 #include <asm/sibyte/sb1250_scd.h>
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64 #define K_SYS_PART_BCM1480 0x1406
65 #define K_SYS_PART_BCM1280 0x1206
66 #define K_SYS_PART_BCM1455 0x1407
67 #define K_SYS_PART_BCM1255 0x1257
68 #define K_SYS_PART_BCM1158 0x1156
69
70
71
72
73
74
75
76
77
78
79
80
81 #define M_BCM1480_SYS_RESERVED0 _SB_MAKEMASK1(0)
82 #define M_BCM1480_SYS_HT_MINRSTCNT _SB_MAKEMASK1(1)
83 #define M_BCM1480_SYS_RESERVED2 _SB_MAKEMASK1(2)
84 #define M_BCM1480_SYS_RESERVED3 _SB_MAKEMASK1(3)
85 #define M_BCM1480_SYS_RESERVED4 _SB_MAKEMASK1(4)
86 #define M_BCM1480_SYS_IOB_DIV _SB_MAKEMASK1(5)
87
88 #define S_BCM1480_SYS_PLL_DIV _SB_MAKE64(6)
89 #define M_BCM1480_SYS_PLL_DIV _SB_MAKEMASK(5, S_BCM1480_SYS_PLL_DIV)
90 #define V_BCM1480_SYS_PLL_DIV(x) _SB_MAKEVALUE(x, S_BCM1480_SYS_PLL_DIV)
91 #define G_BCM1480_SYS_PLL_DIV(x) _SB_GETVALUE(x, S_BCM1480_SYS_PLL_DIV, M_BCM1480_SYS_PLL_DIV)
92
93 #define S_BCM1480_SYS_SW_DIV _SB_MAKE64(11)
94 #define M_BCM1480_SYS_SW_DIV _SB_MAKEMASK(5, S_BCM1480_SYS_SW_DIV)
95 #define V_BCM1480_SYS_SW_DIV(x) _SB_MAKEVALUE(x, S_BCM1480_SYS_SW_DIV)
96 #define G_BCM1480_SYS_SW_DIV(x) _SB_GETVALUE(x, S_BCM1480_SYS_SW_DIV, M_BCM1480_SYS_SW_DIV)
97
98 #define M_BCM1480_SYS_PCMCIA_ENABLE _SB_MAKEMASK1(16)
99 #define M_BCM1480_SYS_DUART1_ENABLE _SB_MAKEMASK1(17)
100
101 #define S_BCM1480_SYS_BOOT_MODE _SB_MAKE64(18)
102 #define M_BCM1480_SYS_BOOT_MODE _SB_MAKEMASK(2, S_BCM1480_SYS_BOOT_MODE)
103 #define V_BCM1480_SYS_BOOT_MODE(x) _SB_MAKEVALUE(x, S_BCM1480_SYS_BOOT_MODE)
104 #define G_BCM1480_SYS_BOOT_MODE(x) _SB_GETVALUE(x, S_BCM1480_SYS_BOOT_MODE, M_BCM1480_SYS_BOOT_MODE)
105 #define K_BCM1480_SYS_BOOT_MODE_ROM32 0
106 #define K_BCM1480_SYS_BOOT_MODE_ROM8 1
107 #define K_BCM1480_SYS_BOOT_MODE_SMBUS_SMALL 2
108 #define K_BCM1480_SYS_BOOT_MODE_SMBUS_BIG 3
109 #define M_BCM1480_SYS_BOOT_MODE_SMBUS _SB_MAKEMASK1(19)
110
111 #define M_BCM1480_SYS_PCI_HOST _SB_MAKEMASK1(20)
112 #define M_BCM1480_SYS_PCI_ARBITER _SB_MAKEMASK1(21)
113 #define M_BCM1480_SYS_BIG_ENDIAN _SB_MAKEMASK1(22)
114 #define M_BCM1480_SYS_GENCLK_EN _SB_MAKEMASK1(23)
115 #define M_BCM1480_SYS_GEN_PARITY_EN _SB_MAKEMASK1(24)
116 #define M_BCM1480_SYS_RESERVED25 _SB_MAKEMASK1(25)
117
118 #define S_BCM1480_SYS_CONFIG 26
119 #define M_BCM1480_SYS_CONFIG _SB_MAKEMASK(6, S_BCM1480_SYS_CONFIG)
120 #define V_BCM1480_SYS_CONFIG(x) _SB_MAKEVALUE(x, S_BCM1480_SYS_CONFIG)
121 #define G_BCM1480_SYS_CONFIG(x) _SB_GETVALUE(x, S_BCM1480_SYS_CONFIG, M_BCM1480_SYS_CONFIG)
122
123 #define M_BCM1480_SYS_RESERVED32 _SB_MAKEMASK(32, 15)
124
125 #define S_BCM1480_SYS_NODEID 47
126 #define M_BCM1480_SYS_NODEID _SB_MAKEMASK(4, S_BCM1480_SYS_NODEID)
127 #define V_BCM1480_SYS_NODEID(x) _SB_MAKEVALUE(x, S_BCM1480_SYS_NODEID)
128 #define G_BCM1480_SYS_NODEID(x) _SB_GETVALUE(x, S_BCM1480_SYS_NODEID, M_BCM1480_SYS_NODEID)
129
130 #define M_BCM1480_SYS_CCNUMA_EN _SB_MAKEMASK1(51)
131 #define M_BCM1480_SYS_CPU_RESET_0 _SB_MAKEMASK1(52)
132 #define M_BCM1480_SYS_CPU_RESET_1 _SB_MAKEMASK1(53)
133 #define M_BCM1480_SYS_CPU_RESET_2 _SB_MAKEMASK1(54)
134 #define M_BCM1480_SYS_CPU_RESET_3 _SB_MAKEMASK1(55)
135 #define S_BCM1480_SYS_DISABLECPU0 56
136 #define M_BCM1480_SYS_DISABLECPU0 _SB_MAKEMASK1(S_BCM1480_SYS_DISABLECPU0)
137 #define S_BCM1480_SYS_DISABLECPU1 57
138 #define M_BCM1480_SYS_DISABLECPU1 _SB_MAKEMASK1(S_BCM1480_SYS_DISABLECPU1)
139 #define S_BCM1480_SYS_DISABLECPU2 58
140 #define M_BCM1480_SYS_DISABLECPU2 _SB_MAKEMASK1(S_BCM1480_SYS_DISABLECPU2)
141 #define S_BCM1480_SYS_DISABLECPU3 59
142 #define M_BCM1480_SYS_DISABLECPU3 _SB_MAKEMASK1(S_BCM1480_SYS_DISABLECPU3)
143
144 #define M_BCM1480_SYS_SB_SOFTRES _SB_MAKEMASK1(60)
145 #define M_BCM1480_SYS_EXT_RESET _SB_MAKEMASK1(61)
146 #define M_BCM1480_SYS_SYSTEM_RESET _SB_MAKEMASK1(62)
147 #define M_BCM1480_SYS_SW_FLAG _SB_MAKEMASK1(63)
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183 #define M_BCM1480_SCD_WDOG_ENABLE _SB_MAKEMASK1(0)
184
185 #define S_BCM1480_SCD_WDOG_RESET_TYPE 2
186 #define M_BCM1480_SCD_WDOG_RESET_TYPE _SB_MAKEMASK(5, S_BCM1480_SCD_WDOG_RESET_TYPE)
187 #define V_BCM1480_SCD_WDOG_RESET_TYPE(x) _SB_MAKEVALUE(x, S_BCM1480_SCD_WDOG_RESET_TYPE)
188 #define G_BCM1480_SCD_WDOG_RESET_TYPE(x) _SB_GETVALUE(x, S_BCM1480_SCD_WDOG_RESET_TYPE, M_BCM1480_SCD_WDOG_RESET_TYPE)
189
190 #define K_BCM1480_SCD_WDOG_RESET_FULL 0
191 #define K_BCM1480_SCD_WDOG_RESET_SOFT 1
192 #define K_BCM1480_SCD_WDOG_RESET_CPU0 3
193 #define K_BCM1480_SCD_WDOG_RESET_CPU1 5
194 #define K_BCM1480_SCD_WDOG_RESET_CPU2 9
195 #define K_BCM1480_SCD_WDOG_RESET_CPU3 17
196 #define K_BCM1480_SCD_WDOG_RESET_ALL_CPUS 31
197
198
199 #define M_BCM1480_SCD_WDOG_HAS_RESET _SB_MAKEMASK1(8)
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233 #define S_SPC_CFG_SRC4 32
234 #define M_SPC_CFG_SRC4 _SB_MAKEMASK(8, S_SPC_CFG_SRC4)
235 #define V_SPC_CFG_SRC4(x) _SB_MAKEVALUE(x, S_SPC_CFG_SRC4)
236 #define G_SPC_CFG_SRC4(x) _SB_GETVALUE(x, S_SPC_CFG_SRC4, M_SPC_CFG_SRC4)
237
238 #define S_SPC_CFG_SRC5 40
239 #define M_SPC_CFG_SRC5 _SB_MAKEMASK(8, S_SPC_CFG_SRC5)
240 #define V_SPC_CFG_SRC5(x) _SB_MAKEVALUE(x, S_SPC_CFG_SRC5)
241 #define G_SPC_CFG_SRC5(x) _SB_GETVALUE(x, S_SPC_CFG_SRC5, M_SPC_CFG_SRC5)
242
243 #define S_SPC_CFG_SRC6 48
244 #define M_SPC_CFG_SRC6 _SB_MAKEMASK(8, S_SPC_CFG_SRC6)
245 #define V_SPC_CFG_SRC6(x) _SB_MAKEVALUE(x, S_SPC_CFG_SRC6)
246 #define G_SPC_CFG_SRC6(x) _SB_GETVALUE(x, S_SPC_CFG_SRC6, M_SPC_CFG_SRC6)
247
248 #define S_SPC_CFG_SRC7 56
249 #define M_SPC_CFG_SRC7 _SB_MAKEMASK(8, S_SPC_CFG_SRC7)
250 #define V_SPC_CFG_SRC7(x) _SB_MAKEVALUE(x, S_SPC_CFG_SRC7)
251 #define G_SPC_CFG_SRC7(x) _SB_GETVALUE(x, S_SPC_CFG_SRC7, M_SPC_CFG_SRC7)
252
253
254
255
256
257
258 #define M_BCM1480_SPC_CFG_CLEAR _SB_MAKEMASK1(0)
259 #define M_BCM1480_SPC_CFG_ENABLE _SB_MAKEMASK1(1)
260 #if SIBYTE_HDR_FEATURE_CHIP(1480)
261 #define M_SPC_CFG_CLEAR M_BCM1480_SPC_CFG_CLEAR
262 #define M_SPC_CFG_ENABLE M_BCM1480_SPC_CFG_ENABLE
263 #endif
264
265
266
267
268
269
270 #define S_BCM1480_SPC_CNT_COUNT 0
271 #define M_BCM1480_SPC_CNT_COUNT _SB_MAKEMASK(40, S_BCM1480_SPC_CNT_COUNT)
272 #define V_BCM1480_SPC_CNT_COUNT(x) _SB_MAKEVALUE(x, S_BCM1480_SPC_CNT_COUNT)
273 #define G_BCM1480_SPC_CNT_COUNT(x) _SB_GETVALUE(x, S_BCM1480_SPC_CNT_COUNT, M_BCM1480_SPC_CNT_COUNT)
274
275 #define M_BCM1480_SPC_CNT_OFLOW _SB_MAKEMASK1(40)
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312 #define M_BCM1480_ATRAP_INDEX _SB_MAKEMASK(4, 0)
313 #define M_BCM1480_ATRAP_ADDRESS _SB_MAKEMASK(40, 0)
314
315 #define S_BCM1480_ATRAP_CFG_CNT 0
316 #define M_BCM1480_ATRAP_CFG_CNT _SB_MAKEMASK(3, S_BCM1480_ATRAP_CFG_CNT)
317 #define V_BCM1480_ATRAP_CFG_CNT(x) _SB_MAKEVALUE(x, S_BCM1480_ATRAP_CFG_CNT)
318 #define G_BCM1480_ATRAP_CFG_CNT(x) _SB_GETVALUE(x, S_BCM1480_ATRAP_CFG_CNT, M_BCM1480_ATRAP_CFG_CNT)
319
320 #define M_BCM1480_ATRAP_CFG_WRITE _SB_MAKEMASK1(3)
321 #define M_BCM1480_ATRAP_CFG_ALL _SB_MAKEMASK1(4)
322 #define M_BCM1480_ATRAP_CFG_INV _SB_MAKEMASK1(5)
323 #define M_BCM1480_ATRAP_CFG_USESRC _SB_MAKEMASK1(6)
324 #define M_BCM1480_ATRAP_CFG_SRCINV _SB_MAKEMASK1(7)
325
326 #define S_BCM1480_ATRAP_CFG_AGENTID 8
327 #define M_BCM1480_ATRAP_CFG_AGENTID _SB_MAKEMASK(4, S_BCM1480_ATRAP_CFG_AGENTID)
328 #define V_BCM1480_ATRAP_CFG_AGENTID(x) _SB_MAKEVALUE(x, S_BCM1480_ATRAP_CFG_AGENTID)
329 #define G_BCM1480_ATRAP_CFG_AGENTID(x) _SB_GETVALUE(x, S_BCM1480_ATRAP_CFG_AGENTID, M_BCM1480_ATRAP_CFG_AGENTID)
330
331
332 #define K_BCM1480_BUS_AGENT_CPU0 0
333 #define K_BCM1480_BUS_AGENT_CPU1 1
334 #define K_BCM1480_BUS_AGENT_NC 2
335 #define K_BCM1480_BUS_AGENT_IOB 3
336 #define K_BCM1480_BUS_AGENT_SCD 4
337 #define K_BCM1480_BUS_AGENT_L2C 6
338 #define K_BCM1480_BUS_AGENT_MC 7
339 #define K_BCM1480_BUS_AGENT_CPU2 8
340 #define K_BCM1480_BUS_AGENT_CPU3 9
341 #define K_BCM1480_BUS_AGENT_PM 10
342
343 #define S_BCM1480_ATRAP_CFG_CATTR 12
344 #define M_BCM1480_ATRAP_CFG_CATTR _SB_MAKEMASK(2, S_BCM1480_ATRAP_CFG_CATTR)
345 #define V_BCM1480_ATRAP_CFG_CATTR(x) _SB_MAKEVALUE(x, S_BCM1480_ATRAP_CFG_CATTR)
346 #define G_BCM1480_ATRAP_CFG_CATTR(x) _SB_GETVALUE(x, S_BCM1480_ATRAP_CFG_CATTR, M_BCM1480_ATRAP_CFG_CATTR)
347
348 #define K_BCM1480_ATRAP_CFG_CATTR_IGNORE 0
349 #define K_BCM1480_ATRAP_CFG_CATTR_UNC 1
350 #define K_BCM1480_ATRAP_CFG_CATTR_NONCOH 2
351 #define K_BCM1480_ATRAP_CFG_CATTR_COHERENT 3
352
353 #define M_BCM1480_ATRAP_CFG_CATTRINV _SB_MAKEMASK1(14)
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369 #define M_BCM1480_SCD_TRSEQ_TID_MATCH_EN _SB_MAKEMASK1(25)
370
371 #define S_BCM1480_SCD_TRSEQ_SWFUNC 26
372 #define M_BCM1480_SCD_TRSEQ_SWFUNC _SB_MAKEMASK(2, S_BCM1480_SCD_TRSEQ_SWFUNC)
373 #define V_BCM1480_SCD_TRSEQ_SWFUNC(x) _SB_MAKEVALUE(x, S_BCM1480_SCD_TRSEQ_SWFUNC)
374 #define G_BCM1480_SCD_TRSEQ_SWFUNC(x) _SB_GETVALUE(x, S_BCM1480_SCD_TRSEQ_SWFUNC, M_BCM1480_SCD_TRSEQ_SWFUNC)
375
376
377
378
379
380
381
382
383
384 #define S_BCM1480_SCD_TRACE_CFG_MODE 16
385 #define M_BCM1480_SCD_TRACE_CFG_MODE _SB_MAKEMASK(2, S_BCM1480_SCD_TRACE_CFG_MODE)
386 #define V_BCM1480_SCD_TRACE_CFG_MODE(x) _SB_MAKEVALUE(x, S_BCM1480_SCD_TRACE_CFG_MODE)
387 #define G_BCM1480_SCD_TRACE_CFG_MODE(x) _SB_GETVALUE(x, S_BCM1480_SCD_TRACE_CFG_MODE, M_BCM1480_SCD_TRACE_CFG_MODE)
388
389 #define K_BCM1480_SCD_TRACE_CFG_MODE_BLOCKERS 0
390 #define K_BCM1480_SCD_TRACE_CFG_MODE_BYTEEN_INT 1
391 #define K_BCM1480_SCD_TRACE_CFG_MODE_FLOW_ID 2
392
393 #endif