Pavona Software APIs
top_dragonfly.h
Go to the documentation of this file.
1// Copyright lowRISC contributors (OpenTitan project).
2// Licensed under the Apache License, Version 2.0, see LICENSE for details.
3// SPDX-License-Identifier: Apache-2.0
4//
5// ------------------- W A R N I N G: A U T O - G E N E R A T E D C O D E !! -------------------//
6// PLEASE DO NOT HAND-EDIT THIS FILE. IT HAS BEEN AUTO-GENERATED WITH THE FOLLOWING COMMAND:
7// util/gen_top_sw.py -t hw/top_dragonfly/data/autogen/top_dragonfly.gen.hjson
8
9#ifndef OPENTITAN_HW_TOP_DRAGONFLY_SW_AUTOGEN_TOP_DRAGONFLY_H_
10#define OPENTITAN_HW_TOP_DRAGONFLY_SW_AUTOGEN_TOP_DRAGONFLY_H_
11
12/**
13 * @file
14 * @brief Top-specific Definitions
15 *
16 * This file contains preprocessor and type definitions for use within the
17 * device C/C++ codebase.
18 *
19 * These definitions are for information that depends on the top-specific chip
20 * configuration, which includes:
21 * - Device Memory Information (for Peripherals and Memory)
22 * - PLIC Interrupt ID Names and Source Mappings
23 * - Alert ID Names and Source Mappings
24 * - Pinmux Pin/Select Names
25 * - Power Manager Wakeups
26 */
27
28#ifdef __cplusplus
29extern "C" {
30#endif
31
32/**
33 * Peripheral base address for uart0 in top dragonfly.
34 *
35 * This should be used with #mmio_region_from_addr to access the memory-mapped
36 * registers associated with the peripheral (usually via a DIF).
37 */
38#define TOP_DRAGONFLY_UART0_BASE_ADDR 0x30010000u
39
40/**
41 * Peripheral size for uart0 in top dragonfly.
42 *
43 * This is the size (in bytes) of the peripheral's reserved memory area. All
44 * memory-mapped registers associated with this peripheral should have an
45 * address between #TOP_DRAGONFLY_UART0_BASE_ADDR and
46 * `TOP_DRAGONFLY_UART0_BASE_ADDR + TOP_DRAGONFLY_UART0_SIZE_BYTES`.
47 */
48#define TOP_DRAGONFLY_UART0_SIZE_BYTES 0x40u
49
50/**
51 * Peripheral base address for gpio in top dragonfly.
52 *
53 * This should be used with #mmio_region_from_addr to access the memory-mapped
54 * registers associated with the peripheral (usually via a DIF).
55 */
56#define TOP_DRAGONFLY_GPIO_BASE_ADDR 0x30000000u
57
58/**
59 * Peripheral size for gpio in top dragonfly.
60 *
61 * This is the size (in bytes) of the peripheral's reserved memory area. All
62 * memory-mapped registers associated with this peripheral should have an
63 * address between #TOP_DRAGONFLY_GPIO_BASE_ADDR and
64 * `TOP_DRAGONFLY_GPIO_BASE_ADDR + TOP_DRAGONFLY_GPIO_SIZE_BYTES`.
65 */
66#define TOP_DRAGONFLY_GPIO_SIZE_BYTES 0x100u
67
68/**
69 * Peripheral base address for spi_device in top dragonfly.
70 *
71 * This should be used with #mmio_region_from_addr to access the memory-mapped
72 * registers associated with the peripheral (usually via a DIF).
73 */
74#define TOP_DRAGONFLY_SPI_DEVICE_BASE_ADDR 0x30310000u
75
76/**
77 * Peripheral size for spi_device in top dragonfly.
78 *
79 * This is the size (in bytes) of the peripheral's reserved memory area. All
80 * memory-mapped registers associated with this peripheral should have an
81 * address between #TOP_DRAGONFLY_SPI_DEVICE_BASE_ADDR and
82 * `TOP_DRAGONFLY_SPI_DEVICE_BASE_ADDR + TOP_DRAGONFLY_SPI_DEVICE_SIZE_BYTES`.
83 */
84#define TOP_DRAGONFLY_SPI_DEVICE_SIZE_BYTES 0x2000u
85
86/**
87 * Peripheral base address for i2c0 in top dragonfly.
88 *
89 * This should be used with #mmio_region_from_addr to access the memory-mapped
90 * registers associated with the peripheral (usually via a DIF).
91 */
92#define TOP_DRAGONFLY_I2C0_BASE_ADDR 0x30080000u
93
94/**
95 * Peripheral size for i2c0 in top dragonfly.
96 *
97 * This is the size (in bytes) of the peripheral's reserved memory area. All
98 * memory-mapped registers associated with this peripheral should have an
99 * address between #TOP_DRAGONFLY_I2C0_BASE_ADDR and
100 * `TOP_DRAGONFLY_I2C0_BASE_ADDR + TOP_DRAGONFLY_I2C0_SIZE_BYTES`.
101 */
102#define TOP_DRAGONFLY_I2C0_SIZE_BYTES 0x80u
103
104/**
105 * Peripheral base address for rv_timer in top dragonfly.
106 *
107 * This should be used with #mmio_region_from_addr to access the memory-mapped
108 * registers associated with the peripheral (usually via a DIF).
109 */
110#define TOP_DRAGONFLY_RV_TIMER_BASE_ADDR 0x30100000u
111
112/**
113 * Peripheral size for rv_timer in top dragonfly.
114 *
115 * This is the size (in bytes) of the peripheral's reserved memory area. All
116 * memory-mapped registers associated with this peripheral should have an
117 * address between #TOP_DRAGONFLY_RV_TIMER_BASE_ADDR and
118 * `TOP_DRAGONFLY_RV_TIMER_BASE_ADDR + TOP_DRAGONFLY_RV_TIMER_SIZE_BYTES`.
119 */
120#define TOP_DRAGONFLY_RV_TIMER_SIZE_BYTES 0x200u
121
122/**
123 * Peripheral base address for core device on otp_ctrl in top dragonfly.
124 *
125 * This should be used with #mmio_region_from_addr to access the memory-mapped
126 * registers associated with the peripheral (usually via a DIF).
127 */
128#define TOP_DRAGONFLY_OTP_CTRL_CORE_BASE_ADDR 0x30130000u
129
130/**
131 * Peripheral size for core device on otp_ctrl in top dragonfly.
132 *
133 * This is the size (in bytes) of the peripheral's reserved memory area. All
134 * memory-mapped registers associated with this peripheral should have an
135 * address between #TOP_DRAGONFLY_OTP_CTRL_CORE_BASE_ADDR and
136 * `TOP_DRAGONFLY_OTP_CTRL_CORE_BASE_ADDR + TOP_DRAGONFLY_OTP_CTRL_CORE_SIZE_BYTES`.
137 */
138#define TOP_DRAGONFLY_OTP_CTRL_CORE_SIZE_BYTES 0x10000u
139
140/**
141 * Peripheral base address for prim device on otp_macro in top dragonfly.
142 *
143 * This should be used with #mmio_region_from_addr to access the memory-mapped
144 * registers associated with the peripheral (usually via a DIF).
145 */
146#define TOP_DRAGONFLY_OTP_MACRO_PRIM_BASE_ADDR 0x30140000u
147
148/**
149 * Peripheral size for prim device on otp_macro in top dragonfly.
150 *
151 * This is the size (in bytes) of the peripheral's reserved memory area. All
152 * memory-mapped registers associated with this peripheral should have an
153 * address between #TOP_DRAGONFLY_OTP_MACRO_PRIM_BASE_ADDR and
154 * `TOP_DRAGONFLY_OTP_MACRO_PRIM_BASE_ADDR + TOP_DRAGONFLY_OTP_MACRO_PRIM_SIZE_BYTES`.
155 */
156#define TOP_DRAGONFLY_OTP_MACRO_PRIM_SIZE_BYTES 0x20u
157
158/**
159 * Peripheral base address for regs device on lc_ctrl in top dragonfly.
160 *
161 * This should be used with #mmio_region_from_addr to access the memory-mapped
162 * registers associated with the peripheral (usually via a DIF).
163 */
164#define TOP_DRAGONFLY_LC_CTRL_REGS_BASE_ADDR 0x30150000u
165
166/**
167 * Peripheral size for regs device on lc_ctrl in top dragonfly.
168 *
169 * This is the size (in bytes) of the peripheral's reserved memory area. All
170 * memory-mapped registers associated with this peripheral should have an
171 * address between #TOP_DRAGONFLY_LC_CTRL_REGS_BASE_ADDR and
172 * `TOP_DRAGONFLY_LC_CTRL_REGS_BASE_ADDR + TOP_DRAGONFLY_LC_CTRL_REGS_SIZE_BYTES`.
173 */
174#define TOP_DRAGONFLY_LC_CTRL_REGS_SIZE_BYTES 0x100u
175
176/**
177 * Peripheral base address for alert_handler in top dragonfly.
178 *
179 * This should be used with #mmio_region_from_addr to access the memory-mapped
180 * registers associated with the peripheral (usually via a DIF).
181 */
182#define TOP_DRAGONFLY_ALERT_HANDLER_BASE_ADDR 0x30160000u
183
184/**
185 * Peripheral size for alert_handler in top dragonfly.
186 *
187 * This is the size (in bytes) of the peripheral's reserved memory area. All
188 * memory-mapped registers associated with this peripheral should have an
189 * address between #TOP_DRAGONFLY_ALERT_HANDLER_BASE_ADDR and
190 * `TOP_DRAGONFLY_ALERT_HANDLER_BASE_ADDR + TOP_DRAGONFLY_ALERT_HANDLER_SIZE_BYTES`.
191 */
192#define TOP_DRAGONFLY_ALERT_HANDLER_SIZE_BYTES 0x800u
193
194/**
195 * Peripheral base address for spi_host0 in top dragonfly.
196 *
197 * This should be used with #mmio_region_from_addr to access the memory-mapped
198 * registers associated with the peripheral (usually via a DIF).
199 */
200#define TOP_DRAGONFLY_SPI_HOST0_BASE_ADDR 0x30300000u
201
202/**
203 * Peripheral size for spi_host0 in top dragonfly.
204 *
205 * This is the size (in bytes) of the peripheral's reserved memory area. All
206 * memory-mapped registers associated with this peripheral should have an
207 * address between #TOP_DRAGONFLY_SPI_HOST0_BASE_ADDR and
208 * `TOP_DRAGONFLY_SPI_HOST0_BASE_ADDR + TOP_DRAGONFLY_SPI_HOST0_SIZE_BYTES`.
209 */
210#define TOP_DRAGONFLY_SPI_HOST0_SIZE_BYTES 0x40u
211
212/**
213 * Peripheral base address for pwrmgr_aon in top dragonfly.
214 *
215 * This should be used with #mmio_region_from_addr to access the memory-mapped
216 * registers associated with the peripheral (usually via a DIF).
217 */
218#define TOP_DRAGONFLY_PWRMGR_AON_BASE_ADDR 0x30400000u
219
220/**
221 * Peripheral size for pwrmgr_aon in top dragonfly.
222 *
223 * This is the size (in bytes) of the peripheral's reserved memory area. All
224 * memory-mapped registers associated with this peripheral should have an
225 * address between #TOP_DRAGONFLY_PWRMGR_AON_BASE_ADDR and
226 * `TOP_DRAGONFLY_PWRMGR_AON_BASE_ADDR + TOP_DRAGONFLY_PWRMGR_AON_SIZE_BYTES`.
227 */
228#define TOP_DRAGONFLY_PWRMGR_AON_SIZE_BYTES 0x80u
229
230/**
231 * Peripheral base address for rstmgr_aon in top dragonfly.
232 *
233 * This should be used with #mmio_region_from_addr to access the memory-mapped
234 * registers associated with the peripheral (usually via a DIF).
235 */
236#define TOP_DRAGONFLY_RSTMGR_AON_BASE_ADDR 0x30410000u
237
238/**
239 * Peripheral size for rstmgr_aon in top dragonfly.
240 *
241 * This is the size (in bytes) of the peripheral's reserved memory area. All
242 * memory-mapped registers associated with this peripheral should have an
243 * address between #TOP_DRAGONFLY_RSTMGR_AON_BASE_ADDR and
244 * `TOP_DRAGONFLY_RSTMGR_AON_BASE_ADDR + TOP_DRAGONFLY_RSTMGR_AON_SIZE_BYTES`.
245 */
246#define TOP_DRAGONFLY_RSTMGR_AON_SIZE_BYTES 0x80u
247
248/**
249 * Peripheral base address for clkmgr_aon in top dragonfly.
250 *
251 * This should be used with #mmio_region_from_addr to access the memory-mapped
252 * registers associated with the peripheral (usually via a DIF).
253 */
254#define TOP_DRAGONFLY_CLKMGR_AON_BASE_ADDR 0x30420000u
255
256/**
257 * Peripheral size for clkmgr_aon in top dragonfly.
258 *
259 * This is the size (in bytes) of the peripheral's reserved memory area. All
260 * memory-mapped registers associated with this peripheral should have an
261 * address between #TOP_DRAGONFLY_CLKMGR_AON_BASE_ADDR and
262 * `TOP_DRAGONFLY_CLKMGR_AON_BASE_ADDR + TOP_DRAGONFLY_CLKMGR_AON_SIZE_BYTES`.
263 */
264#define TOP_DRAGONFLY_CLKMGR_AON_SIZE_BYTES 0x40u
265
266/**
267 * Peripheral base address for pinmux_aon in top dragonfly.
268 *
269 * This should be used with #mmio_region_from_addr to access the memory-mapped
270 * registers associated with the peripheral (usually via a DIF).
271 */
272#define TOP_DRAGONFLY_PINMUX_AON_BASE_ADDR 0x30460000u
273
274/**
275 * Peripheral size for pinmux_aon in top dragonfly.
276 *
277 * This is the size (in bytes) of the peripheral's reserved memory area. All
278 * memory-mapped registers associated with this peripheral should have an
279 * address between #TOP_DRAGONFLY_PINMUX_AON_BASE_ADDR and
280 * `TOP_DRAGONFLY_PINMUX_AON_BASE_ADDR + TOP_DRAGONFLY_PINMUX_AON_SIZE_BYTES`.
281 */
282#define TOP_DRAGONFLY_PINMUX_AON_SIZE_BYTES 0x800u
283
284/**
285 * Peripheral base address for aon_timer_aon in top dragonfly.
286 *
287 * This should be used with #mmio_region_from_addr to access the memory-mapped
288 * registers associated with the peripheral (usually via a DIF).
289 */
290#define TOP_DRAGONFLY_AON_TIMER_AON_BASE_ADDR 0x30470000u
291
292/**
293 * Peripheral size for aon_timer_aon in top dragonfly.
294 *
295 * This is the size (in bytes) of the peripheral's reserved memory area. All
296 * memory-mapped registers associated with this peripheral should have an
297 * address between #TOP_DRAGONFLY_AON_TIMER_AON_BASE_ADDR and
298 * `TOP_DRAGONFLY_AON_TIMER_AON_BASE_ADDR + TOP_DRAGONFLY_AON_TIMER_AON_SIZE_BYTES`.
299 */
300#define TOP_DRAGONFLY_AON_TIMER_AON_SIZE_BYTES 0x40u
301
302/**
303 * Peripheral base address for ast in top dragonfly.
304 *
305 * This should be used with #mmio_region_from_addr to access the memory-mapped
306 * registers associated with the peripheral (usually via a DIF).
307 */
308#define TOP_DRAGONFLY_AST_BASE_ADDR 0x30480000u
309
310/**
311 * Peripheral size for ast in top dragonfly.
312 *
313 * This is the size (in bytes) of the peripheral's reserved memory area. All
314 * memory-mapped registers associated with this peripheral should have an
315 * address between #TOP_DRAGONFLY_AST_BASE_ADDR and
316 * `TOP_DRAGONFLY_AST_BASE_ADDR + TOP_DRAGONFLY_AST_SIZE_BYTES`.
317 */
318#define TOP_DRAGONFLY_AST_SIZE_BYTES 0x400u
319
320/**
321 * Peripheral base address for core device on soc_proxy in top dragonfly.
322 *
323 * This should be used with #mmio_region_from_addr to access the memory-mapped
324 * registers associated with the peripheral (usually via a DIF).
325 */
326#define TOP_DRAGONFLY_SOC_PROXY_CORE_BASE_ADDR 0x22030000u
327
328/**
329 * Peripheral size for core device on soc_proxy in top dragonfly.
330 *
331 * This is the size (in bytes) of the peripheral's reserved memory area. All
332 * memory-mapped registers associated with this peripheral should have an
333 * address between #TOP_DRAGONFLY_SOC_PROXY_CORE_BASE_ADDR and
334 * `TOP_DRAGONFLY_SOC_PROXY_CORE_BASE_ADDR + TOP_DRAGONFLY_SOC_PROXY_CORE_SIZE_BYTES`.
335 */
336#define TOP_DRAGONFLY_SOC_PROXY_CORE_SIZE_BYTES 0x8u
337
338/**
339 * Peripheral base address for regs device on sram_ctrl_ret_aon in top dragonfly.
340 *
341 * This should be used with #mmio_region_from_addr to access the memory-mapped
342 * registers associated with the peripheral (usually via a DIF).
343 */
344#define TOP_DRAGONFLY_SRAM_CTRL_RET_AON_REGS_BASE_ADDR 0x30500000u
345
346/**
347 * Peripheral size for regs device on sram_ctrl_ret_aon in top dragonfly.
348 *
349 * This is the size (in bytes) of the peripheral's reserved memory area. All
350 * memory-mapped registers associated with this peripheral should have an
351 * address between #TOP_DRAGONFLY_SRAM_CTRL_RET_AON_REGS_BASE_ADDR and
352 * `TOP_DRAGONFLY_SRAM_CTRL_RET_AON_REGS_BASE_ADDR + TOP_DRAGONFLY_SRAM_CTRL_RET_AON_REGS_SIZE_BYTES`.
353 */
354#define TOP_DRAGONFLY_SRAM_CTRL_RET_AON_REGS_SIZE_BYTES 0x40u
355
356/**
357 * Peripheral base address for regs device on rv_dm in top dragonfly.
358 *
359 * This should be used with #mmio_region_from_addr to access the memory-mapped
360 * registers associated with the peripheral (usually via a DIF).
361 */
362#define TOP_DRAGONFLY_RV_DM_REGS_BASE_ADDR 0x21200000u
363
364/**
365 * Peripheral size for regs device on rv_dm in top dragonfly.
366 *
367 * This is the size (in bytes) of the peripheral's reserved memory area. All
368 * memory-mapped registers associated with this peripheral should have an
369 * address between #TOP_DRAGONFLY_RV_DM_REGS_BASE_ADDR and
370 * `TOP_DRAGONFLY_RV_DM_REGS_BASE_ADDR + TOP_DRAGONFLY_RV_DM_REGS_SIZE_BYTES`.
371 */
372#define TOP_DRAGONFLY_RV_DM_REGS_SIZE_BYTES 0x10u
373
374/**
375 * Peripheral base address for mem device on rv_dm in top dragonfly.
376 *
377 * This should be used with #mmio_region_from_addr to access the memory-mapped
378 * registers associated with the peripheral (usually via a DIF).
379 */
380#define TOP_DRAGONFLY_RV_DM_MEM_BASE_ADDR 0x40000u
381
382/**
383 * Peripheral size for mem device on rv_dm in top dragonfly.
384 *
385 * This is the size (in bytes) of the peripheral's reserved memory area. All
386 * memory-mapped registers associated with this peripheral should have an
387 * address between #TOP_DRAGONFLY_RV_DM_MEM_BASE_ADDR and
388 * `TOP_DRAGONFLY_RV_DM_MEM_BASE_ADDR + TOP_DRAGONFLY_RV_DM_MEM_SIZE_BYTES`.
389 */
390#define TOP_DRAGONFLY_RV_DM_MEM_SIZE_BYTES 0x1000u
391
392/**
393 * Peripheral base address for rv_plic in top dragonfly.
394 *
395 * This should be used with #mmio_region_from_addr to access the memory-mapped
396 * registers associated with the peripheral (usually via a DIF).
397 */
398#define TOP_DRAGONFLY_RV_PLIC_BASE_ADDR 0x28000000u
399
400/**
401 * Peripheral size for rv_plic in top dragonfly.
402 *
403 * This is the size (in bytes) of the peripheral's reserved memory area. All
404 * memory-mapped registers associated with this peripheral should have an
405 * address between #TOP_DRAGONFLY_RV_PLIC_BASE_ADDR and
406 * `TOP_DRAGONFLY_RV_PLIC_BASE_ADDR + TOP_DRAGONFLY_RV_PLIC_SIZE_BYTES`.
407 */
408#define TOP_DRAGONFLY_RV_PLIC_SIZE_BYTES 0x8000000u
409
410/**
411 * Peripheral base address for acc in top dragonfly.
412 *
413 * This should be used with #mmio_region_from_addr to access the memory-mapped
414 * registers associated with the peripheral (usually via a DIF).
415 */
416#define TOP_DRAGONFLY_ACC_BASE_ADDR 0x22100000u
417
418/**
419 * Peripheral size for acc in top dragonfly.
420 *
421 * This is the size (in bytes) of the peripheral's reserved memory area. All
422 * memory-mapped registers associated with this peripheral should have an
423 * address between #TOP_DRAGONFLY_ACC_BASE_ADDR and
424 * `TOP_DRAGONFLY_ACC_BASE_ADDR + TOP_DRAGONFLY_ACC_SIZE_BYTES`.
425 */
426#define TOP_DRAGONFLY_ACC_SIZE_BYTES 0x20000u
427
428/**
429 * Peripheral base address for aes in top dragonfly.
430 *
431 * This should be used with #mmio_region_from_addr to access the memory-mapped
432 * registers associated with the peripheral (usually via a DIF).
433 */
434#define TOP_DRAGONFLY_AES_BASE_ADDR 0x21100000u
435
436/**
437 * Peripheral size for aes in top dragonfly.
438 *
439 * This is the size (in bytes) of the peripheral's reserved memory area. All
440 * memory-mapped registers associated with this peripheral should have an
441 * address between #TOP_DRAGONFLY_AES_BASE_ADDR and
442 * `TOP_DRAGONFLY_AES_BASE_ADDR + TOP_DRAGONFLY_AES_SIZE_BYTES`.
443 */
444#define TOP_DRAGONFLY_AES_SIZE_BYTES 0x100u
445
446/**
447 * Peripheral base address for hmac in top dragonfly.
448 *
449 * This should be used with #mmio_region_from_addr to access the memory-mapped
450 * registers associated with the peripheral (usually via a DIF).
451 */
452#define TOP_DRAGONFLY_HMAC_BASE_ADDR 0x21110000u
453
454/**
455 * Peripheral size for hmac in top dragonfly.
456 *
457 * This is the size (in bytes) of the peripheral's reserved memory area. All
458 * memory-mapped registers associated with this peripheral should have an
459 * address between #TOP_DRAGONFLY_HMAC_BASE_ADDR and
460 * `TOP_DRAGONFLY_HMAC_BASE_ADDR + TOP_DRAGONFLY_HMAC_SIZE_BYTES`.
461 */
462#define TOP_DRAGONFLY_HMAC_SIZE_BYTES 0x2000u
463
464/**
465 * Peripheral base address for kmac in top dragonfly.
466 *
467 * This should be used with #mmio_region_from_addr to access the memory-mapped
468 * registers associated with the peripheral (usually via a DIF).
469 */
470#define TOP_DRAGONFLY_KMAC_BASE_ADDR 0x21120000u
471
472/**
473 * Peripheral size for kmac in top dragonfly.
474 *
475 * This is the size (in bytes) of the peripheral's reserved memory area. All
476 * memory-mapped registers associated with this peripheral should have an
477 * address between #TOP_DRAGONFLY_KMAC_BASE_ADDR and
478 * `TOP_DRAGONFLY_KMAC_BASE_ADDR + TOP_DRAGONFLY_KMAC_SIZE_BYTES`.
479 */
480#define TOP_DRAGONFLY_KMAC_SIZE_BYTES 0x1000u
481
482/**
483 * Peripheral base address for keymgr_dpe in top dragonfly.
484 *
485 * This should be used with #mmio_region_from_addr to access the memory-mapped
486 * registers associated with the peripheral (usually via a DIF).
487 */
488#define TOP_DRAGONFLY_KEYMGR_DPE_BASE_ADDR 0x21140000u
489
490/**
491 * Peripheral size for keymgr_dpe in top dragonfly.
492 *
493 * This is the size (in bytes) of the peripheral's reserved memory area. All
494 * memory-mapped registers associated with this peripheral should have an
495 * address between #TOP_DRAGONFLY_KEYMGR_DPE_BASE_ADDR and
496 * `TOP_DRAGONFLY_KEYMGR_DPE_BASE_ADDR + TOP_DRAGONFLY_KEYMGR_DPE_SIZE_BYTES`.
497 */
498#define TOP_DRAGONFLY_KEYMGR_DPE_SIZE_BYTES 0x100u
499
500/**
501 * Peripheral base address for csrng in top dragonfly.
502 *
503 * This should be used with #mmio_region_from_addr to access the memory-mapped
504 * registers associated with the peripheral (usually via a DIF).
505 */
506#define TOP_DRAGONFLY_CSRNG_BASE_ADDR 0x21150000u
507
508/**
509 * Peripheral size for csrng in top dragonfly.
510 *
511 * This is the size (in bytes) of the peripheral's reserved memory area. All
512 * memory-mapped registers associated with this peripheral should have an
513 * address between #TOP_DRAGONFLY_CSRNG_BASE_ADDR and
514 * `TOP_DRAGONFLY_CSRNG_BASE_ADDR + TOP_DRAGONFLY_CSRNG_SIZE_BYTES`.
515 */
516#define TOP_DRAGONFLY_CSRNG_SIZE_BYTES 0x80u
517
518/**
519 * Peripheral base address for entropy_src in top dragonfly.
520 *
521 * This should be used with #mmio_region_from_addr to access the memory-mapped
522 * registers associated with the peripheral (usually via a DIF).
523 */
524#define TOP_DRAGONFLY_ENTROPY_SRC_BASE_ADDR 0x21160000u
525
526/**
527 * Peripheral size for entropy_src in top dragonfly.
528 *
529 * This is the size (in bytes) of the peripheral's reserved memory area. All
530 * memory-mapped registers associated with this peripheral should have an
531 * address between #TOP_DRAGONFLY_ENTROPY_SRC_BASE_ADDR and
532 * `TOP_DRAGONFLY_ENTROPY_SRC_BASE_ADDR + TOP_DRAGONFLY_ENTROPY_SRC_SIZE_BYTES`.
533 */
534#define TOP_DRAGONFLY_ENTROPY_SRC_SIZE_BYTES 0x100u
535
536/**
537 * Peripheral base address for edn0 in top dragonfly.
538 *
539 * This should be used with #mmio_region_from_addr to access the memory-mapped
540 * registers associated with the peripheral (usually via a DIF).
541 */
542#define TOP_DRAGONFLY_EDN0_BASE_ADDR 0x21170000u
543
544/**
545 * Peripheral size for edn0 in top dragonfly.
546 *
547 * This is the size (in bytes) of the peripheral's reserved memory area. All
548 * memory-mapped registers associated with this peripheral should have an
549 * address between #TOP_DRAGONFLY_EDN0_BASE_ADDR and
550 * `TOP_DRAGONFLY_EDN0_BASE_ADDR + TOP_DRAGONFLY_EDN0_SIZE_BYTES`.
551 */
552#define TOP_DRAGONFLY_EDN0_SIZE_BYTES 0x80u
553
554/**
555 * Peripheral base address for edn1 in top dragonfly.
556 *
557 * This should be used with #mmio_region_from_addr to access the memory-mapped
558 * registers associated with the peripheral (usually via a DIF).
559 */
560#define TOP_DRAGONFLY_EDN1_BASE_ADDR 0x21180000u
561
562/**
563 * Peripheral size for edn1 in top dragonfly.
564 *
565 * This is the size (in bytes) of the peripheral's reserved memory area. All
566 * memory-mapped registers associated with this peripheral should have an
567 * address between #TOP_DRAGONFLY_EDN1_BASE_ADDR and
568 * `TOP_DRAGONFLY_EDN1_BASE_ADDR + TOP_DRAGONFLY_EDN1_SIZE_BYTES`.
569 */
570#define TOP_DRAGONFLY_EDN1_SIZE_BYTES 0x80u
571
572/**
573 * Peripheral base address for regs device on sram_ctrl_main in top dragonfly.
574 *
575 * This should be used with #mmio_region_from_addr to access the memory-mapped
576 * registers associated with the peripheral (usually via a DIF).
577 */
578#define TOP_DRAGONFLY_SRAM_CTRL_MAIN_REGS_BASE_ADDR 0x211C0000u
579
580/**
581 * Peripheral size for regs device on sram_ctrl_main in top dragonfly.
582 *
583 * This is the size (in bytes) of the peripheral's reserved memory area. All
584 * memory-mapped registers associated with this peripheral should have an
585 * address between #TOP_DRAGONFLY_SRAM_CTRL_MAIN_REGS_BASE_ADDR and
586 * `TOP_DRAGONFLY_SRAM_CTRL_MAIN_REGS_BASE_ADDR + TOP_DRAGONFLY_SRAM_CTRL_MAIN_REGS_SIZE_BYTES`.
587 */
588#define TOP_DRAGONFLY_SRAM_CTRL_MAIN_REGS_SIZE_BYTES 0x40u
589
590/**
591 * Peripheral base address for regs device on sram_ctrl_mbox in top dragonfly.
592 *
593 * This should be used with #mmio_region_from_addr to access the memory-mapped
594 * registers associated with the peripheral (usually via a DIF).
595 */
596#define TOP_DRAGONFLY_SRAM_CTRL_MBOX_REGS_BASE_ADDR 0x211D0000u
597
598/**
599 * Peripheral size for regs device on sram_ctrl_mbox in top dragonfly.
600 *
601 * This is the size (in bytes) of the peripheral's reserved memory area. All
602 * memory-mapped registers associated with this peripheral should have an
603 * address between #TOP_DRAGONFLY_SRAM_CTRL_MBOX_REGS_BASE_ADDR and
604 * `TOP_DRAGONFLY_SRAM_CTRL_MBOX_REGS_BASE_ADDR + TOP_DRAGONFLY_SRAM_CTRL_MBOX_REGS_SIZE_BYTES`.
605 */
606#define TOP_DRAGONFLY_SRAM_CTRL_MBOX_REGS_SIZE_BYTES 0x40u
607
608/**
609 * Peripheral base address for regs device on rom_ctrl0 in top dragonfly.
610 *
611 * This should be used with #mmio_region_from_addr to access the memory-mapped
612 * registers associated with the peripheral (usually via a DIF).
613 */
614#define TOP_DRAGONFLY_ROM_CTRL0_REGS_BASE_ADDR 0x211E0000u
615
616/**
617 * Peripheral size for regs device on rom_ctrl0 in top dragonfly.
618 *
619 * This is the size (in bytes) of the peripheral's reserved memory area. All
620 * memory-mapped registers associated with this peripheral should have an
621 * address between #TOP_DRAGONFLY_ROM_CTRL0_REGS_BASE_ADDR and
622 * `TOP_DRAGONFLY_ROM_CTRL0_REGS_BASE_ADDR + TOP_DRAGONFLY_ROM_CTRL0_REGS_SIZE_BYTES`.
623 */
624#define TOP_DRAGONFLY_ROM_CTRL0_REGS_SIZE_BYTES 0x80u
625
626/**
627 * Peripheral base address for regs device on rom_ctrl1 in top dragonfly.
628 *
629 * This should be used with #mmio_region_from_addr to access the memory-mapped
630 * registers associated with the peripheral (usually via a DIF).
631 */
632#define TOP_DRAGONFLY_ROM_CTRL1_REGS_BASE_ADDR 0x211E1000u
633
634/**
635 * Peripheral size for regs device on rom_ctrl1 in top dragonfly.
636 *
637 * This is the size (in bytes) of the peripheral's reserved memory area. All
638 * memory-mapped registers associated with this peripheral should have an
639 * address between #TOP_DRAGONFLY_ROM_CTRL1_REGS_BASE_ADDR and
640 * `TOP_DRAGONFLY_ROM_CTRL1_REGS_BASE_ADDR + TOP_DRAGONFLY_ROM_CTRL1_REGS_SIZE_BYTES`.
641 */
642#define TOP_DRAGONFLY_ROM_CTRL1_REGS_SIZE_BYTES 0x80u
643
644/**
645 * Peripheral base address for dma in top dragonfly.
646 *
647 * This should be used with #mmio_region_from_addr to access the memory-mapped
648 * registers associated with the peripheral (usually via a DIF).
649 */
650#define TOP_DRAGONFLY_DMA_BASE_ADDR 0x22010000u
651
652/**
653 * Peripheral size for dma in top dragonfly.
654 *
655 * This is the size (in bytes) of the peripheral's reserved memory area. All
656 * memory-mapped registers associated with this peripheral should have an
657 * address between #TOP_DRAGONFLY_DMA_BASE_ADDR and
658 * `TOP_DRAGONFLY_DMA_BASE_ADDR + TOP_DRAGONFLY_DMA_SIZE_BYTES`.
659 */
660#define TOP_DRAGONFLY_DMA_SIZE_BYTES 0x200u
661
662/**
663 * Peripheral base address for core device on mbx0 in top dragonfly.
664 *
665 * This should be used with #mmio_region_from_addr to access the memory-mapped
666 * registers associated with the peripheral (usually via a DIF).
667 */
668#define TOP_DRAGONFLY_MBX0_CORE_BASE_ADDR 0x22000000u
669
670/**
671 * Peripheral size for core device on mbx0 in top dragonfly.
672 *
673 * This is the size (in bytes) of the peripheral's reserved memory area. All
674 * memory-mapped registers associated with this peripheral should have an
675 * address between #TOP_DRAGONFLY_MBX0_CORE_BASE_ADDR and
676 * `TOP_DRAGONFLY_MBX0_CORE_BASE_ADDR + TOP_DRAGONFLY_MBX0_CORE_SIZE_BYTES`.
677 */
678#define TOP_DRAGONFLY_MBX0_CORE_SIZE_BYTES 0x80u
679
680/**
681 * Peripheral base address for core device on mbx1 in top dragonfly.
682 *
683 * This should be used with #mmio_region_from_addr to access the memory-mapped
684 * registers associated with the peripheral (usually via a DIF).
685 */
686#define TOP_DRAGONFLY_MBX1_CORE_BASE_ADDR 0x22000100u
687
688/**
689 * Peripheral size for core device on mbx1 in top dragonfly.
690 *
691 * This is the size (in bytes) of the peripheral's reserved memory area. All
692 * memory-mapped registers associated with this peripheral should have an
693 * address between #TOP_DRAGONFLY_MBX1_CORE_BASE_ADDR and
694 * `TOP_DRAGONFLY_MBX1_CORE_BASE_ADDR + TOP_DRAGONFLY_MBX1_CORE_SIZE_BYTES`.
695 */
696#define TOP_DRAGONFLY_MBX1_CORE_SIZE_BYTES 0x80u
697
698/**
699 * Peripheral base address for core device on mbx2 in top dragonfly.
700 *
701 * This should be used with #mmio_region_from_addr to access the memory-mapped
702 * registers associated with the peripheral (usually via a DIF).
703 */
704#define TOP_DRAGONFLY_MBX2_CORE_BASE_ADDR 0x22000200u
705
706/**
707 * Peripheral size for core device on mbx2 in top dragonfly.
708 *
709 * This is the size (in bytes) of the peripheral's reserved memory area. All
710 * memory-mapped registers associated with this peripheral should have an
711 * address between #TOP_DRAGONFLY_MBX2_CORE_BASE_ADDR and
712 * `TOP_DRAGONFLY_MBX2_CORE_BASE_ADDR + TOP_DRAGONFLY_MBX2_CORE_SIZE_BYTES`.
713 */
714#define TOP_DRAGONFLY_MBX2_CORE_SIZE_BYTES 0x80u
715
716/**
717 * Peripheral base address for core device on mbx3 in top dragonfly.
718 *
719 * This should be used with #mmio_region_from_addr to access the memory-mapped
720 * registers associated with the peripheral (usually via a DIF).
721 */
722#define TOP_DRAGONFLY_MBX3_CORE_BASE_ADDR 0x22000300u
723
724/**
725 * Peripheral size for core device on mbx3 in top dragonfly.
726 *
727 * This is the size (in bytes) of the peripheral's reserved memory area. All
728 * memory-mapped registers associated with this peripheral should have an
729 * address between #TOP_DRAGONFLY_MBX3_CORE_BASE_ADDR and
730 * `TOP_DRAGONFLY_MBX3_CORE_BASE_ADDR + TOP_DRAGONFLY_MBX3_CORE_SIZE_BYTES`.
731 */
732#define TOP_DRAGONFLY_MBX3_CORE_SIZE_BYTES 0x80u
733
734/**
735 * Peripheral base address for core device on mbx4 in top dragonfly.
736 *
737 * This should be used with #mmio_region_from_addr to access the memory-mapped
738 * registers associated with the peripheral (usually via a DIF).
739 */
740#define TOP_DRAGONFLY_MBX4_CORE_BASE_ADDR 0x22000400u
741
742/**
743 * Peripheral size for core device on mbx4 in top dragonfly.
744 *
745 * This is the size (in bytes) of the peripheral's reserved memory area. All
746 * memory-mapped registers associated with this peripheral should have an
747 * address between #TOP_DRAGONFLY_MBX4_CORE_BASE_ADDR and
748 * `TOP_DRAGONFLY_MBX4_CORE_BASE_ADDR + TOP_DRAGONFLY_MBX4_CORE_SIZE_BYTES`.
749 */
750#define TOP_DRAGONFLY_MBX4_CORE_SIZE_BYTES 0x80u
751
752/**
753 * Peripheral base address for core device on mbx5 in top dragonfly.
754 *
755 * This should be used with #mmio_region_from_addr to access the memory-mapped
756 * registers associated with the peripheral (usually via a DIF).
757 */
758#define TOP_DRAGONFLY_MBX5_CORE_BASE_ADDR 0x22000500u
759
760/**
761 * Peripheral size for core device on mbx5 in top dragonfly.
762 *
763 * This is the size (in bytes) of the peripheral's reserved memory area. All
764 * memory-mapped registers associated with this peripheral should have an
765 * address between #TOP_DRAGONFLY_MBX5_CORE_BASE_ADDR and
766 * `TOP_DRAGONFLY_MBX5_CORE_BASE_ADDR + TOP_DRAGONFLY_MBX5_CORE_SIZE_BYTES`.
767 */
768#define TOP_DRAGONFLY_MBX5_CORE_SIZE_BYTES 0x80u
769
770/**
771 * Peripheral base address for core device on mbx6 in top dragonfly.
772 *
773 * This should be used with #mmio_region_from_addr to access the memory-mapped
774 * registers associated with the peripheral (usually via a DIF).
775 */
776#define TOP_DRAGONFLY_MBX6_CORE_BASE_ADDR 0x22000600u
777
778/**
779 * Peripheral size for core device on mbx6 in top dragonfly.
780 *
781 * This is the size (in bytes) of the peripheral's reserved memory area. All
782 * memory-mapped registers associated with this peripheral should have an
783 * address between #TOP_DRAGONFLY_MBX6_CORE_BASE_ADDR and
784 * `TOP_DRAGONFLY_MBX6_CORE_BASE_ADDR + TOP_DRAGONFLY_MBX6_CORE_SIZE_BYTES`.
785 */
786#define TOP_DRAGONFLY_MBX6_CORE_SIZE_BYTES 0x80u
787
788/**
789 * Peripheral base address for core device on mbx_jtag in top dragonfly.
790 *
791 * This should be used with #mmio_region_from_addr to access the memory-mapped
792 * registers associated with the peripheral (usually via a DIF).
793 */
794#define TOP_DRAGONFLY_MBX_JTAG_CORE_BASE_ADDR 0x22000800u
795
796/**
797 * Peripheral size for core device on mbx_jtag in top dragonfly.
798 *
799 * This is the size (in bytes) of the peripheral's reserved memory area. All
800 * memory-mapped registers associated with this peripheral should have an
801 * address between #TOP_DRAGONFLY_MBX_JTAG_CORE_BASE_ADDR and
802 * `TOP_DRAGONFLY_MBX_JTAG_CORE_BASE_ADDR + TOP_DRAGONFLY_MBX_JTAG_CORE_SIZE_BYTES`.
803 */
804#define TOP_DRAGONFLY_MBX_JTAG_CORE_SIZE_BYTES 0x80u
805
806/**
807 * Peripheral base address for core device on mbx_pcie0 in top dragonfly.
808 *
809 * This should be used with #mmio_region_from_addr to access the memory-mapped
810 * registers associated with the peripheral (usually via a DIF).
811 */
812#define TOP_DRAGONFLY_MBX_PCIE0_CORE_BASE_ADDR 0x22040000u
813
814/**
815 * Peripheral size for core device on mbx_pcie0 in top dragonfly.
816 *
817 * This is the size (in bytes) of the peripheral's reserved memory area. All
818 * memory-mapped registers associated with this peripheral should have an
819 * address between #TOP_DRAGONFLY_MBX_PCIE0_CORE_BASE_ADDR and
820 * `TOP_DRAGONFLY_MBX_PCIE0_CORE_BASE_ADDR + TOP_DRAGONFLY_MBX_PCIE0_CORE_SIZE_BYTES`.
821 */
822#define TOP_DRAGONFLY_MBX_PCIE0_CORE_SIZE_BYTES 0x80u
823
824/**
825 * Peripheral base address for core device on mbx_pcie1 in top dragonfly.
826 *
827 * This should be used with #mmio_region_from_addr to access the memory-mapped
828 * registers associated with the peripheral (usually via a DIF).
829 */
830#define TOP_DRAGONFLY_MBX_PCIE1_CORE_BASE_ADDR 0x22040100u
831
832/**
833 * Peripheral size for core device on mbx_pcie1 in top dragonfly.
834 *
835 * This is the size (in bytes) of the peripheral's reserved memory area. All
836 * memory-mapped registers associated with this peripheral should have an
837 * address between #TOP_DRAGONFLY_MBX_PCIE1_CORE_BASE_ADDR and
838 * `TOP_DRAGONFLY_MBX_PCIE1_CORE_BASE_ADDR + TOP_DRAGONFLY_MBX_PCIE1_CORE_SIZE_BYTES`.
839 */
840#define TOP_DRAGONFLY_MBX_PCIE1_CORE_SIZE_BYTES 0x80u
841
842/**
843 * Peripheral base address for core device on soc_dbg_ctrl in top dragonfly.
844 *
845 * This should be used with #mmio_region_from_addr to access the memory-mapped
846 * registers associated with the peripheral (usually via a DIF).
847 */
848#define TOP_DRAGONFLY_SOC_DBG_CTRL_CORE_BASE_ADDR 0x30170000u
849
850/**
851 * Peripheral size for core device on soc_dbg_ctrl in top dragonfly.
852 *
853 * This is the size (in bytes) of the peripheral's reserved memory area. All
854 * memory-mapped registers associated with this peripheral should have an
855 * address between #TOP_DRAGONFLY_SOC_DBG_CTRL_CORE_BASE_ADDR and
856 * `TOP_DRAGONFLY_SOC_DBG_CTRL_CORE_BASE_ADDR + TOP_DRAGONFLY_SOC_DBG_CTRL_CORE_SIZE_BYTES`.
857 */
858#define TOP_DRAGONFLY_SOC_DBG_CTRL_CORE_SIZE_BYTES 0x20u
859
860/**
861 * Peripheral base address for cfg device on rv_core_ibex in top dragonfly.
862 *
863 * This should be used with #mmio_region_from_addr to access the memory-mapped
864 * registers associated with the peripheral (usually via a DIF).
865 */
866#define TOP_DRAGONFLY_RV_CORE_IBEX_CFG_BASE_ADDR 0x211F0000u
867
868/**
869 * Peripheral size for cfg device on rv_core_ibex in top dragonfly.
870 *
871 * This is the size (in bytes) of the peripheral's reserved memory area. All
872 * memory-mapped registers associated with this peripheral should have an
873 * address between #TOP_DRAGONFLY_RV_CORE_IBEX_CFG_BASE_ADDR and
874 * `TOP_DRAGONFLY_RV_CORE_IBEX_CFG_BASE_ADDR + TOP_DRAGONFLY_RV_CORE_IBEX_CFG_SIZE_BYTES`.
875 */
876#define TOP_DRAGONFLY_RV_CORE_IBEX_CFG_SIZE_BYTES 0x800u
877
878
879/**
880 * Memory base address for ctn memory on soc_proxy in top dragonfly.
881 */
882#define TOP_DRAGONFLY_SOC_PROXY_CTN_BASE_ADDR 0x40000000u
883
884/**
885 * Memory size for ctn memory on soc_proxy in top dragonfly.
886 */
887#define TOP_DRAGONFLY_SOC_PROXY_CTN_SIZE_BYTES 0x80000000u
888
889/**
890 * Memory base address for ram_ctn in top dragonfly.
891 */
892#define TOP_DRAGONFLY_SOC_PROXY_RAM_CTN_BASE_ADDR 0x41000000u
893
894/**
895 * Memory size for ram_ctn in top dragonfly.
896 */
897#define TOP_DRAGONFLY_SOC_PROXY_RAM_CTN_SIZE_BYTES 0x100000u
898
899/**
900 * Memory base address for ram memory on sram_ctrl_ret_aon in top dragonfly.
901 */
902#define TOP_DRAGONFLY_SRAM_CTRL_RET_AON_RAM_BASE_ADDR 0x30600000u
903
904/**
905 * Memory size for ram memory on sram_ctrl_ret_aon in top dragonfly.
906 */
907#define TOP_DRAGONFLY_SRAM_CTRL_RET_AON_RAM_SIZE_BYTES 0x1000u
908
909/**
910 * Memory base address for ram memory on sram_ctrl_main in top dragonfly.
911 */
912#define TOP_DRAGONFLY_SRAM_CTRL_MAIN_RAM_BASE_ADDR 0x10000000u
913
914/**
915 * Memory size for ram memory on sram_ctrl_main in top dragonfly.
916 */
917#define TOP_DRAGONFLY_SRAM_CTRL_MAIN_RAM_SIZE_BYTES 0x10000u
918
919/**
920 * Memory base address for ram memory on sram_ctrl_mbox in top dragonfly.
921 */
922#define TOP_DRAGONFLY_SRAM_CTRL_MBOX_RAM_BASE_ADDR 0x11000000u
923
924/**
925 * Memory size for ram memory on sram_ctrl_mbox in top dragonfly.
926 */
927#define TOP_DRAGONFLY_SRAM_CTRL_MBOX_RAM_SIZE_BYTES 0x1000u
928
929/**
930 * Memory base address for rom memory on rom_ctrl0 in top dragonfly.
931 */
932#define TOP_DRAGONFLY_ROM_CTRL0_ROM_BASE_ADDR 0x8000u
933
934/**
935 * Memory size for rom memory on rom_ctrl0 in top dragonfly.
936 */
937#define TOP_DRAGONFLY_ROM_CTRL0_ROM_SIZE_BYTES 0x8000u
938
939/**
940 * Memory base address for rom memory on rom_ctrl1 in top dragonfly.
941 */
942#define TOP_DRAGONFLY_ROM_CTRL1_ROM_BASE_ADDR 0x20000u
943
944/**
945 * Memory size for rom memory on rom_ctrl1 in top dragonfly.
946 */
947#define TOP_DRAGONFLY_ROM_CTRL1_ROM_SIZE_BYTES 0x10000u
948
949
950/**
951 * PLIC Interrupt Source Peripheral.
952 *
953 * Enumeration used to determine which peripheral asserted the corresponding
954 * interrupt.
955 */
957 kTopDragonflyPlicPeripheralUnknown = 0, /**< Unknown Peripheral */
967 kTopDragonflyPlicPeripheralAonTimerAon = 10, /**< aon_timer_aon */
988 kTopDragonflyPlicPeripheralAcRangeCheck = 31, /**< ac_range_check */
989 kTopDragonflyPlicPeripheralLast = 31, /**< \internal Final PLIC peripheral */
991
992/**
993 * PLIC Interrupt Source.
994 *
995 * Enumeration of all PLIC interrupt sources. The interrupt sources belonging to
996 * the same peripheral are guaranteed to be consecutive.
997 */
999 kTopDragonflyPlicIrqIdNone = 0, /**< No Interrupt */
1000 kTopDragonflyPlicIrqIdUart0TxWatermark = 1, /**< uart0_tx_watermark */
1001 kTopDragonflyPlicIrqIdUart0RxWatermark = 2, /**< uart0_rx_watermark */
1002 kTopDragonflyPlicIrqIdUart0TxDone = 3, /**< uart0_tx_done */
1003 kTopDragonflyPlicIrqIdUart0RxOverflow = 4, /**< uart0_rx_overflow */
1004 kTopDragonflyPlicIrqIdUart0RxFrameErr = 5, /**< uart0_rx_frame_err */
1005 kTopDragonflyPlicIrqIdUart0RxBreakErr = 6, /**< uart0_rx_break_err */
1006 kTopDragonflyPlicIrqIdUart0RxTimeout = 7, /**< uart0_rx_timeout */
1007 kTopDragonflyPlicIrqIdUart0RxParityErr = 8, /**< uart0_rx_parity_err */
1008 kTopDragonflyPlicIrqIdUart0TxEmpty = 9, /**< uart0_tx_empty */
1009 kTopDragonflyPlicIrqIdGpioGpio0 = 10, /**< gpio_gpio 0 */
1010 kTopDragonflyPlicIrqIdGpioGpio1 = 11, /**< gpio_gpio 1 */
1011 kTopDragonflyPlicIrqIdGpioGpio2 = 12, /**< gpio_gpio 2 */
1012 kTopDragonflyPlicIrqIdGpioGpio3 = 13, /**< gpio_gpio 3 */
1013 kTopDragonflyPlicIrqIdGpioGpio4 = 14, /**< gpio_gpio 4 */
1014 kTopDragonflyPlicIrqIdGpioGpio5 = 15, /**< gpio_gpio 5 */
1015 kTopDragonflyPlicIrqIdGpioGpio6 = 16, /**< gpio_gpio 6 */
1016 kTopDragonflyPlicIrqIdGpioGpio7 = 17, /**< gpio_gpio 7 */
1017 kTopDragonflyPlicIrqIdGpioGpio8 = 18, /**< gpio_gpio 8 */
1018 kTopDragonflyPlicIrqIdGpioGpio9 = 19, /**< gpio_gpio 9 */
1019 kTopDragonflyPlicIrqIdGpioGpio10 = 20, /**< gpio_gpio 10 */
1020 kTopDragonflyPlicIrqIdGpioGpio11 = 21, /**< gpio_gpio 11 */
1021 kTopDragonflyPlicIrqIdGpioGpio12 = 22, /**< gpio_gpio 12 */
1022 kTopDragonflyPlicIrqIdGpioGpio13 = 23, /**< gpio_gpio 13 */
1023 kTopDragonflyPlicIrqIdGpioGpio14 = 24, /**< gpio_gpio 14 */
1024 kTopDragonflyPlicIrqIdGpioGpio15 = 25, /**< gpio_gpio 15 */
1025 kTopDragonflyPlicIrqIdGpioGpio16 = 26, /**< gpio_gpio 16 */
1026 kTopDragonflyPlicIrqIdGpioGpio17 = 27, /**< gpio_gpio 17 */
1027 kTopDragonflyPlicIrqIdGpioGpio18 = 28, /**< gpio_gpio 18 */
1028 kTopDragonflyPlicIrqIdGpioGpio19 = 29, /**< gpio_gpio 19 */
1029 kTopDragonflyPlicIrqIdGpioGpio20 = 30, /**< gpio_gpio 20 */
1030 kTopDragonflyPlicIrqIdGpioGpio21 = 31, /**< gpio_gpio 21 */
1031 kTopDragonflyPlicIrqIdGpioGpio22 = 32, /**< gpio_gpio 22 */
1032 kTopDragonflyPlicIrqIdGpioGpio23 = 33, /**< gpio_gpio 23 */
1033 kTopDragonflyPlicIrqIdGpioGpio24 = 34, /**< gpio_gpio 24 */
1034 kTopDragonflyPlicIrqIdGpioGpio25 = 35, /**< gpio_gpio 25 */
1035 kTopDragonflyPlicIrqIdGpioGpio26 = 36, /**< gpio_gpio 26 */
1036 kTopDragonflyPlicIrqIdGpioGpio27 = 37, /**< gpio_gpio 27 */
1037 kTopDragonflyPlicIrqIdGpioGpio28 = 38, /**< gpio_gpio 28 */
1038 kTopDragonflyPlicIrqIdGpioGpio29 = 39, /**< gpio_gpio 29 */
1039 kTopDragonflyPlicIrqIdGpioGpio30 = 40, /**< gpio_gpio 30 */
1040 kTopDragonflyPlicIrqIdGpioGpio31 = 41, /**< gpio_gpio 31 */
1041 kTopDragonflyPlicIrqIdSpiDeviceUploadCmdfifoNotEmpty = 42, /**< spi_device_upload_cmdfifo_not_empty */
1042 kTopDragonflyPlicIrqIdSpiDeviceUploadPayloadNotEmpty = 43, /**< spi_device_upload_payload_not_empty */
1043 kTopDragonflyPlicIrqIdSpiDeviceUploadPayloadOverflow = 44, /**< spi_device_upload_payload_overflow */
1044 kTopDragonflyPlicIrqIdSpiDeviceReadbufWatermark = 45, /**< spi_device_readbuf_watermark */
1045 kTopDragonflyPlicIrqIdSpiDeviceReadbufFlip = 46, /**< spi_device_readbuf_flip */
1046 kTopDragonflyPlicIrqIdSpiDeviceTpmHeaderNotEmpty = 47, /**< spi_device_tpm_header_not_empty */
1047 kTopDragonflyPlicIrqIdSpiDeviceTpmRdfifoCmdEnd = 48, /**< spi_device_tpm_rdfifo_cmd_end */
1048 kTopDragonflyPlicIrqIdSpiDeviceTpmRdfifoDrop = 49, /**< spi_device_tpm_rdfifo_drop */
1049 kTopDragonflyPlicIrqIdI2c0FmtThreshold = 50, /**< i2c0_fmt_threshold */
1050 kTopDragonflyPlicIrqIdI2c0RxThreshold = 51, /**< i2c0_rx_threshold */
1051 kTopDragonflyPlicIrqIdI2c0AcqThreshold = 52, /**< i2c0_acq_threshold */
1052 kTopDragonflyPlicIrqIdI2c0RxOverflow = 53, /**< i2c0_rx_overflow */
1053 kTopDragonflyPlicIrqIdI2c0ControllerHalt = 54, /**< i2c0_controller_halt */
1054 kTopDragonflyPlicIrqIdI2c0SclInterference = 55, /**< i2c0_scl_interference */
1055 kTopDragonflyPlicIrqIdI2c0SdaInterference = 56, /**< i2c0_sda_interference */
1056 kTopDragonflyPlicIrqIdI2c0StretchTimeout = 57, /**< i2c0_stretch_timeout */
1057 kTopDragonflyPlicIrqIdI2c0SdaUnstable = 58, /**< i2c0_sda_unstable */
1058 kTopDragonflyPlicIrqIdI2c0CmdComplete = 59, /**< i2c0_cmd_complete */
1059 kTopDragonflyPlicIrqIdI2c0TxStretch = 60, /**< i2c0_tx_stretch */
1060 kTopDragonflyPlicIrqIdI2c0TxThreshold = 61, /**< i2c0_tx_threshold */
1061 kTopDragonflyPlicIrqIdI2c0AcqStretch = 62, /**< i2c0_acq_stretch */
1062 kTopDragonflyPlicIrqIdI2c0UnexpStop = 63, /**< i2c0_unexp_stop */
1063 kTopDragonflyPlicIrqIdI2c0HostTimeout = 64, /**< i2c0_host_timeout */
1064 kTopDragonflyPlicIrqIdRvTimerTimerExpiredHart0Timer0 = 65, /**< rv_timer_timer_expired_hart0_timer0 */
1065 kTopDragonflyPlicIrqIdOtpCtrlOtpOperationDone = 66, /**< otp_ctrl_otp_operation_done */
1066 kTopDragonflyPlicIrqIdOtpCtrlOtpError = 67, /**< otp_ctrl_otp_error */
1067 kTopDragonflyPlicIrqIdAlertHandlerClassa = 68, /**< alert_handler_classa */
1068 kTopDragonflyPlicIrqIdAlertHandlerClassb = 69, /**< alert_handler_classb */
1069 kTopDragonflyPlicIrqIdAlertHandlerClassc = 70, /**< alert_handler_classc */
1070 kTopDragonflyPlicIrqIdAlertHandlerClassd = 71, /**< alert_handler_classd */
1071 kTopDragonflyPlicIrqIdSpiHost0Error = 72, /**< spi_host0_error */
1072 kTopDragonflyPlicIrqIdSpiHost0SpiEvent = 73, /**< spi_host0_spi_event */
1073 kTopDragonflyPlicIrqIdPwrmgrAonWakeup = 74, /**< pwrmgr_aon_wakeup */
1074 kTopDragonflyPlicIrqIdAonTimerAonWkupTimerExpired = 75, /**< aon_timer_aon_wkup_timer_expired */
1075 kTopDragonflyPlicIrqIdAonTimerAonWdogTimerBark = 76, /**< aon_timer_aon_wdog_timer_bark */
1076 kTopDragonflyPlicIrqIdAccDone = 77, /**< acc_done */
1077 kTopDragonflyPlicIrqIdHmacHmacDone = 78, /**< hmac_hmac_done */
1078 kTopDragonflyPlicIrqIdHmacFifoEmpty = 79, /**< hmac_fifo_empty */
1079 kTopDragonflyPlicIrqIdHmacHmacErr = 80, /**< hmac_hmac_err */
1080 kTopDragonflyPlicIrqIdKmacKmacDone = 81, /**< kmac_kmac_done */
1081 kTopDragonflyPlicIrqIdKmacFifoEmpty = 82, /**< kmac_fifo_empty */
1082 kTopDragonflyPlicIrqIdKmacKmacErr = 83, /**< kmac_kmac_err */
1083 kTopDragonflyPlicIrqIdKeymgrDpeOpDone = 84, /**< keymgr_dpe_op_done */
1084 kTopDragonflyPlicIrqIdCsrngCsCmdReqDone = 85, /**< csrng_cs_cmd_req_done */
1085 kTopDragonflyPlicIrqIdCsrngCsEntropyReq = 86, /**< csrng_cs_entropy_req */
1086 kTopDragonflyPlicIrqIdCsrngCsHwInstExc = 87, /**< csrng_cs_hw_inst_exc */
1087 kTopDragonflyPlicIrqIdCsrngCsFatalErr = 88, /**< csrng_cs_fatal_err */
1088 kTopDragonflyPlicIrqIdEntropySrcEsEntropyValid = 89, /**< entropy_src_es_entropy_valid */
1089 kTopDragonflyPlicIrqIdEntropySrcEsHealthTestFailed = 90, /**< entropy_src_es_health_test_failed */
1090 kTopDragonflyPlicIrqIdEntropySrcEsObserveFifoReady = 91, /**< entropy_src_es_observe_fifo_ready */
1091 kTopDragonflyPlicIrqIdEntropySrcEsFatalErr = 92, /**< entropy_src_es_fatal_err */
1092 kTopDragonflyPlicIrqIdEdn0EdnCmdReqDone = 93, /**< edn0_edn_cmd_req_done */
1093 kTopDragonflyPlicIrqIdEdn0EdnFatalErr = 94, /**< edn0_edn_fatal_err */
1094 kTopDragonflyPlicIrqIdEdn1EdnCmdReqDone = 95, /**< edn1_edn_cmd_req_done */
1095 kTopDragonflyPlicIrqIdEdn1EdnFatalErr = 96, /**< edn1_edn_fatal_err */
1096 kTopDragonflyPlicIrqIdDmaDmaDone = 97, /**< dma_dma_done */
1097 kTopDragonflyPlicIrqIdDmaDmaChunkDone = 98, /**< dma_dma_chunk_done */
1098 kTopDragonflyPlicIrqIdDmaDmaError = 99, /**< dma_dma_error */
1099 kTopDragonflyPlicIrqIdMbx0MbxReady = 100, /**< mbx0_mbx_ready */
1100 kTopDragonflyPlicIrqIdMbx0MbxAbort = 101, /**< mbx0_mbx_abort */
1101 kTopDragonflyPlicIrqIdMbx0MbxError = 102, /**< mbx0_mbx_error */
1102 kTopDragonflyPlicIrqIdMbx1MbxReady = 103, /**< mbx1_mbx_ready */
1103 kTopDragonflyPlicIrqIdMbx1MbxAbort = 104, /**< mbx1_mbx_abort */
1104 kTopDragonflyPlicIrqIdMbx1MbxError = 105, /**< mbx1_mbx_error */
1105 kTopDragonflyPlicIrqIdMbx2MbxReady = 106, /**< mbx2_mbx_ready */
1106 kTopDragonflyPlicIrqIdMbx2MbxAbort = 107, /**< mbx2_mbx_abort */
1107 kTopDragonflyPlicIrqIdMbx2MbxError = 108, /**< mbx2_mbx_error */
1108 kTopDragonflyPlicIrqIdMbx3MbxReady = 109, /**< mbx3_mbx_ready */
1109 kTopDragonflyPlicIrqIdMbx3MbxAbort = 110, /**< mbx3_mbx_abort */
1110 kTopDragonflyPlicIrqIdMbx3MbxError = 111, /**< mbx3_mbx_error */
1111 kTopDragonflyPlicIrqIdMbx4MbxReady = 112, /**< mbx4_mbx_ready */
1112 kTopDragonflyPlicIrqIdMbx4MbxAbort = 113, /**< mbx4_mbx_abort */
1113 kTopDragonflyPlicIrqIdMbx4MbxError = 114, /**< mbx4_mbx_error */
1114 kTopDragonflyPlicIrqIdMbx5MbxReady = 115, /**< mbx5_mbx_ready */
1115 kTopDragonflyPlicIrqIdMbx5MbxAbort = 116, /**< mbx5_mbx_abort */
1116 kTopDragonflyPlicIrqIdMbx5MbxError = 117, /**< mbx5_mbx_error */
1117 kTopDragonflyPlicIrqIdMbx6MbxReady = 118, /**< mbx6_mbx_ready */
1118 kTopDragonflyPlicIrqIdMbx6MbxAbort = 119, /**< mbx6_mbx_abort */
1119 kTopDragonflyPlicIrqIdMbx6MbxError = 120, /**< mbx6_mbx_error */
1120 kTopDragonflyPlicIrqIdMbxJtagMbxReady = 121, /**< mbx_jtag_mbx_ready */
1121 kTopDragonflyPlicIrqIdMbxJtagMbxAbort = 122, /**< mbx_jtag_mbx_abort */
1122 kTopDragonflyPlicIrqIdMbxJtagMbxError = 123, /**< mbx_jtag_mbx_error */
1123 kTopDragonflyPlicIrqIdMbxPcie0MbxReady = 124, /**< mbx_pcie0_mbx_ready */
1124 kTopDragonflyPlicIrqIdMbxPcie0MbxAbort = 125, /**< mbx_pcie0_mbx_abort */
1125 kTopDragonflyPlicIrqIdMbxPcie0MbxError = 126, /**< mbx_pcie0_mbx_error */
1126 kTopDragonflyPlicIrqIdMbxPcie1MbxReady = 127, /**< mbx_pcie1_mbx_ready */
1127 kTopDragonflyPlicIrqIdMbxPcie1MbxAbort = 128, /**< mbx_pcie1_mbx_abort */
1128 kTopDragonflyPlicIrqIdMbxPcie1MbxError = 129, /**< mbx_pcie1_mbx_error */
1129 kTopDragonflyPlicIrqIdRaclCtrlRaclError = 130, /**< racl_ctrl_racl_error */
1130 kTopDragonflyPlicIrqIdAcRangeCheckDenyCntReached = 131, /**< ac_range_check_deny_cnt_reached */
1131 kTopDragonflyPlicIrqIdLast = 131, /**< \internal The Last Valid Interrupt ID. */
1133
1134/**
1135 * PLIC Interrupt Source to Peripheral Map
1136 *
1137 * This array is a mapping from `top_dragonfly_plic_irq_id_t` to
1138 * `top_dragonfly_plic_peripheral_t`.
1139 */
1141 top_dragonfly_plic_interrupt_for_peripheral[132];
1142
1143/**
1144 * PLIC Interrupt Target.
1145 *
1146 * Enumeration used to determine which set of IE, CC, threshold registers to
1147 * access for a given interrupt target.
1148 */
1150 kTopDragonflyPlicTargetIbex0 = 0, /**< Ibex Core 0 */
1151 kTopDragonflyPlicTargetLast = 0, /**< \internal Final PLIC target */
1153
1154
1155/**
1156 * Alert Handler Source Peripheral.
1157 *
1158 * Enumeration used to determine which peripheral asserted the corresponding
1159 * alert.
1160 */
1162 kTopDragonflyAlertPeripheralExternal = 0, /**< External Peripheral */
1177 kTopDragonflyAlertPeripheralSramCtrlRetAon = 15, /**< sram_ctrl_ret_aon */
1189 kTopDragonflyAlertPeripheralSramCtrlMain = 27, /**< sram_ctrl_main */
1190 kTopDragonflyAlertPeripheralSramCtrlMbox = 28, /**< sram_ctrl_mbox */
1206 kTopDragonflyAlertPeripheralAcRangeCheck = 44, /**< ac_range_check */
1208 kTopDragonflyAlertPeripheralLast = 45, /**< \internal Final Alert peripheral */
1210
1211/**
1212 * Alert Handler Alert Source.
1213 *
1214 * Enumeration of all Alert Handler Alert Sources. The alert sources belonging to
1215 * the same peripheral are guaranteed to be consecutive.
1216 */
1218 kTopDragonflyAlertIdUart0FatalFault = 0, /**< uart0_fatal_fault */
1219 kTopDragonflyAlertIdGpioFatalFault = 1, /**< gpio_fatal_fault */
1220 kTopDragonflyAlertIdSpiDeviceFatalFault = 2, /**< spi_device_fatal_fault */
1221 kTopDragonflyAlertIdI2c0FatalFault = 3, /**< i2c0_fatal_fault */
1222 kTopDragonflyAlertIdRvTimerFatalFault = 4, /**< rv_timer_fatal_fault */
1223 kTopDragonflyAlertIdOtpCtrlFatalMacroError = 5, /**< otp_ctrl_fatal_macro_error */
1224 kTopDragonflyAlertIdOtpCtrlFatalCheckError = 6, /**< otp_ctrl_fatal_check_error */
1225 kTopDragonflyAlertIdOtpCtrlFatalBusIntegError = 7, /**< otp_ctrl_fatal_bus_integ_error */
1226 kTopDragonflyAlertIdOtpCtrlFatalPrimOtpAlert = 8, /**< otp_ctrl_fatal_prim_otp_alert */
1227 kTopDragonflyAlertIdOtpCtrlRecovPrimOtpAlert = 9, /**< otp_ctrl_recov_prim_otp_alert */
1228 kTopDragonflyAlertIdLcCtrlFatalProgError = 10, /**< lc_ctrl_fatal_prog_error */
1229 kTopDragonflyAlertIdLcCtrlFatalStateError = 11, /**< lc_ctrl_fatal_state_error */
1230 kTopDragonflyAlertIdLcCtrlFatalBusIntegError = 12, /**< lc_ctrl_fatal_bus_integ_error */
1231 kTopDragonflyAlertIdSpiHost0FatalFault = 13, /**< spi_host0_fatal_fault */
1232 kTopDragonflyAlertIdPwrmgrAonFatalFault = 14, /**< pwrmgr_aon_fatal_fault */
1233 kTopDragonflyAlertIdRstmgrAonFatalFault = 15, /**< rstmgr_aon_fatal_fault */
1234 kTopDragonflyAlertIdRstmgrAonFatalCnstyFault = 16, /**< rstmgr_aon_fatal_cnsty_fault */
1235 kTopDragonflyAlertIdClkmgrAonRecovFault = 17, /**< clkmgr_aon_recov_fault */
1236 kTopDragonflyAlertIdClkmgrAonFatalFault = 18, /**< clkmgr_aon_fatal_fault */
1237 kTopDragonflyAlertIdPinmuxAonFatalFault = 19, /**< pinmux_aon_fatal_fault */
1238 kTopDragonflyAlertIdAonTimerAonFatalFault = 20, /**< aon_timer_aon_fatal_fault */
1239 kTopDragonflyAlertIdSocProxyFatalAlertIntg = 21, /**< soc_proxy_fatal_alert_intg */
1240 kTopDragonflyAlertIdSramCtrlRetAonFatalError = 22, /**< sram_ctrl_ret_aon_fatal_error */
1241 kTopDragonflyAlertIdRvDmFatalFault = 23, /**< rv_dm_fatal_fault */
1242 kTopDragonflyAlertIdRvPlicFatalFault = 24, /**< rv_plic_fatal_fault */
1243 kTopDragonflyAlertIdAccFatal = 25, /**< acc_fatal */
1244 kTopDragonflyAlertIdAccRecov = 26, /**< acc_recov */
1245 kTopDragonflyAlertIdAesRecovCtrlUpdateErr = 27, /**< aes_recov_ctrl_update_err */
1246 kTopDragonflyAlertIdAesFatalFault = 28, /**< aes_fatal_fault */
1247 kTopDragonflyAlertIdHmacFatalFault = 29, /**< hmac_fatal_fault */
1248 kTopDragonflyAlertIdKmacRecovOperationErr = 30, /**< kmac_recov_operation_err */
1249 kTopDragonflyAlertIdKmacFatalFaultErr = 31, /**< kmac_fatal_fault_err */
1250 kTopDragonflyAlertIdKeymgrDpeRecovOperationErr = 32, /**< keymgr_dpe_recov_operation_err */
1251 kTopDragonflyAlertIdKeymgrDpeFatalFaultErr = 33, /**< keymgr_dpe_fatal_fault_err */
1252 kTopDragonflyAlertIdCsrngRecovAlert = 34, /**< csrng_recov_alert */
1253 kTopDragonflyAlertIdCsrngFatalAlert = 35, /**< csrng_fatal_alert */
1254 kTopDragonflyAlertIdEntropySrcRecovAlert = 36, /**< entropy_src_recov_alert */
1255 kTopDragonflyAlertIdEntropySrcFatalAlert = 37, /**< entropy_src_fatal_alert */
1256 kTopDragonflyAlertIdEdn0RecovAlert = 38, /**< edn0_recov_alert */
1257 kTopDragonflyAlertIdEdn0FatalAlert = 39, /**< edn0_fatal_alert */
1258 kTopDragonflyAlertIdEdn1RecovAlert = 40, /**< edn1_recov_alert */
1259 kTopDragonflyAlertIdEdn1FatalAlert = 41, /**< edn1_fatal_alert */
1260 kTopDragonflyAlertIdSramCtrlMainFatalError = 42, /**< sram_ctrl_main_fatal_error */
1261 kTopDragonflyAlertIdSramCtrlMboxFatalError = 43, /**< sram_ctrl_mbox_fatal_error */
1262 kTopDragonflyAlertIdRomCtrl0Fatal = 44, /**< rom_ctrl0_fatal */
1263 kTopDragonflyAlertIdRomCtrl1Fatal = 45, /**< rom_ctrl1_fatal */
1264 kTopDragonflyAlertIdDmaFatalFault = 46, /**< dma_fatal_fault */
1265 kTopDragonflyAlertIdMbx0FatalFault = 47, /**< mbx0_fatal_fault */
1266 kTopDragonflyAlertIdMbx0RecovFault = 48, /**< mbx0_recov_fault */
1267 kTopDragonflyAlertIdMbx1FatalFault = 49, /**< mbx1_fatal_fault */
1268 kTopDragonflyAlertIdMbx1RecovFault = 50, /**< mbx1_recov_fault */
1269 kTopDragonflyAlertIdMbx2FatalFault = 51, /**< mbx2_fatal_fault */
1270 kTopDragonflyAlertIdMbx2RecovFault = 52, /**< mbx2_recov_fault */
1271 kTopDragonflyAlertIdMbx3FatalFault = 53, /**< mbx3_fatal_fault */
1272 kTopDragonflyAlertIdMbx3RecovFault = 54, /**< mbx3_recov_fault */
1273 kTopDragonflyAlertIdMbx4FatalFault = 55, /**< mbx4_fatal_fault */
1274 kTopDragonflyAlertIdMbx4RecovFault = 56, /**< mbx4_recov_fault */
1275 kTopDragonflyAlertIdMbx5FatalFault = 57, /**< mbx5_fatal_fault */
1276 kTopDragonflyAlertIdMbx5RecovFault = 58, /**< mbx5_recov_fault */
1277 kTopDragonflyAlertIdMbx6FatalFault = 59, /**< mbx6_fatal_fault */
1278 kTopDragonflyAlertIdMbx6RecovFault = 60, /**< mbx6_recov_fault */
1279 kTopDragonflyAlertIdMbxJtagFatalFault = 61, /**< mbx_jtag_fatal_fault */
1280 kTopDragonflyAlertIdMbxJtagRecovFault = 62, /**< mbx_jtag_recov_fault */
1281 kTopDragonflyAlertIdMbxPcie0FatalFault = 63, /**< mbx_pcie0_fatal_fault */
1282 kTopDragonflyAlertIdMbxPcie0RecovFault = 64, /**< mbx_pcie0_recov_fault */
1283 kTopDragonflyAlertIdMbxPcie1FatalFault = 65, /**< mbx_pcie1_fatal_fault */
1284 kTopDragonflyAlertIdMbxPcie1RecovFault = 66, /**< mbx_pcie1_recov_fault */
1285 kTopDragonflyAlertIdSocDbgCtrlFatalFault = 67, /**< soc_dbg_ctrl_fatal_fault */
1286 kTopDragonflyAlertIdSocDbgCtrlRecovCtrlUpdateErr = 68, /**< soc_dbg_ctrl_recov_ctrl_update_err */
1287 kTopDragonflyAlertIdRaclCtrlFatalFault = 69, /**< racl_ctrl_fatal_fault */
1288 kTopDragonflyAlertIdRaclCtrlRecovCtrlUpdateErr = 70, /**< racl_ctrl_recov_ctrl_update_err */
1289 kTopDragonflyAlertIdAcRangeCheckRecovCtrlUpdateErr = 71, /**< ac_range_check_recov_ctrl_update_err */
1290 kTopDragonflyAlertIdAcRangeCheckFatalFault = 72, /**< ac_range_check_fatal_fault */
1291 kTopDragonflyAlertIdRvCoreIbexFatalSwErr = 73, /**< rv_core_ibex_fatal_sw_err */
1292 kTopDragonflyAlertIdRvCoreIbexRecovSwErr = 74, /**< rv_core_ibex_recov_sw_err */
1293 kTopDragonflyAlertIdRvCoreIbexFatalHwErr = 75, /**< rv_core_ibex_fatal_hw_err */
1294 kTopDragonflyAlertIdRvCoreIbexRecovHwErr = 76, /**< rv_core_ibex_recov_hw_err */
1295 kTopDragonflyAlertIdLast = 76, /**< \internal The Last Valid Alert ID. */
1297
1298/**
1299 * Alert Handler Alert Source to Peripheral Map
1300 *
1301 * This array is a mapping from `top_dragonfly_alert_id_t` to
1302 * `top_dragonfly_alert_peripheral_t`.
1303 */
1305 top_dragonfly_alert_for_peripheral[77];
1306
1307#define PINMUX_MIO_PERIPH_INSEL_IDX_OFFSET 2
1308
1309// PERIPH_INSEL ranges from 0 to NUM_MIO_PADS + 2 -1}
1310// 0 and 1 are tied to value 0 and 1
1311#define NUM_MIO_PADS 12
1312#define NUM_DIO_PADS 73
1313
1314#define PINMUX_PERIPH_OUTSEL_IDX_OFFSET 3
1315
1316/**
1317 * Pinmux Peripheral Input.
1318 */
1324 kTopDragonflyPinmuxPeripheralInLast = 3, /**< \internal Last valid peripheral input */
1326
1327/**
1328 * Pinmux MIO Input Selector.
1329 */
1331 kTopDragonflyPinmuxInselConstantZero = 0, /**< Tie constantly to zero */
1332 kTopDragonflyPinmuxInselConstantOne = 1, /**< Tie constantly to one */
1333 kTopDragonflyPinmuxInselMio0 = 2, /**< MIO Pad 0 */
1334 kTopDragonflyPinmuxInselMio1 = 3, /**< MIO Pad 1 */
1335 kTopDragonflyPinmuxInselMio2 = 4, /**< MIO Pad 2 */
1336 kTopDragonflyPinmuxInselMio3 = 5, /**< MIO Pad 3 */
1337 kTopDragonflyPinmuxInselMio4 = 6, /**< MIO Pad 4 */
1338 kTopDragonflyPinmuxInselMio5 = 7, /**< MIO Pad 5 */
1339 kTopDragonflyPinmuxInselMio6 = 8, /**< MIO Pad 6 */
1340 kTopDragonflyPinmuxInselMio7 = 9, /**< MIO Pad 7 */
1341 kTopDragonflyPinmuxInselMio8 = 10, /**< MIO Pad 8 */
1342 kTopDragonflyPinmuxInselMio9 = 11, /**< MIO Pad 9 */
1343 kTopDragonflyPinmuxInselMio10 = 12, /**< MIO Pad 10 */
1344 kTopDragonflyPinmuxInselMio11 = 13, /**< MIO Pad 11 */
1345 kTopDragonflyPinmuxInselLast = 13, /**< \internal Last valid insel value */
1347
1348/**
1349 * Pinmux MIO Output.
1350 */
1352 kTopDragonflyPinmuxMioOutMio0 = 0, /**< MIO Pad 0 */
1353 kTopDragonflyPinmuxMioOutMio1 = 1, /**< MIO Pad 1 */
1354 kTopDragonflyPinmuxMioOutMio2 = 2, /**< MIO Pad 2 */
1355 kTopDragonflyPinmuxMioOutMio3 = 3, /**< MIO Pad 3 */
1356 kTopDragonflyPinmuxMioOutMio4 = 4, /**< MIO Pad 4 */
1357 kTopDragonflyPinmuxMioOutMio5 = 5, /**< MIO Pad 5 */
1358 kTopDragonflyPinmuxMioOutMio6 = 6, /**< MIO Pad 6 */
1359 kTopDragonflyPinmuxMioOutMio7 = 7, /**< MIO Pad 7 */
1360 kTopDragonflyPinmuxMioOutMio8 = 8, /**< MIO Pad 8 */
1361 kTopDragonflyPinmuxMioOutMio9 = 9, /**< MIO Pad 9 */
1362 kTopDragonflyPinmuxMioOutMio10 = 10, /**< MIO Pad 10 */
1363 kTopDragonflyPinmuxMioOutMio11 = 11, /**< MIO Pad 11 */
1364 kTopDragonflyPinmuxMioOutLast = 11, /**< \internal Last valid mio output */
1366
1367/**
1368 * Pinmux Peripheral Output Selector.
1369 */
1371 kTopDragonflyPinmuxOutselConstantZero = 0, /**< Tie constantly to zero */
1372 kTopDragonflyPinmuxOutselConstantOne = 1, /**< Tie constantly to one */
1373 kTopDragonflyPinmuxOutselConstantHighZ = 2, /**< Tie constantly to high-Z */
1374 kTopDragonflyPinmuxOutselSocProxySocGpo12 = 3, /**< Peripheral Output 0 */
1375 kTopDragonflyPinmuxOutselSocProxySocGpo13 = 4, /**< Peripheral Output 1 */
1376 kTopDragonflyPinmuxOutselSocProxySocGpo14 = 5, /**< Peripheral Output 2 */
1377 kTopDragonflyPinmuxOutselSocProxySocGpo15 = 6, /**< Peripheral Output 3 */
1378 kTopDragonflyPinmuxOutselOtpMacroTest0 = 7, /**< Peripheral Output 4 */
1379 kTopDragonflyPinmuxOutselLast = 7, /**< \internal Last valid outsel value */
1381
1382/**
1383 * Dedicated Pad Selects
1384 */
1386 kTopDragonflyDirectPadsSpiHost0Sd0 = 0, /**< */
1387 kTopDragonflyDirectPadsSpiHost0Sd1 = 1, /**< */
1388 kTopDragonflyDirectPadsSpiHost0Sd2 = 2, /**< */
1389 kTopDragonflyDirectPadsSpiHost0Sd3 = 3, /**< */
1390 kTopDragonflyDirectPadsSpiDeviceSd0 = 4, /**< */
1391 kTopDragonflyDirectPadsSpiDeviceSd1 = 5, /**< */
1392 kTopDragonflyDirectPadsSpiDeviceSd2 = 6, /**< */
1393 kTopDragonflyDirectPadsSpiDeviceSd3 = 7, /**< */
1394 kTopDragonflyDirectPadsI2c0Scl = 8, /**< */
1395 kTopDragonflyDirectPadsI2c0Sda = 9, /**< */
1396 kTopDragonflyDirectPadsGpioGpio0 = 10, /**< */
1397 kTopDragonflyDirectPadsGpioGpio1 = 11, /**< */
1398 kTopDragonflyDirectPadsGpioGpio2 = 12, /**< */
1399 kTopDragonflyDirectPadsGpioGpio3 = 13, /**< */
1400 kTopDragonflyDirectPadsGpioGpio4 = 14, /**< */
1401 kTopDragonflyDirectPadsGpioGpio5 = 15, /**< */
1402 kTopDragonflyDirectPadsGpioGpio6 = 16, /**< */
1403 kTopDragonflyDirectPadsGpioGpio7 = 17, /**< */
1404 kTopDragonflyDirectPadsGpioGpio8 = 18, /**< */
1405 kTopDragonflyDirectPadsGpioGpio9 = 19, /**< */
1406 kTopDragonflyDirectPadsGpioGpio10 = 20, /**< */
1407 kTopDragonflyDirectPadsGpioGpio11 = 21, /**< */
1408 kTopDragonflyDirectPadsGpioGpio12 = 22, /**< */
1409 kTopDragonflyDirectPadsGpioGpio13 = 23, /**< */
1410 kTopDragonflyDirectPadsGpioGpio14 = 24, /**< */
1411 kTopDragonflyDirectPadsGpioGpio15 = 25, /**< */
1412 kTopDragonflyDirectPadsGpioGpio16 = 26, /**< */
1413 kTopDragonflyDirectPadsGpioGpio17 = 27, /**< */
1414 kTopDragonflyDirectPadsGpioGpio18 = 28, /**< */
1415 kTopDragonflyDirectPadsGpioGpio19 = 29, /**< */
1416 kTopDragonflyDirectPadsGpioGpio20 = 30, /**< */
1417 kTopDragonflyDirectPadsGpioGpio21 = 31, /**< */
1418 kTopDragonflyDirectPadsGpioGpio22 = 32, /**< */
1419 kTopDragonflyDirectPadsGpioGpio23 = 33, /**< */
1420 kTopDragonflyDirectPadsGpioGpio24 = 34, /**< */
1421 kTopDragonflyDirectPadsGpioGpio25 = 35, /**< */
1422 kTopDragonflyDirectPadsGpioGpio26 = 36, /**< */
1423 kTopDragonflyDirectPadsGpioGpio27 = 37, /**< */
1424 kTopDragonflyDirectPadsGpioGpio28 = 38, /**< */
1425 kTopDragonflyDirectPadsGpioGpio29 = 39, /**< */
1426 kTopDragonflyDirectPadsGpioGpio30 = 40, /**< */
1427 kTopDragonflyDirectPadsGpioGpio31 = 41, /**< */
1428 kTopDragonflyDirectPadsSpiDeviceSck = 42, /**< */
1429 kTopDragonflyDirectPadsSpiDeviceCsb = 43, /**< */
1430 kTopDragonflyDirectPadsSpiDeviceTpmCsb = 44, /**< */
1431 kTopDragonflyDirectPadsUart0Rx = 45, /**< */
1432 kTopDragonflyDirectPadsSocProxySocGpi0 = 46, /**< */
1433 kTopDragonflyDirectPadsSocProxySocGpi1 = 47, /**< */
1434 kTopDragonflyDirectPadsSocProxySocGpi2 = 48, /**< */
1435 kTopDragonflyDirectPadsSocProxySocGpi3 = 49, /**< */
1436 kTopDragonflyDirectPadsSocProxySocGpi4 = 50, /**< */
1437 kTopDragonflyDirectPadsSocProxySocGpi5 = 51, /**< */
1438 kTopDragonflyDirectPadsSocProxySocGpi6 = 52, /**< */
1439 kTopDragonflyDirectPadsSocProxySocGpi7 = 53, /**< */
1440 kTopDragonflyDirectPadsSocProxySocGpi8 = 54, /**< */
1441 kTopDragonflyDirectPadsSocProxySocGpi9 = 55, /**< */
1442 kTopDragonflyDirectPadsSocProxySocGpi10 = 56, /**< */
1443 kTopDragonflyDirectPadsSocProxySocGpi11 = 57, /**< */
1444 kTopDragonflyDirectPadsSpiHost0Sck = 58, /**< */
1445 kTopDragonflyDirectPadsSpiHost0Csb = 59, /**< */
1446 kTopDragonflyDirectPadsUart0Tx = 60, /**< */
1447 kTopDragonflyDirectPadsSocProxySocGpo0 = 61, /**< */
1448 kTopDragonflyDirectPadsSocProxySocGpo1 = 62, /**< */
1449 kTopDragonflyDirectPadsSocProxySocGpo2 = 63, /**< */
1450 kTopDragonflyDirectPadsSocProxySocGpo3 = 64, /**< */
1451 kTopDragonflyDirectPadsSocProxySocGpo4 = 65, /**< */
1452 kTopDragonflyDirectPadsSocProxySocGpo5 = 66, /**< */
1453 kTopDragonflyDirectPadsSocProxySocGpo6 = 67, /**< */
1454 kTopDragonflyDirectPadsSocProxySocGpo7 = 68, /**< */
1455 kTopDragonflyDirectPadsSocProxySocGpo8 = 69, /**< */
1456 kTopDragonflyDirectPadsSocProxySocGpo9 = 70, /**< */
1457 kTopDragonflyDirectPadsSocProxySocGpo10 = 71, /**< */
1458 kTopDragonflyDirectPadsSocProxySocGpo11 = 72, /**< */
1459 kTopDragonflyDirectPadsLast = 72, /**< \internal Last valid direct pad */
1461
1462/**
1463 * Muxed Pad Selects
1464 */
1466 kTopDragonflyMuxedPadsMio0 = 0, /**< */
1467 kTopDragonflyMuxedPadsMio1 = 1, /**< */
1468 kTopDragonflyMuxedPadsMio2 = 2, /**< */
1469 kTopDragonflyMuxedPadsMio3 = 3, /**< */
1470 kTopDragonflyMuxedPadsMio4 = 4, /**< */
1471 kTopDragonflyMuxedPadsMio5 = 5, /**< */
1472 kTopDragonflyMuxedPadsMio6 = 6, /**< */
1473 kTopDragonflyMuxedPadsMio7 = 7, /**< */
1474 kTopDragonflyMuxedPadsMio8 = 8, /**< */
1475 kTopDragonflyMuxedPadsMio9 = 9, /**< */
1476 kTopDragonflyMuxedPadsMio10 = 10, /**< */
1477 kTopDragonflyMuxedPadsMio11 = 11, /**< */
1478 kTopDragonflyMuxedPadsLast = 11, /**< \internal Last valid muxed pad */
1480
1481/**
1482 * Power Manager Wakeup Signals
1483 */
1485 kTopDragonflyPowerManagerWakeUpsPinmuxAonPinWkupReq = 0, /**< */
1486 kTopDragonflyPowerManagerWakeUpsAonTimerAonWkupReq = 1, /**< */
1487 kTopDragonflyPowerManagerWakeUpsSocProxyWkupExternalReq = 2, /**< */
1488 kTopDragonflyPowerManagerWakeUpsLast = 2, /**< \internal Last valid pwrmgr wakeup signal */
1490
1491/**
1492 * Reset Manager Software Controlled Resets
1493 */
1495 kTopDragonflyResetManagerSwResetsSpiDevice = 0, /**< */
1496 kTopDragonflyResetManagerSwResetsSpiHost0 = 1, /**< */
1497 kTopDragonflyResetManagerSwResetsI2c0 = 2, /**< */
1498 kTopDragonflyResetManagerSwResetsLast = 2, /**< \internal Last valid rstmgr software reset request */
1500
1501/**
1502 * Power Manager Reset Request Signals
1503 */
1505 kTopDragonflyPowerManagerResetRequestsAonTimerAonAonTimerRstReq = 0, /**< */
1506 kTopDragonflyPowerManagerResetRequestsSocProxyRstReqExternal = 1, /**< */
1507 kTopDragonflyPowerManagerResetRequestsLast = 1, /**< \internal Last valid pwrmgr reset_request signal */
1509
1510/**
1511 * Clock Manager Software-Controlled ("Gated") Clocks.
1512 *
1513 * The Software has full control over these clocks.
1514 */
1516 kTopDragonflyGateableClocksIoPeri = 0, /**< Clock clk_io_peri in group peri */
1517 kTopDragonflyGateableClocksLast = 0, /**< \internal Last Valid Gateable Clock */
1519
1520/**
1521 * Clock Manager Software-Hinted Clocks.
1522 *
1523 * The Software has partial control over these clocks. It can ask them to stop,
1524 * but the clock manager is in control of whether the clock actually is stopped.
1525 */
1527 kTopDragonflyHintableClocksMainAcc = 0, /**< Clock clk_main_acc in group trans */
1528 kTopDragonflyHintableClocksMainAes = 1, /**< Clock clk_main_aes in group trans */
1529 kTopDragonflyHintableClocksMainHmac = 2, /**< Clock clk_main_hmac in group trans */
1530 kTopDragonflyHintableClocksMainKmac = 3, /**< Clock clk_main_kmac in group trans */
1531 kTopDragonflyHintableClocksLast = 3, /**< \internal Last Valid Hintable Clock */
1533
1534/**
1535 * MMIO Region
1536 *
1537 * MMIO region excludes any memory that is separate from the module
1538 * configuration space, i.e. ROM, main SRAM, and mbx SRAM are excluded but
1539 * retention SRAM or spi_device are included.
1540 */
1541#define TOP_DRAGONFLY_MMIO_BASE_ADDR 0x21100000u
1542#define TOP_DRAGONFLY_MMIO_SIZE_BYTES 0xF501000u
1543
1544// Header Extern Guard
1545#ifdef __cplusplus
1546} // extern "C"
1547#endif
1548
1549#endif // OPENTITAN_HW_TOP_DRAGONFLY_SW_AUTOGEN_TOP_DRAGONFLY_H_