always resolve (#2678)

This commit is contained in:
Matthew Kennedy 2021-05-10 05:53:19 -07:00 committed by GitHub
parent 5450a87ca5
commit cde70534f7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 5 additions and 4 deletions

View File

@ -172,17 +172,18 @@ static persisted_configuration_state_e doReadConfiguration(flashaddr_t address)
*/
static persisted_configuration_state_e readConfiguration() {
efiAssert(CUSTOM_ERR_ASSERT, getCurrentRemainingStack() > EXPECTED_REMAINING_STACK, "read f", PC_ERROR);
auto firstCopyAddr = getFlashAddrFirstCopy();
auto secondyCopyAddr = getFlashAddrSecondCopy();
#if HW_CHECK_MODE
persisted_configuration_state_e result = PC_OK;
resetConfigurationExt(DEFAULT_ENGINE_TYPE PASS_ENGINE_PARAMETER_SUFFIX);
#else // HW_CHECK_MODE
persisted_configuration_state_e result = doReadConfiguration(getFlashAddrFirstCopy());
persisted_configuration_state_e result = doReadConfiguration(firstCopyAddr);
if (result != PC_OK) {
efiPrintf("Reading second configuration copy");
result = doReadConfiguration(getFlashAddrSecondCopy());
result = doReadConfiguration(secondyCopyAddr);
}
if (result == CRC_FAILED) {