diff --git a/src/platform/silabs/SilabsConfig.cpp b/src/platform/silabs/SilabsConfig.cpp index 1d5fab99c71e5b..c887e6f2d0ac8c 100644 --- a/src/platform/silabs/SilabsConfig.cpp +++ b/src/platform/silabs/SilabsConfig.cpp @@ -35,6 +35,7 @@ #include "nvm3_hal_flash.h" #include +#ifndef BRD4325A // TODO: fix semaphore usage in nvm3_lock for siwx917. use weak implementation for that board instead // Substitute the GSDK weak nvm3_lockBegin and nvm3_lockEnd // for an application controlled re-entrance protection static SemaphoreHandle_t nvm3_Sem; @@ -51,6 +52,7 @@ void nvm3_lockEnd(void) VerifyOrDie(nvm3_Sem != NULL); xSemaphoreGive(nvm3_Sem); } +#endif // not BRD4325A namespace chip { namespace DeviceLayer { @@ -63,6 +65,7 @@ namespace Internal { CHIP_ERROR SilabsConfig::Init() { +#ifndef BRD4325A // TODO: fix semaphore usage in nvm3_lock for siwx917. use weak implementation for that board instead nvm3_Sem = xSemaphoreCreateBinaryStatic(&nvm3_SemStruct); if (nvm3_Sem == NULL) @@ -70,12 +73,15 @@ CHIP_ERROR SilabsConfig::Init() return CHIP_ERROR_NO_MEMORY; } xSemaphoreGive(nvm3_Sem); +#endif // not BRD4325A return MapNvm3Error(nvm3_open(nvm3_defaultHandle, nvm3_defaultInit)); } void SilabsConfig::DeInit() { +#ifndef BRD4325A // TODO: fix semaphore usage in nvm3_lock for siwx917. use weak implementation for that board instead vSemaphoreDelete(nvm3_Sem); +#endif // not BRD4325A nvm3_close(nvm3_defaultHandle); }