AM62x MCU+ SDK  09.01.00
sdl_soc_pok.h
Go to the documentation of this file.
1 /*
2  * Copyright (c) Texas Instruments Incorporated 2023
3  *
4  * Redistribution and use in source and binary forms, with or without
5  * modification, are permitted provided that the following conditions
6  * are met:
7  *
8  * Redistributions of source code must retain the above copyright
9  * notice, this list of conditions and the following disclaimer.
10  *
11  * Redistributions in binary form must reproduce the above copyright
12  * notice, this list of conditions and the following disclaimer in the
13  * documentation and/or other materials provided with the
14  * distribution.
15  *
16  * Neither the name of Texas Instruments Incorporated nor the names of
17  * its contributors may be used to endorse or promote products derived
18  * from this software without specific prior written permission.
19  *
20  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
21  * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
22  * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
23  * A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
24  * OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
25  * SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
26  * LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
27  * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
28  * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
29  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
30  * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
31  *
32  */
33 
42 #ifndef SDL_SOC_POK_H_
43 #define SDL_SOC_POK_H_
44 #include <sdl/esm/sdl_ip_esm.h>
45 #include <sdl/dpl/sdl_dpl.h>
46 #include <sdl/include/am62x/sdlr_soc_baseaddress.h>
47 #include <sdl/include/am62x/sdlr_mcu_ctrl_mmr.h>
48 #include <sdl/include/am62x/sdlr_intr_wkup_esm0.h>
49 
50 
51 #ifdef __cplusplus
52 extern "C" {
53 #endif
54 
72 /**************************************************************************
73 * Register Macros
74 **************************************************************************/
75 
76 typedef int8_t SDL_POK_Inst ;
77 
79 #define SDL_FIRST_POK_ID (0)
80 /* PMIC POK ID */
81 #define SDL_POK_VDDA_PMIC_IN_ID (SDL_FIRST_POK_ID)
82 /* VDDS DDRIO Under voltage/Over Voltage POK ID */
83 #define SDL_POK_VDDS_DDRIO_ID (1)
84 /* VDDR CORE Under Voltage/Over Voltage POK ID */
85 #define SDL_POK_VDDR_CORE_ID (2)
86  /* VMON CAP MCU Under Voltage/Over Voltage POK ID */
87 #define SDL_POK_VMON_CAP_MCU_GENERAL_ID (3)
88 /* VDDSHV MAIN 1P8 Under Voltage/Over Voltage POK ID */
89 #define SDL_POK_VDDSHV_MAIN_1P8_ID (4)
90 /* VDDSHV MAIN 3P3 Under Voltage/Over Voltage POK ID */
91 #define SDL_POK_VDDSHV_MAIN_3P3_ID (5)
92 /* CORE Over Voltage POK ID */
93 #define SDL_POK_VDD_MCU_OV_ID (6)
94 /* VDDA MCU Under Voltage POK ID */
95 #define SDL_POR_VDDA_MCU_UV_ID (7)
96 /* VDD Under Voltage POK ID */
97 #define SDL_POR_VDD_MCU_UV_ID (8)
98 /* VDDA MCU Over Voltage POK ID */
99 #define SDL_POR_VDDA_MCU_OV_ID (9)
100 
101 /* LAST POK ID */
102 #define SDL_LAST_POK_ID (SDL_POR_VDDA_MCU_OV_ID)
103 
104 
105 typedef int8_t SDL_PRG_Inst;
106 
108 #define SDL_POK_PRG_FIRST_ID (0)
109 
110 #define SDL_POK_PRG_PP_0_ID (1)
111 
112 #define SDL_POK_PRG_PP_1_ID (2)
113 
115 #define SDL_POK_PRG_LAST_ID (SDL_POK_PRG_PP_1_ID)
116 
117 
118 
119 
120 
121 
122 #define SDL_POK_MMR_BASE (SDL_MCU_CTRL_MMR0_CFG0_BASE)
123 #if defined (M4F_CORE)
124 #define MCU_ESM_INSTANCE (SDL_WKUP_ESM0_CFG_BASE)
125 #define MCU_ESM_INTID (SDLR_WKUP_ESM0_ESM_LVL_EVENT_ESM0_ESM_INT_HI_LVL_0)
126 #endif
127 
128 #if defined (R5F_CORE)
129 #define MCU_ESM_INSTANCE (SDL_ESM0_CFG_BASE)
130 #define MCU_ESM_INTID (SDLR_ESM0_ESM_LVL_EVENT_WKUP_ESM0_ESM_INT_HI_LVL_0)
131 #endif
132 
133 #define MCU_ESM_ERR_SIG_VDDA_PMIC_IN_UV (SDLR_WKUP_ESM0_ESM_PLS_EVENT0_MCU_PRG_MCU0_POK_PGOOD_UV_OUT_N_TO_ESM_3)
134 #define MCU_ESM_ERR_SIG_VDD_MCU_UV (SDLR_WKUP_ESM0_ESM_PLS_EVENT0_MCU_PRG_MCU0_POK_PGOOD_UV_OUT_N_TO_ESM_0 )
135 #define MCU_ESM_ERR_SIG_VDD_MCU_OV (SDLR_WKUP_ESM0_ESM_PLS_EVENT0_MCU_PRG_MCU0_POK_PGOOD_UV_OUT_N_TO_ESM_4)
136 #define MCU_ESM_ERR_SIG_VDDS_DDRIO_UV (SDLR_WKUP_ESM0_ESM_PLS_EVENT0_MCU_PRG_MCU_5POKS0_POK_PGOOD_UV_OUT_N_TO_ESM_4)
137 #define MCU_ESM_ERR_SIG_VDDS_DDRIO_OV (SDLR_WKUP_ESM0_ESM_PLS_EVENT0_MCU_PRG_MCU_5POKS0_POK_PGOOD_OV_OUT_N_TO_ESM_4)
138 #define MCU_ESM_ERR_SIG_VDDR_CORE_UV (SDLR_WKUP_ESM0_ESM_PLS_EVENT0_MCU_PRG_MCU_5POKS0_POK_PGOOD_UV_OUT_N_TO_ESM_3)
139 #define MCU_ESM_ERR_SIG_VDDR_CORE_OV (SDLR_WKUP_ESM0_ESM_PLS_EVENT0_MCU_PRG_MCU_5POKS0_POK_PGOOD_OV_OUT_N_TO_ESM_3)
140 #define MCU_ESM_ERR_SIG_VMON_CAP_MCU_GENERAL_UV (SDLR_WKUP_ESM0_ESM_PLS_EVENT0_MCU_PRG_MCU_5POKS0_POK_PGOOD_UV_OUT_N_TO_ESM_2 )
141 #define MCU_ESM_ERR_SIG_VMON_CAP_MCU_GENERAL_OV (SDLR_WKUP_ESM0_ESM_PLS_EVENT0_MCU_PRG_MCU_5POKS0_POK_PGOOD_OV_OUT_N_TO_ESM_2)
142 #define MCU_ESM_ERR_SIG_VDDSHV_MAIN_1P8_UV (SDLR_WKUP_ESM0_ESM_PLS_EVENT0_MCU_PRG_MCU_5POKS0_POK_PGOOD_UV_OUT_N_TO_ESM_1)
143 #define MCU_ESM_ERR_SIG_VDDSHV_MAIN_1P8_OV (SDLR_WKUP_ESM0_ESM_PLS_EVENT0_MCU_PRG_MCU_5POKS0_POK_PGOOD_OV_OUT_N_TO_ESM_1)
144 #define MCU_ESM_ERR_SIG_VDDSHV_MAIN_3P3_UV (SDLR_WKUP_ESM0_ESM_PLS_EVENT0_MCU_PRG_MCU_5POKS0_POK_PGOOD_UV_OUT_N_TO_ESM_0)
145 #define MCU_ESM_ERR_SIG_VDDSHV_MAIN_3P3_OV (SDLR_WKUP_ESM0_ESM_PLS_EVENT0_MCU_PRG_MCU_5POKS0_POK_PGOOD_OV_OUT_N_TO_ESM_0)
146 #define MCU_ESM_ERR_SIG_VDDA_MCU_UV (SDLR_WKUP_ESM0_ESM_PLS_EVENT0_MCU_PRG_MCU0_POK_PGOOD_UV_OUT_N_TO_ESM_2)
147 #define MCU_ESM_ERR_SIG_VDDA_MCU_OV (SDLR_WKUP_ESM0_ESM_PLS_EVENT0_MCU_PRG_MCU0_POK_PGOOD_UV_OUT_N_TO_ESM_1)
148 
149 
150 
151 #define ESM_ERR_SIG_VDDA_PMIC_IN_UV MCU_ESM_ERR_SIG_VDDA_PMIC_IN_UV
152 #define ESM_ERR_SIG_VDD_MCU_UV MCU_ESM_ERR_SIG_VDD_MCU_UV
153 #define ESM_ERR_SIG_VDD_MCU_OV MCU_ESM_ERR_SIG_VDD_MCU_OV
154 #define ESM_ERR_SIG_VDDS_DDRIO_UV MCU_ESM_ERR_SIG_VDDS_DDRIO_UV
155 #define ESM_ERR_SIG_VDDS_DDRIO_OV MCU_ESM_ERR_SIG_VDDS_DDRIO_OV
156 #define ESM_ERR_SIG_VDDR_CORE_UV MCU_ESM_ERR_SIG_VDDR_CORE_UV
157 #define ESM_ERR_SIG_VDDR_CORE_OV MCU_ESM_ERR_SIG_VDDR_CORE_OV
158 #define ESM_ERR_SIG_VMON_CAP_MCU_GENERAL_UV MCU_ESM_ERR_SIG_VMON_CAP_MCU_GENERAL_UV
159 #define ESM_ERR_SIG_VMON_CAP_MCU_GENERAL_OV MCU_ESM_ERR_SIG_VMON_CAP_MCU_GENERAL_OV
160 #define ESM_ERR_SIG_VDDSHV_MAIN_1P8_UV MCU_ESM_ERR_SIG_VDDSHV_MAIN_1P8_UV
161 #define ESM_ERR_SIG_VDDSHV_MAIN_1P8_OV MCU_ESM_ERR_SIG_VDDSHV_MAIN_1P8_OV
162 #define ESM_ERR_SIG_VDDSHV_MAIN_3P3_UV MCU_ESM_ERR_SIG_VDDSHV_MAIN_3P3_UV
163 #define ESM_ERR_SIG_VDDSHV_MAIN_3P3_OV MCU_ESM_ERR_SIG_VDDSHV_MAIN_3P3_OV
164 #define ESM_ERR_SIG_VDDA_MCU_UV MCU_ESM_ERR_SIG_VDDA_MCU_UV
165 #define ESM_ERR_SIG_VDDA_MCU_OV MCU_ESM_ERR_SIG_VDDA_MCU_OV
166 
167 
168 
169 
170 
171 #define ESM_INSTANCE MCU_ESM_INSTANCE
172 #define ESM_INTID MCU_ESM_INTID
173 
174 
175 
176 
177 
178 
179 typedef enum{
181 
183 
184 bool SDL_POK_getBaseaddr(SDL_POK_InstanceType instance, uint32_t *pbaseAddress);
185 
186 
187 
188 
189 #ifdef __cplusplus
190 }
191 #endif
192 #endif /* SDL_SOC_POK_H_ */
193 
194 
SDL_PRG_Inst
int8_t SDL_PRG_Inst
Definition: sdl_soc_pok.h:105
SDL_POK_InstanceType
SDL_POK_InstanceType
Definition: sdl_soc_pok.h:179
sdl_dpl.h
This file contains the SDL DPL API's.
SDL_POK_MCU_CTRL_MMR0
@ SDL_POK_MCU_CTRL_MMR0
Definition: sdl_soc_pok.h:180
SDL_POK_getBaseaddr
bool SDL_POK_getBaseaddr(SDL_POK_InstanceType instance, uint32_t *pbaseAddress)
SDL_POK_Inst
int8_t SDL_POK_Inst
Definition: sdl_soc_pok.h:76