|
35 | 35 |
|
36 | 36 | using namespace scomt::poz;
|
37 | 37 |
|
38 |
| - |
39 | 38 | SCOMT_PERV_USE_FSXCOMP_FSXLOG_SB_CS;
|
40 | 39 | SCOMT_PERV_USE_FSXCOMP_FSXLOG_SB_MSG;
|
41 | 40 |
|
@@ -82,6 +81,10 @@ ReturnCode poz_sbe_hreset(
|
82 | 81 | FAPI_INF("SBE is in NOT Runtime State");
|
83 | 82 | }
|
84 | 83 |
|
| 84 | + FAPI_INF("Clearing boot status in SB_MSG register before doing HRESET"); |
| 85 | + SB_MSG.clearBit<0>(); |
| 86 | + FAPI_TRY(SB_MSG.putCfam(i_target)); |
| 87 | + |
85 | 88 | FAPI_INF("Resetting restart vector0 and vector1 ...");
|
86 | 89 | FAPI_TRY(SB_CS.getCfam(i_target));
|
87 | 90 | SB_CS.set_START_RESTART_VECTOR0(0);
|
@@ -110,13 +113,24 @@ ReturnCode poz_sbe_hreset(
|
110 | 113 | // bump count
|
111 | 114 | l_poll++;
|
112 | 115 |
|
| 116 | + if (!(l_poll <= i_boot_parms.max_polls)) |
| 117 | + { |
| 118 | + FAPI_TRY(SB_CS.getCfam(i_target)); |
| 119 | + |
| 120 | + if (SB_CS.get_SECURE_DEBUG_MODE()) |
| 121 | + { |
| 122 | + FAPI_ERR("SBE Boot failed since SDB is set"); |
| 123 | + } |
| 124 | + } |
| 125 | + |
113 | 126 | // test for timeout
|
114 | 127 | FAPI_ASSERT((l_poll <= i_boot_parms.max_polls),
|
115 | 128 | fapi2::SBE_BOOT_CHECK_ERR_CFAM_PATH()
|
116 | 129 | .set_TARGET(i_target)
|
117 | 130 | .set_POLL_COUNT(i_boot_parms.max_polls)
|
118 | 131 | .set_POLL_DELAY(i_boot_parms.poll_delay_ns)
|
119 | 132 | .set_SB_CS(SB_CS)
|
| 133 | + .set_SDB(SB_CS.get_SECURE_DEBUG_MODE()) |
120 | 134 | .set_SB_MSG(SB_MSG),
|
121 | 135 | //.set_BOOT_TYPE(l_check_for_runtime),
|
122 | 136 | "SBE did not Boot up prior to timeout!");
|
@@ -149,6 +163,10 @@ ReturnCode poz_sbe_hreset(
|
149 | 163 | FAPI_INF("SBE is in NOT Runtime State");
|
150 | 164 | }
|
151 | 165 |
|
| 166 | + FAPI_INF("Clearing boot status in SB_MSG register before doing HRESET"); |
| 167 | + SB_MSG.clearBit<0>(); |
| 168 | + FAPI_TRY(SB_MSG.putScom(i_target)); |
| 169 | + |
152 | 170 | FAPI_INF("Resetting restart vector1 ...");
|
153 | 171 | FAPI_TRY(SB_CS.getScom(i_target));
|
154 | 172 | SB_CS.set_START_RESTART_VECTOR1(0);
|
@@ -176,13 +194,24 @@ ReturnCode poz_sbe_hreset(
|
176 | 194 | // bump count
|
177 | 195 | l_poll++;
|
178 | 196 |
|
| 197 | + if (!(l_poll <= i_boot_parms.max_polls)) |
| 198 | + { |
| 199 | + FAPI_TRY(SB_CS.getScom(i_target)); |
| 200 | + |
| 201 | + if (SB_CS.get_SECURE_DEBUG_MODE()) |
| 202 | + { |
| 203 | + FAPI_ERR("SBE Boot failed since SDB is set"); |
| 204 | + } |
| 205 | + } |
| 206 | + |
179 | 207 | // test for timeout
|
180 | 208 | FAPI_ASSERT((l_poll <= i_boot_parms.max_polls),
|
181 | 209 | fapi2::SBE_BOOT_CHECK_ERR_SCOM_PATH()
|
182 | 210 | .set_TARGET(i_target)
|
183 | 211 | .set_POLL_COUNT(i_boot_parms.max_polls)
|
184 | 212 | .set_POLL_DELAY(i_boot_parms.poll_delay_ns)
|
185 | 213 | .set_SB_CS(SB_CS)
|
| 214 | + .set_SDB(SB_CS.get_SECURE_DEBUG_MODE()) |
186 | 215 | .set_SB_MSG(SB_MSG),
|
187 | 216 | //.set_BOOT_TYPE(l_check_for_runtime),
|
188 | 217 | "SBE did not Boot up prior to timeout!");
|
|
0 commit comments