Skip to content

Commit b6710a6

Browse files
restyled-commitslpbeliveau-silabs
authored andcommitted
Restyled by clang-format
1 parent 9f93eb7 commit b6710a6

File tree

4 files changed

+18
-21
lines changed

4 files changed

+18
-21
lines changed

examples/platform/silabs/BaseApplication.cpp

+12-10
Original file line numberDiff line numberDiff line change
@@ -115,8 +115,8 @@ app::Clusters::NetworkCommissioning::Instance
115115
sWiFiNetworkCommissioningInstance(0 /* Endpoint Id */, &(NetworkCommissioning::SlWiFiDriver::GetInstance()));
116116
#endif /* SL_WIFI */
117117

118-
bool sIsEnabled = false;
119-
bool sIsAttached = false;
118+
bool sIsEnabled = false;
119+
bool sIsAttached = false;
120120

121121
#if !(defined(CHIP_CONFIG_ENABLE_ICD_SERVER) && CHIP_CONFIG_ENABLE_ICD_SERVER)
122122
bool sHaveBLEConnections = false;
@@ -160,9 +160,9 @@ Identify gIdentify = {
160160

161161
} // namespace
162162

163-
bool BaseApplication::sIsProvisioned = false;
164-
bool BaseApplication::sIsFactoryResetTriggered = false;
165-
LEDWidget * BaseApplication::sAppActionLed = nullptr;
163+
bool BaseApplication::sIsProvisioned = false;
164+
bool BaseApplication::sIsFactoryResetTriggered = false;
165+
LEDWidget * BaseApplication::sAppActionLed = nullptr;
166166
BaseApplicationDelegate BaseApplication::sAppDelegate = BaseApplicationDelegate();
167167

168168
#ifdef DIC_ENABLE
@@ -438,14 +438,14 @@ void BaseApplication::UpdateCommissioningStatus(bool newState)
438438
{
439439
#ifdef SL_WIFI
440440
BaseApplication::sIsProvisioned = ConnectivityMgr().IsWiFiStationProvisioned();
441-
sIsEnabled = ConnectivityMgr().IsWiFiStationEnabled();
442-
sIsAttached = ConnectivityMgr().IsWiFiStationConnected();
441+
sIsEnabled = ConnectivityMgr().IsWiFiStationEnabled();
442+
sIsAttached = ConnectivityMgr().IsWiFiStationConnected();
443443
#endif /* SL_WIFI */
444444
#if CHIP_ENABLE_OPENTHREAD
445445
// TODO: This is a temporary solution until we can read Thread provisioning status from RAM instead of NVM.
446446
BaseApplication::sIsProvisioned = newState;
447-
sIsEnabled = ConnectivityMgr().IsThreadEnabled();
448-
sIsAttached = ConnectivityMgr().IsThreadAttached();
447+
sIsEnabled = ConnectivityMgr().IsThreadEnabled();
448+
sIsAttached = ConnectivityMgr().IsThreadAttached();
449449
#endif /* CHIP_ENABLE_OPENTHREAD */
450450

451451
ActivateStatusLedPatterns();
@@ -790,7 +790,9 @@ void BaseApplication::ScheduleFactoryReset()
790790
{
791791
Provision::Manager::GetInstance().SetProvisionRequired(true);
792792
}
793-
PlatformMgr().HandleServerShuttingDown(); // HandleServerShuttingDown calls OnShutdown() which is only implemented for the basic information cluster it seems. And triggers and Event flush, which is not relevant when there are no fabrics left
793+
PlatformMgr().HandleServerShuttingDown(); // HandleServerShuttingDown calls OnShutdown() which is only implemented for the
794+
// basic information cluster it seems. And triggers and Event flush, which is not
795+
// relevant when there are no fabrics left
794796
ConfigurationMgr().InitiateFactoryReset();
795797
});
796798
}

examples/platform/silabs/BaseApplication.h

