Skip to content

Commit

Permalink
[mw320] Remove doing factory-reset on fail-safe armed (#29882)
Browse files Browse the repository at this point in the history
Signed-off-by: Chin-Ran Lo <[email protected]>
  • Loading branch information
crlonxp authored Oct 21, 2023
1 parent 7966379 commit 2f612b0
Showing 1 changed file with 0 additions and 7 deletions.
7 changes: 0 additions & 7 deletions src/platform/nxp/mw320/ConfigurationManagerImpl.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,6 @@ CHIP_ERROR ConfigurationManagerImpl::Init()
{
CHIP_ERROR err;
uint32_t rebootCount = 0;
bool failSafeArmed;

// Initialize the generic implementation base class.
// err = Internal::GenericConfigurationManagerImpl<ConfigurationManagerImpl>::Init();
Expand All @@ -74,12 +73,6 @@ CHIP_ERROR ConfigurationManagerImpl::Init()
err = StoreRebootCount(1);
SuccessOrExit(err);
}
// If the fail-safe was armed when the device last shutdown, initiate a factory reset.
if (GetFailSafeArmed(failSafeArmed) == CHIP_NO_ERROR && failSafeArmed)
{
ChipLogProgress(DeviceLayer, "Detected fail-safe armed on reboot; initiating factory reset");
InitiateFactoryReset();
}

if (!MW320Config::ConfigValueExists(MW320Config::kCounterKey_BootReason))
{
Expand Down

0 comments on commit 2f612b0

Please sign in to comment.