Pavona Software APIs
top_egret.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_egret/data/autogen/top_egret.gen.hjson
8
9#ifndef OPENTITAN_HW_TOP_EGRET_SW_AUTOGEN_TOP_EGRET_H_
10#define OPENTITAN_HW_TOP_EGRET_SW_AUTOGEN_TOP_EGRET_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 egret.
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_EGRET_UART0_BASE_ADDR 0x40000000u
39
40/**
41 * Peripheral size for uart0 in top egret.
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_EGRET_UART0_BASE_ADDR and
46 * `TOP_EGRET_UART0_BASE_ADDR + TOP_EGRET_UART0_SIZE_BYTES`.
47 */
48#define TOP_EGRET_UART0_SIZE_BYTES 0x40u
49
50/**
51 * Peripheral base address for uart1 in top egret.
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_EGRET_UART1_BASE_ADDR 0x40010000u
57
58/**
59 * Peripheral size for uart1 in top egret.
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_EGRET_UART1_BASE_ADDR and
64 * `TOP_EGRET_UART1_BASE_ADDR + TOP_EGRET_UART1_SIZE_BYTES`.
65 */
66#define TOP_EGRET_UART1_SIZE_BYTES 0x40u
67
68/**
69 * Peripheral base address for uart2 in top egret.
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_EGRET_UART2_BASE_ADDR 0x40020000u
75
76/**
77 * Peripheral size for uart2 in top egret.
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_EGRET_UART2_BASE_ADDR and
82 * `TOP_EGRET_UART2_BASE_ADDR + TOP_EGRET_UART2_SIZE_BYTES`.
83 */
84#define TOP_EGRET_UART2_SIZE_BYTES 0x40u
85
86/**
87 * Peripheral base address for uart3 in top egret.
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_EGRET_UART3_BASE_ADDR 0x40030000u
93
94/**
95 * Peripheral size for uart3 in top egret.
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_EGRET_UART3_BASE_ADDR and
100 * `TOP_EGRET_UART3_BASE_ADDR + TOP_EGRET_UART3_SIZE_BYTES`.
101 */
102#define TOP_EGRET_UART3_SIZE_BYTES 0x40u
103
104/**
105 * Peripheral base address for gpio in top egret.
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_EGRET_GPIO_BASE_ADDR 0x40040000u
111
112/**
113 * Peripheral size for gpio in top egret.
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_EGRET_GPIO_BASE_ADDR and
118 * `TOP_EGRET_GPIO_BASE_ADDR + TOP_EGRET_GPIO_SIZE_BYTES`.
119 */
120#define TOP_EGRET_GPIO_SIZE_BYTES 0x80u
121
122/**
123 * Peripheral base address for spi_device in top egret.
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_EGRET_SPI_DEVICE_BASE_ADDR 0x40050000u
129
130/**
131 * Peripheral size for spi_device in top egret.
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_EGRET_SPI_DEVICE_BASE_ADDR and
136 * `TOP_EGRET_SPI_DEVICE_BASE_ADDR + TOP_EGRET_SPI_DEVICE_SIZE_BYTES`.
137 */
138#define TOP_EGRET_SPI_DEVICE_SIZE_BYTES 0x2000u
139
140/**
141 * Peripheral base address for i2c0 in top egret.
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_EGRET_I2C0_BASE_ADDR 0x40080000u
147
148/**
149 * Peripheral size for i2c0 in top egret.
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_EGRET_I2C0_BASE_ADDR and
154 * `TOP_EGRET_I2C0_BASE_ADDR + TOP_EGRET_I2C0_SIZE_BYTES`.
155 */
156#define TOP_EGRET_I2C0_SIZE_BYTES 0x80u
157
158/**
159 * Peripheral base address for i2c1 in top egret.
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_EGRET_I2C1_BASE_ADDR 0x40090000u
165
166/**
167 * Peripheral size for i2c1 in top egret.
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_EGRET_I2C1_BASE_ADDR and
172 * `TOP_EGRET_I2C1_BASE_ADDR + TOP_EGRET_I2C1_SIZE_BYTES`.
173 */
174#define TOP_EGRET_I2C1_SIZE_BYTES 0x80u
175
176/**
177 * Peripheral base address for i2c2 in top egret.
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_EGRET_I2C2_BASE_ADDR 0x400A0000u
183
184/**
185 * Peripheral size for i2c2 in top egret.
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_EGRET_I2C2_BASE_ADDR and
190 * `TOP_EGRET_I2C2_BASE_ADDR + TOP_EGRET_I2C2_SIZE_BYTES`.
191 */
192#define TOP_EGRET_I2C2_SIZE_BYTES 0x80u
193
194/**
195 * Peripheral base address for pattgen in top egret.
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_EGRET_PATTGEN_BASE_ADDR 0x400E0000u
201
202/**
203 * Peripheral size for pattgen in top egret.
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_EGRET_PATTGEN_BASE_ADDR and
208 * `TOP_EGRET_PATTGEN_BASE_ADDR + TOP_EGRET_PATTGEN_SIZE_BYTES`.
209 */
210#define TOP_EGRET_PATTGEN_SIZE_BYTES 0x40u
211
212/**
213 * Peripheral base address for rv_timer in top egret.
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_EGRET_RV_TIMER_BASE_ADDR 0x40100000u
219
220/**
221 * Peripheral size for rv_timer in top egret.
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_EGRET_RV_TIMER_BASE_ADDR and
226 * `TOP_EGRET_RV_TIMER_BASE_ADDR + TOP_EGRET_RV_TIMER_SIZE_BYTES`.
227 */
228#define TOP_EGRET_RV_TIMER_SIZE_BYTES 0x200u
229
230/**
231 * Peripheral base address for core device on otp_ctrl in top egret.
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_EGRET_OTP_CTRL_CORE_BASE_ADDR 0x40130000u
237
238/**
239 * Peripheral size for core device on otp_ctrl in top egret.
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_EGRET_OTP_CTRL_CORE_BASE_ADDR and
244 * `TOP_EGRET_OTP_CTRL_CORE_BASE_ADDR + TOP_EGRET_OTP_CTRL_CORE_SIZE_BYTES`.
245 */
246#define TOP_EGRET_OTP_CTRL_CORE_SIZE_BYTES 0x1000u
247
248/**
249 * Peripheral base address for prim device on otp_macro in top egret.
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_EGRET_OTP_MACRO_PRIM_BASE_ADDR 0x40138000u
255
256/**
257 * Peripheral size for prim device on otp_macro in top egret.
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_EGRET_OTP_MACRO_PRIM_BASE_ADDR and
262 * `TOP_EGRET_OTP_MACRO_PRIM_BASE_ADDR + TOP_EGRET_OTP_MACRO_PRIM_SIZE_BYTES`.
263 */
264#define TOP_EGRET_OTP_MACRO_PRIM_SIZE_BYTES 0x20u
265
266/**
267 * Peripheral base address for regs device on lc_ctrl in top egret.
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_EGRET_LC_CTRL_REGS_BASE_ADDR 0x40140000u
273
274/**
275 * Peripheral size for regs device on lc_ctrl in top egret.
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_EGRET_LC_CTRL_REGS_BASE_ADDR and
280 * `TOP_EGRET_LC_CTRL_REGS_BASE_ADDR + TOP_EGRET_LC_CTRL_REGS_SIZE_BYTES`.
281 */
282#define TOP_EGRET_LC_CTRL_REGS_SIZE_BYTES 0x100u
283
284/**
285 * Peripheral base address for dmi device on lc_ctrl in top egret.
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_EGRET_LC_CTRL_DMI_BASE_ADDR 0x0u
291
292/**
293 * Peripheral size for dmi device on lc_ctrl in top egret.
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_EGRET_LC_CTRL_DMI_BASE_ADDR and
298 * `TOP_EGRET_LC_CTRL_DMI_BASE_ADDR + TOP_EGRET_LC_CTRL_DMI_SIZE_BYTES`.
299 */
300#define TOP_EGRET_LC_CTRL_DMI_SIZE_BYTES 0x1000u
301
302/**
303 * Peripheral base address for alert_handler in top egret.
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_EGRET_ALERT_HANDLER_BASE_ADDR 0x40150000u
309
310/**
311 * Peripheral size for alert_handler in top egret.
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_EGRET_ALERT_HANDLER_BASE_ADDR and
316 * `TOP_EGRET_ALERT_HANDLER_BASE_ADDR + TOP_EGRET_ALERT_HANDLER_SIZE_BYTES`.
317 */
318#define TOP_EGRET_ALERT_HANDLER_SIZE_BYTES 0x800u
319
320/**
321 * Peripheral base address for spi_host0 in top egret.
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_EGRET_SPI_HOST0_BASE_ADDR 0x40300000u
327
328/**
329 * Peripheral size for spi_host0 in top egret.
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_EGRET_SPI_HOST0_BASE_ADDR and
334 * `TOP_EGRET_SPI_HOST0_BASE_ADDR + TOP_EGRET_SPI_HOST0_SIZE_BYTES`.
335 */
336#define TOP_EGRET_SPI_HOST0_SIZE_BYTES 0x40u
337
338/**
339 * Peripheral base address for spi_host1 in top egret.
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_EGRET_SPI_HOST1_BASE_ADDR 0x40310000u
345
346/**
347 * Peripheral size for spi_host1 in top egret.
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_EGRET_SPI_HOST1_BASE_ADDR and
352 * `TOP_EGRET_SPI_HOST1_BASE_ADDR + TOP_EGRET_SPI_HOST1_SIZE_BYTES`.
353 */
354#define TOP_EGRET_SPI_HOST1_SIZE_BYTES 0x40u
355
356/**
357 * Peripheral base address for usbdev in top egret.
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_EGRET_USBDEV_BASE_ADDR 0x40320000u
363
364/**
365 * Peripheral size for usbdev in top egret.
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_EGRET_USBDEV_BASE_ADDR and
370 * `TOP_EGRET_USBDEV_BASE_ADDR + TOP_EGRET_USBDEV_SIZE_BYTES`.
371 */
372#define TOP_EGRET_USBDEV_SIZE_BYTES 0x1000u
373
374/**
375 * Peripheral base address for pwrmgr_aon in top egret.
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_EGRET_PWRMGR_AON_BASE_ADDR 0x40400000u
381
382/**
383 * Peripheral size for pwrmgr_aon in top egret.
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_EGRET_PWRMGR_AON_BASE_ADDR and
388 * `TOP_EGRET_PWRMGR_AON_BASE_ADDR + TOP_EGRET_PWRMGR_AON_SIZE_BYTES`.
389 */
390#define TOP_EGRET_PWRMGR_AON_SIZE_BYTES 0x80u
391
392/**
393 * Peripheral base address for rstmgr_aon in top egret.
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_EGRET_RSTMGR_AON_BASE_ADDR 0x40410000u
399
400/**
401 * Peripheral size for rstmgr_aon in top egret.
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_EGRET_RSTMGR_AON_BASE_ADDR and
406 * `TOP_EGRET_RSTMGR_AON_BASE_ADDR + TOP_EGRET_RSTMGR_AON_SIZE_BYTES`.
407 */
408#define TOP_EGRET_RSTMGR_AON_SIZE_BYTES 0x80u
409
410/**
411 * Peripheral base address for clkmgr_aon in top egret.
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_EGRET_CLKMGR_AON_BASE_ADDR 0x40420000u
417
418/**
419 * Peripheral size for clkmgr_aon in top egret.
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_EGRET_CLKMGR_AON_BASE_ADDR and
424 * `TOP_EGRET_CLKMGR_AON_BASE_ADDR + TOP_EGRET_CLKMGR_AON_SIZE_BYTES`.
425 */
426#define TOP_EGRET_CLKMGR_AON_SIZE_BYTES 0x80u
427
428/**
429 * Peripheral base address for sysrst_ctrl_aon in top egret.
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_EGRET_SYSRST_CTRL_AON_BASE_ADDR 0x40430000u
435
436/**
437 * Peripheral size for sysrst_ctrl_aon in top egret.
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_EGRET_SYSRST_CTRL_AON_BASE_ADDR and
442 * `TOP_EGRET_SYSRST_CTRL_AON_BASE_ADDR + TOP_EGRET_SYSRST_CTRL_AON_SIZE_BYTES`.
443 */
444#define TOP_EGRET_SYSRST_CTRL_AON_SIZE_BYTES 0x100u
445
446/**
447 * Peripheral base address for adc_ctrl_aon in top egret.
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_EGRET_ADC_CTRL_AON_BASE_ADDR 0x40440000u
453
454/**
455 * Peripheral size for adc_ctrl_aon in top egret.
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_EGRET_ADC_CTRL_AON_BASE_ADDR and
460 * `TOP_EGRET_ADC_CTRL_AON_BASE_ADDR + TOP_EGRET_ADC_CTRL_AON_SIZE_BYTES`.
461 */
462#define TOP_EGRET_ADC_CTRL_AON_SIZE_BYTES 0x80u
463
464/**
465 * Peripheral base address for pwm_aon in top egret.
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_EGRET_PWM_AON_BASE_ADDR 0x40450000u
471
472/**
473 * Peripheral size for pwm_aon in top egret.
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_EGRET_PWM_AON_BASE_ADDR and
478 * `TOP_EGRET_PWM_AON_BASE_ADDR + TOP_EGRET_PWM_AON_SIZE_BYTES`.
479 */
480#define TOP_EGRET_PWM_AON_SIZE_BYTES 0x80u
481
482/**
483 * Peripheral base address for pinmux_aon in top egret.
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_EGRET_PINMUX_AON_BASE_ADDR 0x40460000u
489
490/**
491 * Peripheral size for pinmux_aon in top egret.
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_EGRET_PINMUX_AON_BASE_ADDR and
496 * `TOP_EGRET_PINMUX_AON_BASE_ADDR + TOP_EGRET_PINMUX_AON_SIZE_BYTES`.
497 */
498#define TOP_EGRET_PINMUX_AON_SIZE_BYTES 0x1000u
499
500/**
501 * Peripheral base address for aon_timer_aon in top egret.
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_EGRET_AON_TIMER_AON_BASE_ADDR 0x40470000u
507
508/**
509 * Peripheral size for aon_timer_aon in top egret.
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_EGRET_AON_TIMER_AON_BASE_ADDR and
514 * `TOP_EGRET_AON_TIMER_AON_BASE_ADDR + TOP_EGRET_AON_TIMER_AON_SIZE_BYTES`.
515 */
516#define TOP_EGRET_AON_TIMER_AON_SIZE_BYTES 0x40u
517
518/**
519 * Peripheral base address for ast in top egret.
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_EGRET_AST_BASE_ADDR 0x40480000u
525
526/**
527 * Peripheral size for ast in top egret.
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_EGRET_AST_BASE_ADDR and
532 * `TOP_EGRET_AST_BASE_ADDR + TOP_EGRET_AST_SIZE_BYTES`.
533 */
534#define TOP_EGRET_AST_SIZE_BYTES 0x400u
535
536/**
537 * Peripheral base address for sensor_ctrl_aon in top egret.
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_EGRET_SENSOR_CTRL_AON_BASE_ADDR 0x40490000u
543
544/**
545 * Peripheral size for sensor_ctrl_aon in top egret.
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_EGRET_SENSOR_CTRL_AON_BASE_ADDR and
550 * `TOP_EGRET_SENSOR_CTRL_AON_BASE_ADDR + TOP_EGRET_SENSOR_CTRL_AON_SIZE_BYTES`.
551 */
552#define TOP_EGRET_SENSOR_CTRL_AON_SIZE_BYTES 0x80u
553
554/**
555 * Peripheral base address for regs device on sram_ctrl_ret_aon in top egret.
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_EGRET_SRAM_CTRL_RET_AON_REGS_BASE_ADDR 0x40500000u
561
562/**
563 * Peripheral size for regs device on sram_ctrl_ret_aon in top egret.
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_EGRET_SRAM_CTRL_RET_AON_REGS_BASE_ADDR and
568 * `TOP_EGRET_SRAM_CTRL_RET_AON_REGS_BASE_ADDR + TOP_EGRET_SRAM_CTRL_RET_AON_REGS_SIZE_BYTES`.
569 */
570#define TOP_EGRET_SRAM_CTRL_RET_AON_REGS_SIZE_BYTES 0x40u
571
572/**
573 * Peripheral base address for core device on flash_ctrl in top egret.
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_EGRET_FLASH_CTRL_CORE_BASE_ADDR 0x41000000u
579
580/**
581 * Peripheral size for core device on flash_ctrl in top egret.
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_EGRET_FLASH_CTRL_CORE_BASE_ADDR and
586 * `TOP_EGRET_FLASH_CTRL_CORE_BASE_ADDR + TOP_EGRET_FLASH_CTRL_CORE_SIZE_BYTES`.
587 */
588#define TOP_EGRET_FLASH_CTRL_CORE_SIZE_BYTES 0x200u
589
590/**
591 * Peripheral base address for flash_macro_wrapper in top egret.
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_EGRET_FLASH_MACRO_WRAPPER_BASE_ADDR 0x41008000u
597
598/**
599 * Peripheral size for flash_macro_wrapper in top egret.
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_EGRET_FLASH_MACRO_WRAPPER_BASE_ADDR and
604 * `TOP_EGRET_FLASH_MACRO_WRAPPER_BASE_ADDR + TOP_EGRET_FLASH_MACRO_WRAPPER_SIZE_BYTES`.
605 */
606#define TOP_EGRET_FLASH_MACRO_WRAPPER_SIZE_BYTES 0x80u
607
608/**
609 * Peripheral base address for regs device on rv_dm in top egret.
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_EGRET_RV_DM_REGS_BASE_ADDR 0x41200000u
615
616/**
617 * Peripheral size for regs device on rv_dm in top egret.
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_EGRET_RV_DM_REGS_BASE_ADDR and
622 * `TOP_EGRET_RV_DM_REGS_BASE_ADDR + TOP_EGRET_RV_DM_REGS_SIZE_BYTES`.
623 */
624#define TOP_EGRET_RV_DM_REGS_SIZE_BYTES 0x10u
625
626/**
627 * Peripheral base address for mem device on rv_dm in top egret.
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_EGRET_RV_DM_MEM_BASE_ADDR 0x10000u
633
634/**
635 * Peripheral size for mem device on rv_dm in top egret.
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_EGRET_RV_DM_MEM_BASE_ADDR and
640 * `TOP_EGRET_RV_DM_MEM_BASE_ADDR + TOP_EGRET_RV_DM_MEM_SIZE_BYTES`.
641 */
642#define TOP_EGRET_RV_DM_MEM_SIZE_BYTES 0x1000u
643
644/**
645 * Peripheral base address for dbg device on rv_dm in top egret.
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_EGRET_RV_DM_DBG_BASE_ADDR 0x1000u
651
652/**
653 * Peripheral size for dbg device on rv_dm in top egret.
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_EGRET_RV_DM_DBG_BASE_ADDR and
658 * `TOP_EGRET_RV_DM_DBG_BASE_ADDR + TOP_EGRET_RV_DM_DBG_SIZE_BYTES`.
659 */
660#define TOP_EGRET_RV_DM_DBG_SIZE_BYTES 0x200u
661
662/**
663 * Peripheral base address for rv_plic in top egret.
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_EGRET_RV_PLIC_BASE_ADDR 0x48000000u
669
670/**
671 * Peripheral size for rv_plic in top egret.
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_EGRET_RV_PLIC_BASE_ADDR and
676 * `TOP_EGRET_RV_PLIC_BASE_ADDR + TOP_EGRET_RV_PLIC_SIZE_BYTES`.
677 */
678#define TOP_EGRET_RV_PLIC_SIZE_BYTES 0x8000000u
679
680/**
681 * Peripheral base address for acc in top egret.
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_EGRET_ACC_BASE_ADDR 0x41300000u
687
688/**
689 * Peripheral size for acc in top egret.
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_EGRET_ACC_BASE_ADDR and
694 * `TOP_EGRET_ACC_BASE_ADDR + TOP_EGRET_ACC_SIZE_BYTES`.
695 */
696#define TOP_EGRET_ACC_SIZE_BYTES 0x20000u
697
698/**
699 * Peripheral base address for aes in top egret.
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_EGRET_AES_BASE_ADDR 0x41100000u
705
706/**
707 * Peripheral size for aes in top egret.
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_EGRET_AES_BASE_ADDR and
712 * `TOP_EGRET_AES_BASE_ADDR + TOP_EGRET_AES_SIZE_BYTES`.
713 */
714#define TOP_EGRET_AES_SIZE_BYTES 0x100u
715
716/**
717 * Peripheral base address for hmac in top egret.
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_EGRET_HMAC_BASE_ADDR 0x41110000u
723
724/**
725 * Peripheral size for hmac in top egret.
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_EGRET_HMAC_BASE_ADDR and
730 * `TOP_EGRET_HMAC_BASE_ADDR + TOP_EGRET_HMAC_SIZE_BYTES`.
731 */
732#define TOP_EGRET_HMAC_SIZE_BYTES 0x2000u
733
734/**
735 * Peripheral base address for kmac in top egret.
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_EGRET_KMAC_BASE_ADDR 0x41120000u
741
742/**
743 * Peripheral size for kmac in top egret.
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_EGRET_KMAC_BASE_ADDR and
748 * `TOP_EGRET_KMAC_BASE_ADDR + TOP_EGRET_KMAC_SIZE_BYTES`.
749 */
750#define TOP_EGRET_KMAC_SIZE_BYTES 0x1000u
751
752/**
753 * Peripheral base address for keymgr in top egret.
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_EGRET_KEYMGR_BASE_ADDR 0x41140000u
759
760/**
761 * Peripheral size for keymgr in top egret.
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_EGRET_KEYMGR_BASE_ADDR and
766 * `TOP_EGRET_KEYMGR_BASE_ADDR + TOP_EGRET_KEYMGR_SIZE_BYTES`.
767 */
768#define TOP_EGRET_KEYMGR_SIZE_BYTES 0x100u
769
770/**
771 * Peripheral base address for csrng in top egret.
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_EGRET_CSRNG_BASE_ADDR 0x41150000u
777
778/**
779 * Peripheral size for csrng in top egret.
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_EGRET_CSRNG_BASE_ADDR and
784 * `TOP_EGRET_CSRNG_BASE_ADDR + TOP_EGRET_CSRNG_SIZE_BYTES`.
785 */
786#define TOP_EGRET_CSRNG_SIZE_BYTES 0x80u
787
788/**
789 * Peripheral base address for entropy_src in top egret.
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_EGRET_ENTROPY_SRC_BASE_ADDR 0x41160000u
795
796/**
797 * Peripheral size for entropy_src in top egret.
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_EGRET_ENTROPY_SRC_BASE_ADDR and
802 * `TOP_EGRET_ENTROPY_SRC_BASE_ADDR + TOP_EGRET_ENTROPY_SRC_SIZE_BYTES`.
803 */
804#define TOP_EGRET_ENTROPY_SRC_SIZE_BYTES 0x100u
805
806/**
807 * Peripheral base address for edn0 in top egret.
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_EGRET_EDN0_BASE_ADDR 0x41170000u
813
814/**
815 * Peripheral size for edn0 in top egret.
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_EGRET_EDN0_BASE_ADDR and
820 * `TOP_EGRET_EDN0_BASE_ADDR + TOP_EGRET_EDN0_SIZE_BYTES`.
821 */
822#define TOP_EGRET_EDN0_SIZE_BYTES 0x80u
823
824/**
825 * Peripheral base address for edn1 in top egret.
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_EGRET_EDN1_BASE_ADDR 0x41180000u
831
832/**
833 * Peripheral size for edn1 in top egret.
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_EGRET_EDN1_BASE_ADDR and
838 * `TOP_EGRET_EDN1_BASE_ADDR + TOP_EGRET_EDN1_SIZE_BYTES`.
839 */
840#define TOP_EGRET_EDN1_SIZE_BYTES 0x80u
841
842/**
843 * Peripheral base address for regs device on sram_ctrl_main in top egret.
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_EGRET_SRAM_CTRL_MAIN_REGS_BASE_ADDR 0x411C0000u
849
850/**
851 * Peripheral size for regs device on sram_ctrl_main in top egret.
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_EGRET_SRAM_CTRL_MAIN_REGS_BASE_ADDR and
856 * `TOP_EGRET_SRAM_CTRL_MAIN_REGS_BASE_ADDR + TOP_EGRET_SRAM_CTRL_MAIN_REGS_SIZE_BYTES`.
857 */
858#define TOP_EGRET_SRAM_CTRL_MAIN_REGS_SIZE_BYTES 0x40u
859
860/**
861 * Peripheral base address for regs device on rom_ctrl in top egret.
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_EGRET_ROM_CTRL_REGS_BASE_ADDR 0x411E0000u
867
868/**
869 * Peripheral size for regs device on rom_ctrl in top egret.
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_EGRET_ROM_CTRL_REGS_BASE_ADDR and
874 * `TOP_EGRET_ROM_CTRL_REGS_BASE_ADDR + TOP_EGRET_ROM_CTRL_REGS_SIZE_BYTES`.
875 */
876#define TOP_EGRET_ROM_CTRL_REGS_SIZE_BYTES 0x80u
877
878/**
879 * Peripheral base address for cfg device on rv_core_ibex in top egret.
880 *
881 * This should be used with #mmio_region_from_addr to access the memory-mapped
882 * registers associated with the peripheral (usually via a DIF).
883 */
884#define TOP_EGRET_RV_CORE_IBEX_CFG_BASE_ADDR 0x411F0000u
885
886/**
887 * Peripheral size for cfg device on rv_core_ibex in top egret.
888 *
889 * This is the size (in bytes) of the peripheral's reserved memory area. All
890 * memory-mapped registers associated with this peripheral should have an
891 * address between #TOP_EGRET_RV_CORE_IBEX_CFG_BASE_ADDR and
892 * `TOP_EGRET_RV_CORE_IBEX_CFG_BASE_ADDR + TOP_EGRET_RV_CORE_IBEX_CFG_SIZE_BYTES`.
893 */
894#define TOP_EGRET_RV_CORE_IBEX_CFG_SIZE_BYTES 0x100u
895
896
897/**
898 * Memory base address for ram memory on sram_ctrl_ret_aon in top egret.
899 */
900#define TOP_EGRET_SRAM_CTRL_RET_AON_RAM_BASE_ADDR 0x40600000u
901
902/**
903 * Memory size for ram memory on sram_ctrl_ret_aon in top egret.
904 */
905#define TOP_EGRET_SRAM_CTRL_RET_AON_RAM_SIZE_BYTES 0x1000u
906
907/**
908 * Memory base address for mem memory on flash_ctrl in top egret.
909 */
910#define TOP_EGRET_FLASH_CTRL_MEM_BASE_ADDR 0x20000000u
911
912/**
913 * Memory size for mem memory on flash_ctrl in top egret.
914 */
915#define TOP_EGRET_FLASH_CTRL_MEM_SIZE_BYTES 0x100000u
916
917/**
918 * Memory base address for ram memory on sram_ctrl_main in top egret.
919 */
920#define TOP_EGRET_SRAM_CTRL_MAIN_RAM_BASE_ADDR 0x10000000u
921
922/**
923 * Memory size for ram memory on sram_ctrl_main in top egret.
924 */
925#define TOP_EGRET_SRAM_CTRL_MAIN_RAM_SIZE_BYTES 0x20000u
926
927/**
928 * Memory base address for rom memory on rom_ctrl in top egret.
929 */
930#define TOP_EGRET_ROM_CTRL_ROM_BASE_ADDR 0x8000u
931
932/**
933 * Memory size for rom memory on rom_ctrl in top egret.
934 */
935#define TOP_EGRET_ROM_CTRL_ROM_SIZE_BYTES 0x8000u
936
937
938/**
939 * PLIC Interrupt Source Peripheral.
940 *
941 * Enumeration used to determine which peripheral asserted the corresponding
942 * interrupt.
943 */
945 kTopEgretPlicPeripheralUnknown = 0, /**< Unknown Peripheral */
951 kTopEgretPlicPeripheralSpiDevice = 6, /**< spi_device */
955 kTopEgretPlicPeripheralPattgen = 10, /**< pattgen */
956 kTopEgretPlicPeripheralRvTimer = 11, /**< rv_timer */
957 kTopEgretPlicPeripheralOtpCtrl = 12, /**< otp_ctrl */
958 kTopEgretPlicPeripheralAlertHandler = 13, /**< alert_handler */
959 kTopEgretPlicPeripheralSpiHost0 = 14, /**< spi_host0 */
960 kTopEgretPlicPeripheralSpiHost1 = 15, /**< spi_host1 */
961 kTopEgretPlicPeripheralUsbdev = 16, /**< usbdev */
962 kTopEgretPlicPeripheralPwrmgrAon = 17, /**< pwrmgr_aon */
963 kTopEgretPlicPeripheralSysrstCtrlAon = 18, /**< sysrst_ctrl_aon */
964 kTopEgretPlicPeripheralAdcCtrlAon = 19, /**< adc_ctrl_aon */
965 kTopEgretPlicPeripheralAonTimerAon = 20, /**< aon_timer_aon */
966 kTopEgretPlicPeripheralSensorCtrlAon = 21, /**< sensor_ctrl_aon */
967 kTopEgretPlicPeripheralFlashCtrl = 22, /**< flash_ctrl */
971 kTopEgretPlicPeripheralKeymgr = 26, /**< keymgr */
973 kTopEgretPlicPeripheralEntropySrc = 28, /**< entropy_src */
976 kTopEgretPlicPeripheralLast = 30, /**< \internal Final PLIC peripheral */
978
979/**
980 * PLIC Interrupt Source.
981 *
982 * Enumeration of all PLIC interrupt sources. The interrupt sources belonging to
983 * the same peripheral are guaranteed to be consecutive.
984 */
986 kTopEgretPlicIrqIdNone = 0, /**< No Interrupt */
987 kTopEgretPlicIrqIdUart0TxWatermark = 1, /**< uart0_tx_watermark */
988 kTopEgretPlicIrqIdUart0RxWatermark = 2, /**< uart0_rx_watermark */
989 kTopEgretPlicIrqIdUart0TxDone = 3, /**< uart0_tx_done */
990 kTopEgretPlicIrqIdUart0RxOverflow = 4, /**< uart0_rx_overflow */
991 kTopEgretPlicIrqIdUart0RxFrameErr = 5, /**< uart0_rx_frame_err */
992 kTopEgretPlicIrqIdUart0RxBreakErr = 6, /**< uart0_rx_break_err */
993 kTopEgretPlicIrqIdUart0RxTimeout = 7, /**< uart0_rx_timeout */
994 kTopEgretPlicIrqIdUart0RxParityErr = 8, /**< uart0_rx_parity_err */
995 kTopEgretPlicIrqIdUart0TxEmpty = 9, /**< uart0_tx_empty */
996 kTopEgretPlicIrqIdUart1TxWatermark = 10, /**< uart1_tx_watermark */
997 kTopEgretPlicIrqIdUart1RxWatermark = 11, /**< uart1_rx_watermark */
998 kTopEgretPlicIrqIdUart1TxDone = 12, /**< uart1_tx_done */
999 kTopEgretPlicIrqIdUart1RxOverflow = 13, /**< uart1_rx_overflow */
1000 kTopEgretPlicIrqIdUart1RxFrameErr = 14, /**< uart1_rx_frame_err */
1001 kTopEgretPlicIrqIdUart1RxBreakErr = 15, /**< uart1_rx_break_err */
1002 kTopEgretPlicIrqIdUart1RxTimeout = 16, /**< uart1_rx_timeout */
1003 kTopEgretPlicIrqIdUart1RxParityErr = 17, /**< uart1_rx_parity_err */
1004 kTopEgretPlicIrqIdUart1TxEmpty = 18, /**< uart1_tx_empty */
1005 kTopEgretPlicIrqIdUart2TxWatermark = 19, /**< uart2_tx_watermark */
1006 kTopEgretPlicIrqIdUart2RxWatermark = 20, /**< uart2_rx_watermark */
1007 kTopEgretPlicIrqIdUart2TxDone = 21, /**< uart2_tx_done */
1008 kTopEgretPlicIrqIdUart2RxOverflow = 22, /**< uart2_rx_overflow */
1009 kTopEgretPlicIrqIdUart2RxFrameErr = 23, /**< uart2_rx_frame_err */
1010 kTopEgretPlicIrqIdUart2RxBreakErr = 24, /**< uart2_rx_break_err */
1011 kTopEgretPlicIrqIdUart2RxTimeout = 25, /**< uart2_rx_timeout */
1012 kTopEgretPlicIrqIdUart2RxParityErr = 26, /**< uart2_rx_parity_err */
1013 kTopEgretPlicIrqIdUart2TxEmpty = 27, /**< uart2_tx_empty */
1014 kTopEgretPlicIrqIdUart3TxWatermark = 28, /**< uart3_tx_watermark */
1015 kTopEgretPlicIrqIdUart3RxWatermark = 29, /**< uart3_rx_watermark */
1016 kTopEgretPlicIrqIdUart3TxDone = 30, /**< uart3_tx_done */
1017 kTopEgretPlicIrqIdUart3RxOverflow = 31, /**< uart3_rx_overflow */
1018 kTopEgretPlicIrqIdUart3RxFrameErr = 32, /**< uart3_rx_frame_err */
1019 kTopEgretPlicIrqIdUart3RxBreakErr = 33, /**< uart3_rx_break_err */
1020 kTopEgretPlicIrqIdUart3RxTimeout = 34, /**< uart3_rx_timeout */
1021 kTopEgretPlicIrqIdUart3RxParityErr = 35, /**< uart3_rx_parity_err */
1022 kTopEgretPlicIrqIdUart3TxEmpty = 36, /**< uart3_tx_empty */
1023 kTopEgretPlicIrqIdGpioGpio0 = 37, /**< gpio_gpio 0 */
1024 kTopEgretPlicIrqIdGpioGpio1 = 38, /**< gpio_gpio 1 */
1025 kTopEgretPlicIrqIdGpioGpio2 = 39, /**< gpio_gpio 2 */
1026 kTopEgretPlicIrqIdGpioGpio3 = 40, /**< gpio_gpio 3 */
1027 kTopEgretPlicIrqIdGpioGpio4 = 41, /**< gpio_gpio 4 */
1028 kTopEgretPlicIrqIdGpioGpio5 = 42, /**< gpio_gpio 5 */
1029 kTopEgretPlicIrqIdGpioGpio6 = 43, /**< gpio_gpio 6 */
1030 kTopEgretPlicIrqIdGpioGpio7 = 44, /**< gpio_gpio 7 */
1031 kTopEgretPlicIrqIdGpioGpio8 = 45, /**< gpio_gpio 8 */
1032 kTopEgretPlicIrqIdGpioGpio9 = 46, /**< gpio_gpio 9 */
1033 kTopEgretPlicIrqIdGpioGpio10 = 47, /**< gpio_gpio 10 */
1034 kTopEgretPlicIrqIdGpioGpio11 = 48, /**< gpio_gpio 11 */
1035 kTopEgretPlicIrqIdGpioGpio12 = 49, /**< gpio_gpio 12 */
1036 kTopEgretPlicIrqIdGpioGpio13 = 50, /**< gpio_gpio 13 */
1037 kTopEgretPlicIrqIdGpioGpio14 = 51, /**< gpio_gpio 14 */
1038 kTopEgretPlicIrqIdGpioGpio15 = 52, /**< gpio_gpio 15 */
1039 kTopEgretPlicIrqIdGpioGpio16 = 53, /**< gpio_gpio 16 */
1040 kTopEgretPlicIrqIdGpioGpio17 = 54, /**< gpio_gpio 17 */
1041 kTopEgretPlicIrqIdGpioGpio18 = 55, /**< gpio_gpio 18 */
1042 kTopEgretPlicIrqIdGpioGpio19 = 56, /**< gpio_gpio 19 */
1043 kTopEgretPlicIrqIdGpioGpio20 = 57, /**< gpio_gpio 20 */
1044 kTopEgretPlicIrqIdGpioGpio21 = 58, /**< gpio_gpio 21 */
1045 kTopEgretPlicIrqIdGpioGpio22 = 59, /**< gpio_gpio 22 */
1046 kTopEgretPlicIrqIdGpioGpio23 = 60, /**< gpio_gpio 23 */
1047 kTopEgretPlicIrqIdGpioGpio24 = 61, /**< gpio_gpio 24 */
1048 kTopEgretPlicIrqIdGpioGpio25 = 62, /**< gpio_gpio 25 */
1049 kTopEgretPlicIrqIdGpioGpio26 = 63, /**< gpio_gpio 26 */
1050 kTopEgretPlicIrqIdGpioGpio27 = 64, /**< gpio_gpio 27 */
1051 kTopEgretPlicIrqIdGpioGpio28 = 65, /**< gpio_gpio 28 */
1052 kTopEgretPlicIrqIdGpioGpio29 = 66, /**< gpio_gpio 29 */
1053 kTopEgretPlicIrqIdGpioGpio30 = 67, /**< gpio_gpio 30 */
1054 kTopEgretPlicIrqIdGpioGpio31 = 68, /**< gpio_gpio 31 */
1055 kTopEgretPlicIrqIdSpiDeviceUploadCmdfifoNotEmpty = 69, /**< spi_device_upload_cmdfifo_not_empty */
1056 kTopEgretPlicIrqIdSpiDeviceUploadPayloadNotEmpty = 70, /**< spi_device_upload_payload_not_empty */
1057 kTopEgretPlicIrqIdSpiDeviceUploadPayloadOverflow = 71, /**< spi_device_upload_payload_overflow */
1058 kTopEgretPlicIrqIdSpiDeviceReadbufWatermark = 72, /**< spi_device_readbuf_watermark */
1059 kTopEgretPlicIrqIdSpiDeviceReadbufFlip = 73, /**< spi_device_readbuf_flip */
1060 kTopEgretPlicIrqIdSpiDeviceTpmHeaderNotEmpty = 74, /**< spi_device_tpm_header_not_empty */
1061 kTopEgretPlicIrqIdSpiDeviceTpmRdfifoCmdEnd = 75, /**< spi_device_tpm_rdfifo_cmd_end */
1062 kTopEgretPlicIrqIdSpiDeviceTpmRdfifoDrop = 76, /**< spi_device_tpm_rdfifo_drop */
1063 kTopEgretPlicIrqIdI2c0FmtThreshold = 77, /**< i2c0_fmt_threshold */
1064 kTopEgretPlicIrqIdI2c0RxThreshold = 78, /**< i2c0_rx_threshold */
1065 kTopEgretPlicIrqIdI2c0AcqThreshold = 79, /**< i2c0_acq_threshold */
1066 kTopEgretPlicIrqIdI2c0RxOverflow = 80, /**< i2c0_rx_overflow */
1067 kTopEgretPlicIrqIdI2c0ControllerHalt = 81, /**< i2c0_controller_halt */
1068 kTopEgretPlicIrqIdI2c0SclInterference = 82, /**< i2c0_scl_interference */
1069 kTopEgretPlicIrqIdI2c0SdaInterference = 83, /**< i2c0_sda_interference */
1070 kTopEgretPlicIrqIdI2c0StretchTimeout = 84, /**< i2c0_stretch_timeout */
1071 kTopEgretPlicIrqIdI2c0SdaUnstable = 85, /**< i2c0_sda_unstable */
1072 kTopEgretPlicIrqIdI2c0CmdComplete = 86, /**< i2c0_cmd_complete */
1073 kTopEgretPlicIrqIdI2c0TxStretch = 87, /**< i2c0_tx_stretch */
1074 kTopEgretPlicIrqIdI2c0TxThreshold = 88, /**< i2c0_tx_threshold */
1075 kTopEgretPlicIrqIdI2c0AcqStretch = 89, /**< i2c0_acq_stretch */
1076 kTopEgretPlicIrqIdI2c0UnexpStop = 90, /**< i2c0_unexp_stop */
1077 kTopEgretPlicIrqIdI2c0HostTimeout = 91, /**< i2c0_host_timeout */
1078 kTopEgretPlicIrqIdI2c1FmtThreshold = 92, /**< i2c1_fmt_threshold */
1079 kTopEgretPlicIrqIdI2c1RxThreshold = 93, /**< i2c1_rx_threshold */
1080 kTopEgretPlicIrqIdI2c1AcqThreshold = 94, /**< i2c1_acq_threshold */
1081 kTopEgretPlicIrqIdI2c1RxOverflow = 95, /**< i2c1_rx_overflow */
1082 kTopEgretPlicIrqIdI2c1ControllerHalt = 96, /**< i2c1_controller_halt */
1083 kTopEgretPlicIrqIdI2c1SclInterference = 97, /**< i2c1_scl_interference */
1084 kTopEgretPlicIrqIdI2c1SdaInterference = 98, /**< i2c1_sda_interference */
1085 kTopEgretPlicIrqIdI2c1StretchTimeout = 99, /**< i2c1_stretch_timeout */
1086 kTopEgretPlicIrqIdI2c1SdaUnstable = 100, /**< i2c1_sda_unstable */
1087 kTopEgretPlicIrqIdI2c1CmdComplete = 101, /**< i2c1_cmd_complete */
1088 kTopEgretPlicIrqIdI2c1TxStretch = 102, /**< i2c1_tx_stretch */
1089 kTopEgretPlicIrqIdI2c1TxThreshold = 103, /**< i2c1_tx_threshold */
1090 kTopEgretPlicIrqIdI2c1AcqStretch = 104, /**< i2c1_acq_stretch */
1091 kTopEgretPlicIrqIdI2c1UnexpStop = 105, /**< i2c1_unexp_stop */
1092 kTopEgretPlicIrqIdI2c1HostTimeout = 106, /**< i2c1_host_timeout */
1093 kTopEgretPlicIrqIdI2c2FmtThreshold = 107, /**< i2c2_fmt_threshold */
1094 kTopEgretPlicIrqIdI2c2RxThreshold = 108, /**< i2c2_rx_threshold */
1095 kTopEgretPlicIrqIdI2c2AcqThreshold = 109, /**< i2c2_acq_threshold */
1096 kTopEgretPlicIrqIdI2c2RxOverflow = 110, /**< i2c2_rx_overflow */
1097 kTopEgretPlicIrqIdI2c2ControllerHalt = 111, /**< i2c2_controller_halt */
1098 kTopEgretPlicIrqIdI2c2SclInterference = 112, /**< i2c2_scl_interference */
1099 kTopEgretPlicIrqIdI2c2SdaInterference = 113, /**< i2c2_sda_interference */
1100 kTopEgretPlicIrqIdI2c2StretchTimeout = 114, /**< i2c2_stretch_timeout */
1101 kTopEgretPlicIrqIdI2c2SdaUnstable = 115, /**< i2c2_sda_unstable */
1102 kTopEgretPlicIrqIdI2c2CmdComplete = 116, /**< i2c2_cmd_complete */
1103 kTopEgretPlicIrqIdI2c2TxStretch = 117, /**< i2c2_tx_stretch */
1104 kTopEgretPlicIrqIdI2c2TxThreshold = 118, /**< i2c2_tx_threshold */
1105 kTopEgretPlicIrqIdI2c2AcqStretch = 119, /**< i2c2_acq_stretch */
1106 kTopEgretPlicIrqIdI2c2UnexpStop = 120, /**< i2c2_unexp_stop */
1107 kTopEgretPlicIrqIdI2c2HostTimeout = 121, /**< i2c2_host_timeout */
1108 kTopEgretPlicIrqIdPattgenDoneCh0 = 122, /**< pattgen_done_ch0 */
1109 kTopEgretPlicIrqIdPattgenDoneCh1 = 123, /**< pattgen_done_ch1 */
1110 kTopEgretPlicIrqIdRvTimerTimerExpiredHart0Timer0 = 124, /**< rv_timer_timer_expired_hart0_timer0 */
1111 kTopEgretPlicIrqIdOtpCtrlOtpOperationDone = 125, /**< otp_ctrl_otp_operation_done */
1112 kTopEgretPlicIrqIdOtpCtrlOtpError = 126, /**< otp_ctrl_otp_error */
1113 kTopEgretPlicIrqIdAlertHandlerClassa = 127, /**< alert_handler_classa */
1114 kTopEgretPlicIrqIdAlertHandlerClassb = 128, /**< alert_handler_classb */
1115 kTopEgretPlicIrqIdAlertHandlerClassc = 129, /**< alert_handler_classc */
1116 kTopEgretPlicIrqIdAlertHandlerClassd = 130, /**< alert_handler_classd */
1117 kTopEgretPlicIrqIdSpiHost0Error = 131, /**< spi_host0_error */
1118 kTopEgretPlicIrqIdSpiHost0SpiEvent = 132, /**< spi_host0_spi_event */
1119 kTopEgretPlicIrqIdSpiHost1Error = 133, /**< spi_host1_error */
1120 kTopEgretPlicIrqIdSpiHost1SpiEvent = 134, /**< spi_host1_spi_event */
1121 kTopEgretPlicIrqIdUsbdevPktReceived = 135, /**< usbdev_pkt_received */
1122 kTopEgretPlicIrqIdUsbdevPktSent = 136, /**< usbdev_pkt_sent */
1123 kTopEgretPlicIrqIdUsbdevDisconnected = 137, /**< usbdev_disconnected */
1124 kTopEgretPlicIrqIdUsbdevHostLost = 138, /**< usbdev_host_lost */
1125 kTopEgretPlicIrqIdUsbdevLinkReset = 139, /**< usbdev_link_reset */
1126 kTopEgretPlicIrqIdUsbdevLinkSuspend = 140, /**< usbdev_link_suspend */
1127 kTopEgretPlicIrqIdUsbdevLinkResume = 141, /**< usbdev_link_resume */
1128 kTopEgretPlicIrqIdUsbdevAvOutEmpty = 142, /**< usbdev_av_out_empty */
1129 kTopEgretPlicIrqIdUsbdevRxFull = 143, /**< usbdev_rx_full */
1130 kTopEgretPlicIrqIdUsbdevAvOverflow = 144, /**< usbdev_av_overflow */
1131 kTopEgretPlicIrqIdUsbdevLinkInErr = 145, /**< usbdev_link_in_err */
1132 kTopEgretPlicIrqIdUsbdevRxCrcErr = 146, /**< usbdev_rx_crc_err */
1133 kTopEgretPlicIrqIdUsbdevRxPidErr = 147, /**< usbdev_rx_pid_err */
1134 kTopEgretPlicIrqIdUsbdevRxBitstuffErr = 148, /**< usbdev_rx_bitstuff_err */
1135 kTopEgretPlicIrqIdUsbdevFrame = 149, /**< usbdev_frame */
1136 kTopEgretPlicIrqIdUsbdevPowered = 150, /**< usbdev_powered */
1137 kTopEgretPlicIrqIdUsbdevLinkOutErr = 151, /**< usbdev_link_out_err */
1138 kTopEgretPlicIrqIdUsbdevAvSetupEmpty = 152, /**< usbdev_av_setup_empty */
1139 kTopEgretPlicIrqIdPwrmgrAonWakeup = 153, /**< pwrmgr_aon_wakeup */
1140 kTopEgretPlicIrqIdSysrstCtrlAonEventDetected = 154, /**< sysrst_ctrl_aon_event_detected */
1141 kTopEgretPlicIrqIdAdcCtrlAonMatchPending = 155, /**< adc_ctrl_aon_match_pending */
1142 kTopEgretPlicIrqIdAonTimerAonWkupTimerExpired = 156, /**< aon_timer_aon_wkup_timer_expired */
1143 kTopEgretPlicIrqIdAonTimerAonWdogTimerBark = 157, /**< aon_timer_aon_wdog_timer_bark */
1144 kTopEgretPlicIrqIdSensorCtrlAonIoStatusChange = 158, /**< sensor_ctrl_aon_io_status_change */
1145 kTopEgretPlicIrqIdSensorCtrlAonInitStatusChange = 159, /**< sensor_ctrl_aon_init_status_change */
1146 kTopEgretPlicIrqIdFlashCtrlProgEmpty = 160, /**< flash_ctrl_prog_empty */
1147 kTopEgretPlicIrqIdFlashCtrlProgLvl = 161, /**< flash_ctrl_prog_lvl */
1148 kTopEgretPlicIrqIdFlashCtrlRdFull = 162, /**< flash_ctrl_rd_full */
1149 kTopEgretPlicIrqIdFlashCtrlRdLvl = 163, /**< flash_ctrl_rd_lvl */
1150 kTopEgretPlicIrqIdFlashCtrlOpDone = 164, /**< flash_ctrl_op_done */
1151 kTopEgretPlicIrqIdFlashCtrlCorrErr = 165, /**< flash_ctrl_corr_err */
1152 kTopEgretPlicIrqIdAccDone = 166, /**< acc_done */
1153 kTopEgretPlicIrqIdHmacHmacDone = 167, /**< hmac_hmac_done */
1154 kTopEgretPlicIrqIdHmacFifoEmpty = 168, /**< hmac_fifo_empty */
1155 kTopEgretPlicIrqIdHmacHmacErr = 169, /**< hmac_hmac_err */
1156 kTopEgretPlicIrqIdKmacKmacDone = 170, /**< kmac_kmac_done */
1157 kTopEgretPlicIrqIdKmacFifoEmpty = 171, /**< kmac_fifo_empty */
1158 kTopEgretPlicIrqIdKmacKmacErr = 172, /**< kmac_kmac_err */
1159 kTopEgretPlicIrqIdKeymgrOpDone = 173, /**< keymgr_op_done */
1160 kTopEgretPlicIrqIdCsrngCsCmdReqDone = 174, /**< csrng_cs_cmd_req_done */
1161 kTopEgretPlicIrqIdCsrngCsEntropyReq = 175, /**< csrng_cs_entropy_req */
1162 kTopEgretPlicIrqIdCsrngCsHwInstExc = 176, /**< csrng_cs_hw_inst_exc */
1163 kTopEgretPlicIrqIdCsrngCsFatalErr = 177, /**< csrng_cs_fatal_err */
1164 kTopEgretPlicIrqIdEntropySrcEsEntropyValid = 178, /**< entropy_src_es_entropy_valid */
1165 kTopEgretPlicIrqIdEntropySrcEsHealthTestFailed = 179, /**< entropy_src_es_health_test_failed */
1166 kTopEgretPlicIrqIdEntropySrcEsObserveFifoReady = 180, /**< entropy_src_es_observe_fifo_ready */
1167 kTopEgretPlicIrqIdEntropySrcEsFatalErr = 181, /**< entropy_src_es_fatal_err */
1168 kTopEgretPlicIrqIdEdn0EdnCmdReqDone = 182, /**< edn0_edn_cmd_req_done */
1169 kTopEgretPlicIrqIdEdn0EdnFatalErr = 183, /**< edn0_edn_fatal_err */
1170 kTopEgretPlicIrqIdEdn1EdnCmdReqDone = 184, /**< edn1_edn_cmd_req_done */
1171 kTopEgretPlicIrqIdEdn1EdnFatalErr = 185, /**< edn1_edn_fatal_err */
1172 kTopEgretPlicIrqIdLast = 185, /**< \internal The Last Valid Interrupt ID. */
1174
1175/**
1176 * PLIC Interrupt Source to Peripheral Map
1177 *
1178 * This array is a mapping from `top_egret_plic_irq_id_t` to
1179 * `top_egret_plic_peripheral_t`.
1180 */
1181extern const top_egret_plic_peripheral_t
1182 top_egret_plic_interrupt_for_peripheral[186];
1183
1184/**
1185 * PLIC Interrupt Target.
1186 *
1187 * Enumeration used to determine which set of IE, CC, threshold registers to
1188 * access for a given interrupt target.
1189 */
1191 kTopEgretPlicTargetIbex0 = 0, /**< Ibex Core 0 */
1192 kTopEgretPlicTargetLast = 0, /**< \internal Final PLIC target */
1194
1195
1196/**
1197 * Alert Handler Source Peripheral.
1198 *
1199 * Enumeration used to determine which peripheral asserted the corresponding
1200 * alert.
1201 */
1203 kTopEgretAlertPeripheralExternal = 0, /**< External Peripheral */
1214 kTopEgretAlertPeripheralRvTimer = 11, /**< rv_timer */
1215 kTopEgretAlertPeripheralOtpCtrl = 12, /**< otp_ctrl */
1217 kTopEgretAlertPeripheralSpiHost0 = 14, /**< spi_host0 */
1218 kTopEgretAlertPeripheralSpiHost1 = 15, /**< spi_host1 */
1220 kTopEgretAlertPeripheralPwrmgrAon = 17, /**< pwrmgr_aon */
1221 kTopEgretAlertPeripheralRstmgrAon = 18, /**< rstmgr_aon */
1222 kTopEgretAlertPeripheralClkmgrAon = 19, /**< clkmgr_aon */
1223 kTopEgretAlertPeripheralSysrstCtrlAon = 20, /**< sysrst_ctrl_aon */
1224 kTopEgretAlertPeripheralAdcCtrlAon = 21, /**< adc_ctrl_aon */
1226 kTopEgretAlertPeripheralPinmuxAon = 23, /**< pinmux_aon */
1227 kTopEgretAlertPeripheralAonTimerAon = 24, /**< aon_timer_aon */
1228 kTopEgretAlertPeripheralSensorCtrlAon = 25, /**< sensor_ctrl_aon */
1229 kTopEgretAlertPeripheralSramCtrlRetAon = 26, /**< sram_ctrl_ret_aon */
1230 kTopEgretAlertPeripheralFlashCtrl = 27, /**< flash_ctrl */
1239 kTopEgretAlertPeripheralEntropySrc = 36, /**< entropy_src */
1242 kTopEgretAlertPeripheralSramCtrlMain = 39, /**< sram_ctrl_main */
1243 kTopEgretAlertPeripheralRomCtrl = 40, /**< rom_ctrl */
1244 kTopEgretAlertPeripheralRvCoreIbex = 41, /**< rv_core_ibex */
1245 kTopEgretAlertPeripheralLast = 41, /**< \internal Final Alert peripheral */
1247
1248/**
1249 * Alert Handler Alert Source.
1250 *
1251 * Enumeration of all Alert Handler Alert Sources. The alert sources belonging to
1252 * the same peripheral are guaranteed to be consecutive.
1253 */
1255 kTopEgretAlertIdUart0FatalFault = 0, /**< uart0_fatal_fault */
1256 kTopEgretAlertIdUart1FatalFault = 1, /**< uart1_fatal_fault */
1257 kTopEgretAlertIdUart2FatalFault = 2, /**< uart2_fatal_fault */
1258 kTopEgretAlertIdUart3FatalFault = 3, /**< uart3_fatal_fault */
1259 kTopEgretAlertIdGpioFatalFault = 4, /**< gpio_fatal_fault */
1260 kTopEgretAlertIdSpiDeviceFatalFault = 5, /**< spi_device_fatal_fault */
1261 kTopEgretAlertIdI2c0FatalFault = 6, /**< i2c0_fatal_fault */
1262 kTopEgretAlertIdI2c1FatalFault = 7, /**< i2c1_fatal_fault */
1263 kTopEgretAlertIdI2c2FatalFault = 8, /**< i2c2_fatal_fault */
1264 kTopEgretAlertIdPattgenFatalFault = 9, /**< pattgen_fatal_fault */
1265 kTopEgretAlertIdRvTimerFatalFault = 10, /**< rv_timer_fatal_fault */
1266 kTopEgretAlertIdOtpCtrlFatalMacroError = 11, /**< otp_ctrl_fatal_macro_error */
1267 kTopEgretAlertIdOtpCtrlFatalCheckError = 12, /**< otp_ctrl_fatal_check_error */
1268 kTopEgretAlertIdOtpCtrlFatalBusIntegError = 13, /**< otp_ctrl_fatal_bus_integ_error */
1269 kTopEgretAlertIdOtpCtrlFatalPrimOtpAlert = 14, /**< otp_ctrl_fatal_prim_otp_alert */
1270 kTopEgretAlertIdOtpCtrlRecovPrimOtpAlert = 15, /**< otp_ctrl_recov_prim_otp_alert */
1271 kTopEgretAlertIdLcCtrlFatalProgError = 16, /**< lc_ctrl_fatal_prog_error */
1272 kTopEgretAlertIdLcCtrlFatalStateError = 17, /**< lc_ctrl_fatal_state_error */
1273 kTopEgretAlertIdLcCtrlFatalBusIntegError = 18, /**< lc_ctrl_fatal_bus_integ_error */
1274 kTopEgretAlertIdSpiHost0FatalFault = 19, /**< spi_host0_fatal_fault */
1275 kTopEgretAlertIdSpiHost1FatalFault = 20, /**< spi_host1_fatal_fault */
1276 kTopEgretAlertIdUsbdevFatalFault = 21, /**< usbdev_fatal_fault */
1277 kTopEgretAlertIdPwrmgrAonFatalFault = 22, /**< pwrmgr_aon_fatal_fault */
1278 kTopEgretAlertIdRstmgrAonFatalFault = 23, /**< rstmgr_aon_fatal_fault */
1279 kTopEgretAlertIdRstmgrAonFatalCnstyFault = 24, /**< rstmgr_aon_fatal_cnsty_fault */
1280 kTopEgretAlertIdClkmgrAonRecovFault = 25, /**< clkmgr_aon_recov_fault */
1281 kTopEgretAlertIdClkmgrAonFatalFault = 26, /**< clkmgr_aon_fatal_fault */
1282 kTopEgretAlertIdSysrstCtrlAonFatalFault = 27, /**< sysrst_ctrl_aon_fatal_fault */
1283 kTopEgretAlertIdAdcCtrlAonFatalFault = 28, /**< adc_ctrl_aon_fatal_fault */
1284 kTopEgretAlertIdPwmAonFatalFault = 29, /**< pwm_aon_fatal_fault */
1285 kTopEgretAlertIdPinmuxAonFatalFault = 30, /**< pinmux_aon_fatal_fault */
1286 kTopEgretAlertIdAonTimerAonFatalFault = 31, /**< aon_timer_aon_fatal_fault */
1287 kTopEgretAlertIdSensorCtrlAonRecovAlert = 32, /**< sensor_ctrl_aon_recov_alert */
1288 kTopEgretAlertIdSensorCtrlAonFatalAlert = 33, /**< sensor_ctrl_aon_fatal_alert */
1289 kTopEgretAlertIdSramCtrlRetAonFatalError = 34, /**< sram_ctrl_ret_aon_fatal_error */
1290 kTopEgretAlertIdFlashCtrlRecovErr = 35, /**< flash_ctrl_recov_err */
1291 kTopEgretAlertIdFlashCtrlFatalStdErr = 36, /**< flash_ctrl_fatal_std_err */
1292 kTopEgretAlertIdFlashCtrlFatalErr = 37, /**< flash_ctrl_fatal_err */
1293 kTopEgretAlertIdFlashCtrlFatalPrimFlashAlert = 38, /**< flash_ctrl_fatal_prim_flash_alert */
1294 kTopEgretAlertIdFlashCtrlRecovPrimFlashAlert = 39, /**< flash_ctrl_recov_prim_flash_alert */
1295 kTopEgretAlertIdRvDmFatalFault = 40, /**< rv_dm_fatal_fault */
1296 kTopEgretAlertIdRvPlicFatalFault = 41, /**< rv_plic_fatal_fault */
1297 kTopEgretAlertIdAccFatal = 42, /**< acc_fatal */
1298 kTopEgretAlertIdAccRecov = 43, /**< acc_recov */
1299 kTopEgretAlertIdAesRecovCtrlUpdateErr = 44, /**< aes_recov_ctrl_update_err */
1300 kTopEgretAlertIdAesFatalFault = 45, /**< aes_fatal_fault */
1301 kTopEgretAlertIdHmacFatalFault = 46, /**< hmac_fatal_fault */
1302 kTopEgretAlertIdKmacRecovOperationErr = 47, /**< kmac_recov_operation_err */
1303 kTopEgretAlertIdKmacFatalFaultErr = 48, /**< kmac_fatal_fault_err */
1304 kTopEgretAlertIdKeymgrRecovOperationErr = 49, /**< keymgr_recov_operation_err */
1305 kTopEgretAlertIdKeymgrFatalFaultErr = 50, /**< keymgr_fatal_fault_err */
1306 kTopEgretAlertIdCsrngRecovAlert = 51, /**< csrng_recov_alert */
1307 kTopEgretAlertIdCsrngFatalAlert = 52, /**< csrng_fatal_alert */
1308 kTopEgretAlertIdEntropySrcRecovAlert = 53, /**< entropy_src_recov_alert */
1309 kTopEgretAlertIdEntropySrcFatalAlert = 54, /**< entropy_src_fatal_alert */
1310 kTopEgretAlertIdEdn0RecovAlert = 55, /**< edn0_recov_alert */
1311 kTopEgretAlertIdEdn0FatalAlert = 56, /**< edn0_fatal_alert */
1312 kTopEgretAlertIdEdn1RecovAlert = 57, /**< edn1_recov_alert */
1313 kTopEgretAlertIdEdn1FatalAlert = 58, /**< edn1_fatal_alert */
1314 kTopEgretAlertIdSramCtrlMainFatalError = 59, /**< sram_ctrl_main_fatal_error */
1315 kTopEgretAlertIdRomCtrlFatal = 60, /**< rom_ctrl_fatal */
1316 kTopEgretAlertIdRvCoreIbexFatalSwErr = 61, /**< rv_core_ibex_fatal_sw_err */
1317 kTopEgretAlertIdRvCoreIbexRecovSwErr = 62, /**< rv_core_ibex_recov_sw_err */
1318 kTopEgretAlertIdRvCoreIbexFatalHwErr = 63, /**< rv_core_ibex_fatal_hw_err */
1319 kTopEgretAlertIdRvCoreIbexRecovHwErr = 64, /**< rv_core_ibex_recov_hw_err */
1320 kTopEgretAlertIdLast = 64, /**< \internal The Last Valid Alert ID. */
1322
1323/**
1324 * Alert Handler Alert Source to Peripheral Map
1325 *
1326 * This array is a mapping from `top_egret_alert_id_t` to
1327 * `top_egret_alert_peripheral_t`.
1328 */
1330 top_egret_alert_for_peripheral[65];
1331
1332#define PINMUX_MIO_PERIPH_INSEL_IDX_OFFSET 2
1333
1334// PERIPH_INSEL ranges from 0 to NUM_MIO_PADS + 2 -1}
1335// 0 and 1 are tied to value 0 and 1
1336#define NUM_MIO_PADS 47
1337#define NUM_DIO_PADS 16
1338
1339#define PINMUX_PERIPH_OUTSEL_IDX_OFFSET 3
1340
1341/**
1342 * Pinmux Peripheral Input.
1343 */
1345 kTopEgretPinmuxPeripheralInGpioGpio0 = 0, /**< Peripheral Input 0 */
1346 kTopEgretPinmuxPeripheralInGpioGpio1 = 1, /**< Peripheral Input 1 */
1347 kTopEgretPinmuxPeripheralInGpioGpio2 = 2, /**< Peripheral Input 2 */
1348 kTopEgretPinmuxPeripheralInGpioGpio3 = 3, /**< Peripheral Input 3 */
1349 kTopEgretPinmuxPeripheralInGpioGpio4 = 4, /**< Peripheral Input 4 */
1350 kTopEgretPinmuxPeripheralInGpioGpio5 = 5, /**< Peripheral Input 5 */
1351 kTopEgretPinmuxPeripheralInGpioGpio6 = 6, /**< Peripheral Input 6 */
1352 kTopEgretPinmuxPeripheralInGpioGpio7 = 7, /**< Peripheral Input 7 */
1353 kTopEgretPinmuxPeripheralInGpioGpio8 = 8, /**< Peripheral Input 8 */
1354 kTopEgretPinmuxPeripheralInGpioGpio9 = 9, /**< Peripheral Input 9 */
1355 kTopEgretPinmuxPeripheralInGpioGpio10 = 10, /**< Peripheral Input 10 */
1356 kTopEgretPinmuxPeripheralInGpioGpio11 = 11, /**< Peripheral Input 11 */
1357 kTopEgretPinmuxPeripheralInGpioGpio12 = 12, /**< Peripheral Input 12 */
1358 kTopEgretPinmuxPeripheralInGpioGpio13 = 13, /**< Peripheral Input 13 */
1359 kTopEgretPinmuxPeripheralInGpioGpio14 = 14, /**< Peripheral Input 14 */
1360 kTopEgretPinmuxPeripheralInGpioGpio15 = 15, /**< Peripheral Input 15 */
1361 kTopEgretPinmuxPeripheralInGpioGpio16 = 16, /**< Peripheral Input 16 */
1362 kTopEgretPinmuxPeripheralInGpioGpio17 = 17, /**< Peripheral Input 17 */
1363 kTopEgretPinmuxPeripheralInGpioGpio18 = 18, /**< Peripheral Input 18 */
1364 kTopEgretPinmuxPeripheralInGpioGpio19 = 19, /**< Peripheral Input 19 */
1365 kTopEgretPinmuxPeripheralInGpioGpio20 = 20, /**< Peripheral Input 20 */
1366 kTopEgretPinmuxPeripheralInGpioGpio21 = 21, /**< Peripheral Input 21 */
1367 kTopEgretPinmuxPeripheralInGpioGpio22 = 22, /**< Peripheral Input 22 */
1368 kTopEgretPinmuxPeripheralInGpioGpio23 = 23, /**< Peripheral Input 23 */
1369 kTopEgretPinmuxPeripheralInGpioGpio24 = 24, /**< Peripheral Input 24 */
1370 kTopEgretPinmuxPeripheralInGpioGpio25 = 25, /**< Peripheral Input 25 */
1371 kTopEgretPinmuxPeripheralInGpioGpio26 = 26, /**< Peripheral Input 26 */
1372 kTopEgretPinmuxPeripheralInGpioGpio27 = 27, /**< Peripheral Input 27 */
1373 kTopEgretPinmuxPeripheralInGpioGpio28 = 28, /**< Peripheral Input 28 */
1374 kTopEgretPinmuxPeripheralInGpioGpio29 = 29, /**< Peripheral Input 29 */
1375 kTopEgretPinmuxPeripheralInGpioGpio30 = 30, /**< Peripheral Input 30 */
1376 kTopEgretPinmuxPeripheralInGpioGpio31 = 31, /**< Peripheral Input 31 */
1377 kTopEgretPinmuxPeripheralInI2c0Sda = 32, /**< Peripheral Input 32 */
1378 kTopEgretPinmuxPeripheralInI2c0Scl = 33, /**< Peripheral Input 33 */
1379 kTopEgretPinmuxPeripheralInI2c1Sda = 34, /**< Peripheral Input 34 */
1380 kTopEgretPinmuxPeripheralInI2c1Scl = 35, /**< Peripheral Input 35 */
1381 kTopEgretPinmuxPeripheralInI2c2Sda = 36, /**< Peripheral Input 36 */
1382 kTopEgretPinmuxPeripheralInI2c2Scl = 37, /**< Peripheral Input 37 */
1383 kTopEgretPinmuxPeripheralInSpiHost1Sd0 = 38, /**< Peripheral Input 38 */
1384 kTopEgretPinmuxPeripheralInSpiHost1Sd1 = 39, /**< Peripheral Input 39 */
1385 kTopEgretPinmuxPeripheralInSpiHost1Sd2 = 40, /**< Peripheral Input 40 */
1386 kTopEgretPinmuxPeripheralInSpiHost1Sd3 = 41, /**< Peripheral Input 41 */
1387 kTopEgretPinmuxPeripheralInUart0Rx = 42, /**< Peripheral Input 42 */
1388 kTopEgretPinmuxPeripheralInUart1Rx = 43, /**< Peripheral Input 43 */
1389 kTopEgretPinmuxPeripheralInUart2Rx = 44, /**< Peripheral Input 44 */
1390 kTopEgretPinmuxPeripheralInUart3Rx = 45, /**< Peripheral Input 45 */
1391 kTopEgretPinmuxPeripheralInSpiDeviceTpmCsb = 46, /**< Peripheral Input 46 */
1392 kTopEgretPinmuxPeripheralInFlashMacroWrapperTck = 47, /**< Peripheral Input 47 */
1393 kTopEgretPinmuxPeripheralInFlashMacroWrapperTms = 48, /**< Peripheral Input 48 */
1394 kTopEgretPinmuxPeripheralInFlashMacroWrapperTdi = 49, /**< Peripheral Input 49 */
1396 kTopEgretPinmuxPeripheralInSysrstCtrlAonKey0In = 51, /**< Peripheral Input 51 */
1397 kTopEgretPinmuxPeripheralInSysrstCtrlAonKey1In = 52, /**< Peripheral Input 52 */
1398 kTopEgretPinmuxPeripheralInSysrstCtrlAonKey2In = 53, /**< Peripheral Input 53 */
1399 kTopEgretPinmuxPeripheralInSysrstCtrlAonPwrbIn = 54, /**< Peripheral Input 54 */
1400 kTopEgretPinmuxPeripheralInSysrstCtrlAonLidOpen = 55, /**< Peripheral Input 55 */
1401 kTopEgretPinmuxPeripheralInUsbdevSense = 56, /**< Peripheral Input 56 */
1402 kTopEgretPinmuxPeripheralInLast = 56, /**< \internal Last valid peripheral input */
1404
1405/**
1406 * Pinmux MIO Input Selector.
1407 */
1409 kTopEgretPinmuxInselConstantZero = 0, /**< Tie constantly to zero */
1410 kTopEgretPinmuxInselConstantOne = 1, /**< Tie constantly to one */
1411 kTopEgretPinmuxInselIoa0 = 2, /**< MIO Pad 0 */
1412 kTopEgretPinmuxInselIoa1 = 3, /**< MIO Pad 1 */
1413 kTopEgretPinmuxInselIoa2 = 4, /**< MIO Pad 2 */
1414 kTopEgretPinmuxInselIoa3 = 5, /**< MIO Pad 3 */
1415 kTopEgretPinmuxInselIoa4 = 6, /**< MIO Pad 4 */
1416 kTopEgretPinmuxInselIoa5 = 7, /**< MIO Pad 5 */
1417 kTopEgretPinmuxInselIoa6 = 8, /**< MIO Pad 6 */
1418 kTopEgretPinmuxInselIoa7 = 9, /**< MIO Pad 7 */
1419 kTopEgretPinmuxInselIoa8 = 10, /**< MIO Pad 8 */
1420 kTopEgretPinmuxInselIob0 = 11, /**< MIO Pad 9 */
1421 kTopEgretPinmuxInselIob1 = 12, /**< MIO Pad 10 */
1422 kTopEgretPinmuxInselIob2 = 13, /**< MIO Pad 11 */
1423 kTopEgretPinmuxInselIob3 = 14, /**< MIO Pad 12 */
1424 kTopEgretPinmuxInselIob4 = 15, /**< MIO Pad 13 */
1425 kTopEgretPinmuxInselIob5 = 16, /**< MIO Pad 14 */
1426 kTopEgretPinmuxInselIob6 = 17, /**< MIO Pad 15 */
1427 kTopEgretPinmuxInselIob7 = 18, /**< MIO Pad 16 */
1428 kTopEgretPinmuxInselIob8 = 19, /**< MIO Pad 17 */
1429 kTopEgretPinmuxInselIob9 = 20, /**< MIO Pad 18 */
1430 kTopEgretPinmuxInselIob10 = 21, /**< MIO Pad 19 */
1431 kTopEgretPinmuxInselIob11 = 22, /**< MIO Pad 20 */
1432 kTopEgretPinmuxInselIob12 = 23, /**< MIO Pad 21 */
1433 kTopEgretPinmuxInselIoc0 = 24, /**< MIO Pad 22 */
1434 kTopEgretPinmuxInselIoc1 = 25, /**< MIO Pad 23 */
1435 kTopEgretPinmuxInselIoc2 = 26, /**< MIO Pad 24 */
1436 kTopEgretPinmuxInselIoc3 = 27, /**< MIO Pad 25 */
1437 kTopEgretPinmuxInselIoc4 = 28, /**< MIO Pad 26 */
1438 kTopEgretPinmuxInselIoc5 = 29, /**< MIO Pad 27 */
1439 kTopEgretPinmuxInselIoc6 = 30, /**< MIO Pad 28 */
1440 kTopEgretPinmuxInselIoc7 = 31, /**< MIO Pad 29 */
1441 kTopEgretPinmuxInselIoc8 = 32, /**< MIO Pad 30 */
1442 kTopEgretPinmuxInselIoc9 = 33, /**< MIO Pad 31 */
1443 kTopEgretPinmuxInselIoc10 = 34, /**< MIO Pad 32 */
1444 kTopEgretPinmuxInselIoc11 = 35, /**< MIO Pad 33 */
1445 kTopEgretPinmuxInselIoc12 = 36, /**< MIO Pad 34 */
1446 kTopEgretPinmuxInselIor0 = 37, /**< MIO Pad 35 */
1447 kTopEgretPinmuxInselIor1 = 38, /**< MIO Pad 36 */
1448 kTopEgretPinmuxInselIor2 = 39, /**< MIO Pad 37 */
1449 kTopEgretPinmuxInselIor3 = 40, /**< MIO Pad 38 */
1450 kTopEgretPinmuxInselIor4 = 41, /**< MIO Pad 39 */
1451 kTopEgretPinmuxInselIor5 = 42, /**< MIO Pad 40 */
1452 kTopEgretPinmuxInselIor6 = 43, /**< MIO Pad 41 */
1453 kTopEgretPinmuxInselIor7 = 44, /**< MIO Pad 42 */
1454 kTopEgretPinmuxInselIor10 = 45, /**< MIO Pad 43 */
1455 kTopEgretPinmuxInselIor11 = 46, /**< MIO Pad 44 */
1456 kTopEgretPinmuxInselIor12 = 47, /**< MIO Pad 45 */
1457 kTopEgretPinmuxInselIor13 = 48, /**< MIO Pad 46 */
1458 kTopEgretPinmuxInselLast = 48, /**< \internal Last valid insel value */
1460
1461/**
1462 * Pinmux MIO Output.
1463 */
1465 kTopEgretPinmuxMioOutIoa0 = 0, /**< MIO Pad 0 */
1466 kTopEgretPinmuxMioOutIoa1 = 1, /**< MIO Pad 1 */
1467 kTopEgretPinmuxMioOutIoa2 = 2, /**< MIO Pad 2 */
1468 kTopEgretPinmuxMioOutIoa3 = 3, /**< MIO Pad 3 */
1469 kTopEgretPinmuxMioOutIoa4 = 4, /**< MIO Pad 4 */
1470 kTopEgretPinmuxMioOutIoa5 = 5, /**< MIO Pad 5 */
1471 kTopEgretPinmuxMioOutIoa6 = 6, /**< MIO Pad 6 */
1472 kTopEgretPinmuxMioOutIoa7 = 7, /**< MIO Pad 7 */
1473 kTopEgretPinmuxMioOutIoa8 = 8, /**< MIO Pad 8 */
1474 kTopEgretPinmuxMioOutIob0 = 9, /**< MIO Pad 9 */
1475 kTopEgretPinmuxMioOutIob1 = 10, /**< MIO Pad 10 */
1476 kTopEgretPinmuxMioOutIob2 = 11, /**< MIO Pad 11 */
1477 kTopEgretPinmuxMioOutIob3 = 12, /**< MIO Pad 12 */
1478 kTopEgretPinmuxMioOutIob4 = 13, /**< MIO Pad 13 */
1479 kTopEgretPinmuxMioOutIob5 = 14, /**< MIO Pad 14 */
1480 kTopEgretPinmuxMioOutIob6 = 15, /**< MIO Pad 15 */
1481 kTopEgretPinmuxMioOutIob7 = 16, /**< MIO Pad 16 */
1482 kTopEgretPinmuxMioOutIob8 = 17, /**< MIO Pad 17 */
1483 kTopEgretPinmuxMioOutIob9 = 18, /**< MIO Pad 18 */
1484 kTopEgretPinmuxMioOutIob10 = 19, /**< MIO Pad 19 */
1485 kTopEgretPinmuxMioOutIob11 = 20, /**< MIO Pad 20 */
1486 kTopEgretPinmuxMioOutIob12 = 21, /**< MIO Pad 21 */
1487 kTopEgretPinmuxMioOutIoc0 = 22, /**< MIO Pad 22 */
1488 kTopEgretPinmuxMioOutIoc1 = 23, /**< MIO Pad 23 */
1489 kTopEgretPinmuxMioOutIoc2 = 24, /**< MIO Pad 24 */
1490 kTopEgretPinmuxMioOutIoc3 = 25, /**< MIO Pad 25 */
1491 kTopEgretPinmuxMioOutIoc4 = 26, /**< MIO Pad 26 */
1492 kTopEgretPinmuxMioOutIoc5 = 27, /**< MIO Pad 27 */
1493 kTopEgretPinmuxMioOutIoc6 = 28, /**< MIO Pad 28 */
1494 kTopEgretPinmuxMioOutIoc7 = 29, /**< MIO Pad 29 */
1495 kTopEgretPinmuxMioOutIoc8 = 30, /**< MIO Pad 30 */
1496 kTopEgretPinmuxMioOutIoc9 = 31, /**< MIO Pad 31 */
1497 kTopEgretPinmuxMioOutIoc10 = 32, /**< MIO Pad 32 */
1498 kTopEgretPinmuxMioOutIoc11 = 33, /**< MIO Pad 33 */
1499 kTopEgretPinmuxMioOutIoc12 = 34, /**< MIO Pad 34 */
1500 kTopEgretPinmuxMioOutIor0 = 35, /**< MIO Pad 35 */
1501 kTopEgretPinmuxMioOutIor1 = 36, /**< MIO Pad 36 */
1502 kTopEgretPinmuxMioOutIor2 = 37, /**< MIO Pad 37 */
1503 kTopEgretPinmuxMioOutIor3 = 38, /**< MIO Pad 38 */
1504 kTopEgretPinmuxMioOutIor4 = 39, /**< MIO Pad 39 */
1505 kTopEgretPinmuxMioOutIor5 = 40, /**< MIO Pad 40 */
1506 kTopEgretPinmuxMioOutIor6 = 41, /**< MIO Pad 41 */
1507 kTopEgretPinmuxMioOutIor7 = 42, /**< MIO Pad 42 */
1508 kTopEgretPinmuxMioOutIor10 = 43, /**< MIO Pad 43 */
1509 kTopEgretPinmuxMioOutIor11 = 44, /**< MIO Pad 44 */
1510 kTopEgretPinmuxMioOutIor12 = 45, /**< MIO Pad 45 */
1511 kTopEgretPinmuxMioOutIor13 = 46, /**< MIO Pad 46 */
1512 kTopEgretPinmuxMioOutLast = 46, /**< \internal Last valid mio output */
1514
1515/**
1516 * Pinmux Peripheral Output Selector.
1517 */
1519 kTopEgretPinmuxOutselConstantZero = 0, /**< Tie constantly to zero */
1520 kTopEgretPinmuxOutselConstantOne = 1, /**< Tie constantly to one */
1521 kTopEgretPinmuxOutselConstantHighZ = 2, /**< Tie constantly to high-Z */
1522 kTopEgretPinmuxOutselGpioGpio0 = 3, /**< Peripheral Output 0 */
1523 kTopEgretPinmuxOutselGpioGpio1 = 4, /**< Peripheral Output 1 */
1524 kTopEgretPinmuxOutselGpioGpio2 = 5, /**< Peripheral Output 2 */
1525 kTopEgretPinmuxOutselGpioGpio3 = 6, /**< Peripheral Output 3 */
1526 kTopEgretPinmuxOutselGpioGpio4 = 7, /**< Peripheral Output 4 */
1527 kTopEgretPinmuxOutselGpioGpio5 = 8, /**< Peripheral Output 5 */
1528 kTopEgretPinmuxOutselGpioGpio6 = 9, /**< Peripheral Output 6 */
1529 kTopEgretPinmuxOutselGpioGpio7 = 10, /**< Peripheral Output 7 */
1530 kTopEgretPinmuxOutselGpioGpio8 = 11, /**< Peripheral Output 8 */
1531 kTopEgretPinmuxOutselGpioGpio9 = 12, /**< Peripheral Output 9 */
1532 kTopEgretPinmuxOutselGpioGpio10 = 13, /**< Peripheral Output 10 */
1533 kTopEgretPinmuxOutselGpioGpio11 = 14, /**< Peripheral Output 11 */
1534 kTopEgretPinmuxOutselGpioGpio12 = 15, /**< Peripheral Output 12 */
1535 kTopEgretPinmuxOutselGpioGpio13 = 16, /**< Peripheral Output 13 */
1536 kTopEgretPinmuxOutselGpioGpio14 = 17, /**< Peripheral Output 14 */
1537 kTopEgretPinmuxOutselGpioGpio15 = 18, /**< Peripheral Output 15 */
1538 kTopEgretPinmuxOutselGpioGpio16 = 19, /**< Peripheral Output 16 */
1539 kTopEgretPinmuxOutselGpioGpio17 = 20, /**< Peripheral Output 17 */
1540 kTopEgretPinmuxOutselGpioGpio18 = 21, /**< Peripheral Output 18 */
1541 kTopEgretPinmuxOutselGpioGpio19 = 22, /**< Peripheral Output 19 */
1542 kTopEgretPinmuxOutselGpioGpio20 = 23, /**< Peripheral Output 20 */
1543 kTopEgretPinmuxOutselGpioGpio21 = 24, /**< Peripheral Output 21 */
1544 kTopEgretPinmuxOutselGpioGpio22 = 25, /**< Peripheral Output 22 */
1545 kTopEgretPinmuxOutselGpioGpio23 = 26, /**< Peripheral Output 23 */
1546 kTopEgretPinmuxOutselGpioGpio24 = 27, /**< Peripheral Output 24 */
1547 kTopEgretPinmuxOutselGpioGpio25 = 28, /**< Peripheral Output 25 */
1548 kTopEgretPinmuxOutselGpioGpio26 = 29, /**< Peripheral Output 26 */
1549 kTopEgretPinmuxOutselGpioGpio27 = 30, /**< Peripheral Output 27 */
1550 kTopEgretPinmuxOutselGpioGpio28 = 31, /**< Peripheral Output 28 */
1551 kTopEgretPinmuxOutselGpioGpio29 = 32, /**< Peripheral Output 29 */
1552 kTopEgretPinmuxOutselGpioGpio30 = 33, /**< Peripheral Output 30 */
1553 kTopEgretPinmuxOutselGpioGpio31 = 34, /**< Peripheral Output 31 */
1554 kTopEgretPinmuxOutselI2c0Sda = 35, /**< Peripheral Output 32 */
1555 kTopEgretPinmuxOutselI2c0Scl = 36, /**< Peripheral Output 33 */
1556 kTopEgretPinmuxOutselI2c1Sda = 37, /**< Peripheral Output 34 */
1557 kTopEgretPinmuxOutselI2c1Scl = 38, /**< Peripheral Output 35 */
1558 kTopEgretPinmuxOutselI2c2Sda = 39, /**< Peripheral Output 36 */
1559 kTopEgretPinmuxOutselI2c2Scl = 40, /**< Peripheral Output 37 */
1560 kTopEgretPinmuxOutselSpiHost1Sd0 = 41, /**< Peripheral Output 38 */
1561 kTopEgretPinmuxOutselSpiHost1Sd1 = 42, /**< Peripheral Output 39 */
1562 kTopEgretPinmuxOutselSpiHost1Sd2 = 43, /**< Peripheral Output 40 */
1563 kTopEgretPinmuxOutselSpiHost1Sd3 = 44, /**< Peripheral Output 41 */
1564 kTopEgretPinmuxOutselUart0Tx = 45, /**< Peripheral Output 42 */
1565 kTopEgretPinmuxOutselUart1Tx = 46, /**< Peripheral Output 43 */
1566 kTopEgretPinmuxOutselUart2Tx = 47, /**< Peripheral Output 44 */
1567 kTopEgretPinmuxOutselUart3Tx = 48, /**< Peripheral Output 45 */
1568 kTopEgretPinmuxOutselPattgenPda0Tx = 49, /**< Peripheral Output 46 */
1569 kTopEgretPinmuxOutselPattgenPcl0Tx = 50, /**< Peripheral Output 47 */
1570 kTopEgretPinmuxOutselPattgenPda1Tx = 51, /**< Peripheral Output 48 */
1571 kTopEgretPinmuxOutselPattgenPcl1Tx = 52, /**< Peripheral Output 49 */
1572 kTopEgretPinmuxOutselSpiHost1Sck = 53, /**< Peripheral Output 50 */
1573 kTopEgretPinmuxOutselSpiHost1Csb = 54, /**< Peripheral Output 51 */
1574 kTopEgretPinmuxOutselFlashMacroWrapperTdo = 55, /**< Peripheral Output 52 */
1575 kTopEgretPinmuxOutselSensorCtrlAonAstDebugOut0 = 56, /**< Peripheral Output 53 */
1576 kTopEgretPinmuxOutselSensorCtrlAonAstDebugOut1 = 57, /**< Peripheral Output 54 */
1577 kTopEgretPinmuxOutselSensorCtrlAonAstDebugOut2 = 58, /**< Peripheral Output 55 */
1578 kTopEgretPinmuxOutselSensorCtrlAonAstDebugOut3 = 59, /**< Peripheral Output 56 */
1579 kTopEgretPinmuxOutselSensorCtrlAonAstDebugOut4 = 60, /**< Peripheral Output 57 */
1580 kTopEgretPinmuxOutselSensorCtrlAonAstDebugOut5 = 61, /**< Peripheral Output 58 */
1581 kTopEgretPinmuxOutselSensorCtrlAonAstDebugOut6 = 62, /**< Peripheral Output 59 */
1582 kTopEgretPinmuxOutselSensorCtrlAonAstDebugOut7 = 63, /**< Peripheral Output 60 */
1583 kTopEgretPinmuxOutselSensorCtrlAonAstDebugOut8 = 64, /**< Peripheral Output 61 */
1584 kTopEgretPinmuxOutselPwmAonPwm0 = 65, /**< Peripheral Output 62 */
1585 kTopEgretPinmuxOutselPwmAonPwm1 = 66, /**< Peripheral Output 63 */
1586 kTopEgretPinmuxOutselPwmAonPwm2 = 67, /**< Peripheral Output 64 */
1587 kTopEgretPinmuxOutselPwmAonPwm3 = 68, /**< Peripheral Output 65 */
1588 kTopEgretPinmuxOutselPwmAonPwm4 = 69, /**< Peripheral Output 66 */
1589 kTopEgretPinmuxOutselPwmAonPwm5 = 70, /**< Peripheral Output 67 */
1590 kTopEgretPinmuxOutselOtpMacroTest0 = 71, /**< Peripheral Output 68 */
1591 kTopEgretPinmuxOutselSysrstCtrlAonBatDisable = 72, /**< Peripheral Output 69 */
1592 kTopEgretPinmuxOutselSysrstCtrlAonKey0Out = 73, /**< Peripheral Output 70 */
1593 kTopEgretPinmuxOutselSysrstCtrlAonKey1Out = 74, /**< Peripheral Output 71 */
1594 kTopEgretPinmuxOutselSysrstCtrlAonKey2Out = 75, /**< Peripheral Output 72 */
1595 kTopEgretPinmuxOutselSysrstCtrlAonPwrbOut = 76, /**< Peripheral Output 73 */
1596 kTopEgretPinmuxOutselSysrstCtrlAonZ3Wakeup = 77, /**< Peripheral Output 74 */
1597 kTopEgretPinmuxOutselLast = 77, /**< \internal Last valid outsel value */
1599
1600/**
1601 * Dedicated Pad Selects
1602 */
1604 kTopEgretDirectPadsUsbdevUsbDp = 0, /**< */
1605 kTopEgretDirectPadsUsbdevUsbDn = 1, /**< */
1606 kTopEgretDirectPadsSpiHost0Sd0 = 2, /**< */
1607 kTopEgretDirectPadsSpiHost0Sd1 = 3, /**< */
1608 kTopEgretDirectPadsSpiHost0Sd2 = 4, /**< */
1609 kTopEgretDirectPadsSpiHost0Sd3 = 5, /**< */
1610 kTopEgretDirectPadsSpiDeviceSd0 = 6, /**< */
1611 kTopEgretDirectPadsSpiDeviceSd1 = 7, /**< */
1612 kTopEgretDirectPadsSpiDeviceSd2 = 8, /**< */
1613 kTopEgretDirectPadsSpiDeviceSd3 = 9, /**< */
1614 kTopEgretDirectPadsSysrstCtrlAonEcRstL = 10, /**< */
1615 kTopEgretDirectPadsSysrstCtrlAonFlashWpL = 11, /**< */
1616 kTopEgretDirectPadsSpiDeviceSck = 12, /**< */
1617 kTopEgretDirectPadsSpiDeviceCsb = 13, /**< */
1618 kTopEgretDirectPadsSpiHost0Sck = 14, /**< */
1619 kTopEgretDirectPadsSpiHost0Csb = 15, /**< */
1620 kTopEgretDirectPadsLast = 15, /**< \internal Last valid direct pad */
1622
1623/**
1624 * Muxed Pad Selects
1625 */
1627 kTopEgretMuxedPadsIoa0 = 0, /**< */
1628 kTopEgretMuxedPadsIoa1 = 1, /**< */
1629 kTopEgretMuxedPadsIoa2 = 2, /**< */
1630 kTopEgretMuxedPadsIoa3 = 3, /**< */
1631 kTopEgretMuxedPadsIoa4 = 4, /**< */
1632 kTopEgretMuxedPadsIoa5 = 5, /**< */
1633 kTopEgretMuxedPadsIoa6 = 6, /**< */
1634 kTopEgretMuxedPadsIoa7 = 7, /**< */
1635 kTopEgretMuxedPadsIoa8 = 8, /**< */
1636 kTopEgretMuxedPadsIob0 = 9, /**< */
1637 kTopEgretMuxedPadsIob1 = 10, /**< */
1638 kTopEgretMuxedPadsIob2 = 11, /**< */
1639 kTopEgretMuxedPadsIob3 = 12, /**< */
1640 kTopEgretMuxedPadsIob4 = 13, /**< */
1641 kTopEgretMuxedPadsIob5 = 14, /**< */
1642 kTopEgretMuxedPadsIob6 = 15, /**< */
1643 kTopEgretMuxedPadsIob7 = 16, /**< */
1644 kTopEgretMuxedPadsIob8 = 17, /**< */
1645 kTopEgretMuxedPadsIob9 = 18, /**< */
1646 kTopEgretMuxedPadsIob10 = 19, /**< */
1647 kTopEgretMuxedPadsIob11 = 20, /**< */
1648 kTopEgretMuxedPadsIob12 = 21, /**< */
1649 kTopEgretMuxedPadsIoc0 = 22, /**< */
1650 kTopEgretMuxedPadsIoc1 = 23, /**< */
1651 kTopEgretMuxedPadsIoc2 = 24, /**< */
1652 kTopEgretMuxedPadsIoc3 = 25, /**< */
1653 kTopEgretMuxedPadsIoc4 = 26, /**< */
1654 kTopEgretMuxedPadsIoc5 = 27, /**< */
1655 kTopEgretMuxedPadsIoc6 = 28, /**< */
1656 kTopEgretMuxedPadsIoc7 = 29, /**< */
1657 kTopEgretMuxedPadsIoc8 = 30, /**< */
1658 kTopEgretMuxedPadsIoc9 = 31, /**< */
1659 kTopEgretMuxedPadsIoc10 = 32, /**< */
1660 kTopEgretMuxedPadsIoc11 = 33, /**< */
1661 kTopEgretMuxedPadsIoc12 = 34, /**< */
1662 kTopEgretMuxedPadsIor0 = 35, /**< */
1663 kTopEgretMuxedPadsIor1 = 36, /**< */
1664 kTopEgretMuxedPadsIor2 = 37, /**< */
1665 kTopEgretMuxedPadsIor3 = 38, /**< */
1666 kTopEgretMuxedPadsIor4 = 39, /**< */
1667 kTopEgretMuxedPadsIor5 = 40, /**< */
1668 kTopEgretMuxedPadsIor6 = 41, /**< */
1669 kTopEgretMuxedPadsIor7 = 42, /**< */
1670 kTopEgretMuxedPadsIor10 = 43, /**< */
1671 kTopEgretMuxedPadsIor11 = 44, /**< */
1672 kTopEgretMuxedPadsIor12 = 45, /**< */
1673 kTopEgretMuxedPadsIor13 = 46, /**< */
1674 kTopEgretMuxedPadsLast = 46, /**< \internal Last valid muxed pad */
1676
1677/**
1678 * Power Manager Wakeup Signals
1679 */
1681 kTopEgretPowerManagerWakeUpsSysrstCtrlAonWkupReq = 0, /**< */
1682 kTopEgretPowerManagerWakeUpsAdcCtrlAonWkupReq = 1, /**< */
1683 kTopEgretPowerManagerWakeUpsPinmuxAonPinWkupReq = 2, /**< */
1684 kTopEgretPowerManagerWakeUpsPinmuxAonUsbWkupReq = 3, /**< */
1685 kTopEgretPowerManagerWakeUpsAonTimerAonWkupReq = 4, /**< */
1686 kTopEgretPowerManagerWakeUpsSensorCtrlAonWkupReq = 5, /**< */
1687 kTopEgretPowerManagerWakeUpsLast = 5, /**< \internal Last valid pwrmgr wakeup signal */
1689
1690/**
1691 * Reset Manager Software Controlled Resets
1692 */
1694 kTopEgretResetManagerSwResetsSpiDevice = 0, /**< */
1695 kTopEgretResetManagerSwResetsSpiHost0 = 1, /**< */
1696 kTopEgretResetManagerSwResetsSpiHost1 = 2, /**< */
1697 kTopEgretResetManagerSwResetsUsb = 3, /**< */
1698 kTopEgretResetManagerSwResetsUsbAon = 4, /**< */
1699 kTopEgretResetManagerSwResetsI2c0 = 5, /**< */
1700 kTopEgretResetManagerSwResetsI2c1 = 6, /**< */
1701 kTopEgretResetManagerSwResetsI2c2 = 7, /**< */
1702 kTopEgretResetManagerSwResetsLast = 7, /**< \internal Last valid rstmgr software reset request */
1704
1705/**
1706 * Power Manager Reset Request Signals
1707 */
1709 kTopEgretPowerManagerResetRequestsSysrstCtrlAonRstReq = 0, /**< */
1710 kTopEgretPowerManagerResetRequestsAonTimerAonAonTimerRstReq = 1, /**< */
1711 kTopEgretPowerManagerResetRequestsLast = 1, /**< \internal Last valid pwrmgr reset_request signal */
1713
1714/**
1715 * Clock Manager Software-Controlled ("Gated") Clocks.
1716 *
1717 * The Software has full control over these clocks.
1718 */
1720 kTopEgretGateableClocksIoDiv4Peri = 0, /**< Clock clk_io_div4_peri in group peri */
1721 kTopEgretGateableClocksIoDiv2Peri = 1, /**< Clock clk_io_div2_peri in group peri */
1722 kTopEgretGateableClocksIoPeri = 2, /**< Clock clk_io_peri in group peri */
1723 kTopEgretGateableClocksUsbPeri = 3, /**< Clock clk_usb_peri in group peri */
1724 kTopEgretGateableClocksLast = 3, /**< \internal Last Valid Gateable Clock */
1726
1727/**
1728 * Clock Manager Software-Hinted Clocks.
1729 *
1730 * The Software has partial control over these clocks. It can ask them to stop,
1731 * but the clock manager is in control of whether the clock actually is stopped.
1732 */
1734 kTopEgretHintableClocksMainAcc = 0, /**< Clock clk_main_acc in group trans */
1735 kTopEgretHintableClocksMainAes = 1, /**< Clock clk_main_aes in group trans */
1736 kTopEgretHintableClocksMainHmac = 2, /**< Clock clk_main_hmac in group trans */
1737 kTopEgretHintableClocksMainKmac = 3, /**< Clock clk_main_kmac in group trans */
1738 kTopEgretHintableClocksLast = 3, /**< \internal Last Valid Hintable Clock */
1740
1741/**
1742 * MMIO Region
1743 *
1744 * MMIO region excludes any memory that is separate from the module
1745 * configuration space, i.e. ROM, main SRAM, and flash are excluded but
1746 * retention SRAM, spi_device memory, or usbdev memory are included.
1747 */
1748#define TOP_EGRET_MMIO_BASE_ADDR 0x40000000u
1749#define TOP_EGRET_MMIO_SIZE_BYTES 0x10000000u
1750
1751// Header Extern Guard
1752#ifdef __cplusplus
1753} // extern "C"
1754#endif
1755
1756#endif // OPENTITAN_HW_TOP_EGRET_SW_AUTOGEN_TOP_EGRET_H_