+2-3
Original file line numberDiff line numberDiff line change
@@ -32,10 +32,10 @@
3232
#include <app/util/config.h>
3333
#include <ble/Ble.h>
3434
#include <cmsis_os2.h>
35+
#include <credentials/FabricTable.h>
3536
#include <lib/core/CHIPError.h>
3637
#include <platform/CHIPDeviceEvent.h>
3738
#include <platform/CHIPDeviceLayer.h>
38-
#include <credentials/FabricTable.h>
3939

4040
#include "LEDWidget.h"
4141

@@ -63,8 +63,7 @@
6363
#define APP_ERROR_START_TIMER_FAILED CHIP_APPLICATION_ERROR(0x05)
6464
#define APP_ERROR_STOP_TIMER_FAILED CHIP_APPLICATION_ERROR(0x06)
6565

66-
class BaseApplicationDelegate : public AppDelegate,
67-
public chip::FabricTable::Delegate
66+
class BaseApplicationDelegate : public AppDelegate, public chip::FabricTable::Delegate
6867
{
6968
private:
7069
// AppDelegate

src/platform/OpenThread/GenericThreadStackManagerImpl_OpenThread.hpp

-1
Original file line numberDiff line numberDiff line change
@@ -1144,7 +1144,6 @@ CHIP_ERROR GenericThreadStackManagerImpl_OpenThread<ImplClass>::ConfigureThreadS
11441144
return err;
11451145
}
11461146

1147-
11481147
template <class ImplClass>
11491148
CHIP_ERROR GenericThreadStackManagerImpl_OpenThread<ImplClass>::DoInit(otInstance * otInst)
11501149
{

src/platform/silabs/efr32/ThreadStackManagerImpl_CMSIS.hpp

+4-7
Original file line numberDiff line numberDiff line change
@@ -23,9 +23,9 @@
2323
* GenericThreadStackManagerImpl_FreeRTOS<> template.
2424
*/
2525

26+
#include "../ThreadStackManagerImpl_CMSIS.h"
2627
#include <lib/support/CodeUtils.h>
2728
#include <lib/support/logging/CHIPLogging.h>
28-
#include "../ThreadStackManagerImpl_CMSIS.h"
2929
#include <platform/OpenThread/OpenThreadUtils.h>
3030
#include <platform/ThreadStackManager.h>
3131
#include <platform/internal/CHIPDeviceLayerInternal.h>
@@ -49,8 +49,7 @@ CHIP_ERROR ThreadStackManagerImpl_CMSIS<ImplClass>::_StartThreadTask(void)
4949

5050
template <class ImplClass>
5151
void ThreadStackManagerImpl_CMSIS<ImplClass>::_LockThreadStack(void)
52-
{
53-
}
52+
{}
5453

5554
template <class ImplClass>
5655
bool ThreadStackManagerImpl_CMSIS<ImplClass>::_TryLockThreadStack(void)
@@ -60,8 +59,7 @@ bool ThreadStackManagerImpl_CMSIS<ImplClass>::_TryLockThreadStack(void)
6059

6160
template <class ImplClass>
6261
void ThreadStackManagerImpl_CMSIS<ImplClass>::_UnlockThreadStack(void)
63-
{
64-
}
62+
{}
6563

6664
#if CHIP_DEVICE_CONFIG_ENABLE_THREAD_SRP_CLIENT
6765
template <class ImplClass>
@@ -114,8 +112,7 @@ BaseType_t ThreadStackManagerImpl_CMSIS<ImplClass>::SignalThreadActivityPendingF
114112
template <class ImplClass>
115113
void ThreadStackManagerImpl_CMSIS<ImplClass>::ThreadTaskMain(void * arg)
116114
{
117-
ThreadStackManagerImpl_CMSIS<ImplClass> * self =
118-
static_cast<ThreadStackManagerImpl_CMSIS<ImplClass> *>(arg);
115+
ThreadStackManagerImpl_CMSIS<ImplClass> * self = static_cast<ThreadStackManagerImpl_CMSIS<ImplClass> *>(arg);
119116

120117
ChipLogDetail(DeviceLayer, "Thread task running");
121118

0 commit comments

Comments
 (0)