From 3212d3556f68f18969bf45b3951743457c232ef0 Mon Sep 17 00:00:00 2001 From: chirag-silabs <100861685+chirag-silabs@users.noreply.github.com> Date: Tue, 25 Apr 2023 19:47:15 +0530 Subject: [PATCH] adding the lock and unlock chip stack and some build fixes for 917 SoC (#26245) --- examples/platform/silabs/SiWx917/BaseApplication.cpp | 3 +++ examples/platform/silabs/efr32/BaseApplication.cpp | 3 +++ src/platform/silabs/platformAbstraction/WiseMCU_SPAM.cpp | 4 ++-- 3 files changed, 8 insertions(+), 2 deletions(-) diff --git a/examples/platform/silabs/SiWx917/BaseApplication.cpp b/examples/platform/silabs/SiWx917/BaseApplication.cpp index f0dde1ffc39e80..62b5f4cc1bc361 100644 --- a/examples/platform/silabs/SiWx917/BaseApplication.cpp +++ b/examples/platform/silabs/SiWx917/BaseApplication.cpp @@ -166,7 +166,10 @@ CHIP_ERROR BaseApplication::Init(Identify * identifyObj) SILABS_LOG("APP: Done WiFi Init"); /* We will init server when we get IP */ + chip::DeviceLayer::PlatformMgr().LockChipStack(); sWiFiNetworkCommissioningInstance.Init(); + chip::DeviceLayer::PlatformMgr().UnlockChipStack(); + #endif // Create FreeRTOS sw timer for Function Selection. diff --git a/examples/platform/silabs/efr32/BaseApplication.cpp b/examples/platform/silabs/efr32/BaseApplication.cpp index e29797607f7e35..6ce48e736d121e 100644 --- a/examples/platform/silabs/efr32/BaseApplication.cpp +++ b/examples/platform/silabs/efr32/BaseApplication.cpp @@ -178,7 +178,10 @@ CHIP_ERROR BaseApplication::Init(Identify * identifyObj) SILABS_LOG("APP: Done WiFi Init"); /* We will init server when we get IP */ + chip::DeviceLayer::PlatformMgr().LockChipStack(); sWiFiNetworkCommissioningInstance.Init(); + chip::DeviceLayer::PlatformMgr().UnlockChipStack(); + #endif // Create FreeRTOS sw timer for Function Selection. diff --git a/src/platform/silabs/platformAbstraction/WiseMCU_SPAM.cpp b/src/platform/silabs/platformAbstraction/WiseMCU_SPAM.cpp index 816c9a6df4459d..7b5af3e6e87c2b 100644 --- a/src/platform/silabs/platformAbstraction/WiseMCU_SPAM.cpp +++ b/src/platform/silabs/platformAbstraction/WiseMCU_SPAM.cpp @@ -41,7 +41,7 @@ void SilabsPlatform::InitLed(void) SilabsPlatformAbstractionBase::InitLed(); } -CHIP_ERROR SilabsPlatform::SetLed(bool state, uint8_t led) override +CHIP_ERROR SilabsPlatform::SetLed(bool state, uint8_t led) { // TODO add range check RSI_Board_LED_Set(led, state); @@ -54,7 +54,7 @@ bool SilabsPlatform::GetLedState(uint8_t led) return SilabsPlatformAbstractionBase::GetLedState(led); } -CHIP_ERROR SilabsPlatform::ToggleLed(uint8_t led) override +CHIP_ERROR SilabsPlatform::ToggleLed(uint8_t led) { // TODO add range check RSI_Board_LED_Toggle(led);