Skip to content

Commit

Permalink
Rename Deinit to Shutdown
Browse files Browse the repository at this point in the history
  • Loading branch information
jadhavrohit924 committed Jan 14, 2025
1 parent 5b23629 commit f150fb9
Show file tree
Hide file tree
Showing 23 changed files with 27 additions and 27 deletions.
4 changes: 2 additions & 2 deletions examples/all-clusters-app/esp32/main/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -154,11 +154,11 @@ static void Shutdown(TimerHandle_t xTimer)
DeviceLayer::StackLock lock;

Esp32AppServer::Shutdown();
ESPOpenThreadDeinit();
ESPOpenThreadShutdown();
GetAppTask().StopAppTask();

#if CHIP_DEVICE_CONFIG_ENABLE_WIFI
if (DeviceLayer::Internal::ESP32Utils::DeinitWiFiStack() != CHIP_NO_ERROR)
if (DeviceLayer::Internal::ESP32Utils::ShutdownWiFiStack() != CHIP_NO_ERROR)
{
ESP_LOGE(TAG, "Failed to deinitialize the Wi-Fi stack");
return;
Expand Down
4 changes: 2 additions & 2 deletions examples/platform/esp32/common/Esp32ThreadInit.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -99,13 +99,13 @@ void ESPOpenThreadInit()
#endif // CHIP_DEVICE_CONFIG_ENABLE_THREAD
}

void ESPOpenThreadDeinit()
void ESPOpenThreadShutdown()
{
#if CHIP_DEVICE_CONFIG_ENABLE_THREAD
#if defined(CONFIG_OPENTHREAD_BORDER_ROUTER) && defined(CONFIG_AUTO_UPDATE_RCP)
openthread_deinit_br_rcp();
#endif // CONFIG_OPENTHREAD_BORDER_ROUTER && CONFIG_AUTO_UPDATE_RCP
ThreadStackMgr().StopThreadStack();
ThreadStackMgr().DeinitThreadStack();
ThreadStackMgr().ShutdownThreadStack();
#endif // CHIP_DEVICE_CONFIG_ENABLE_THREAD
}
2 changes: 1 addition & 1 deletion examples/platform/esp32/common/Esp32ThreadInit.h
Original file line number Diff line number Diff line change
Expand Up @@ -98,4 +98,4 @@
#endif // CONFIG_OPENTHREAD_ENABLED

void ESPOpenThreadInit();
void ESPOpenThreadDeinit();
void ESPOpenThreadShutdown();
6 changes: 3 additions & 3 deletions src/include/platform/ThreadStackManager.h
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ class ThreadStackManager
// ===== Members that define the public interface of the ThreadStackManager

CHIP_ERROR InitThreadStack();
void DeinitThreadStack();
void ShutdownThreadStack();
void ProcessThreadActivity();
CHIP_ERROR StartThreadTask();
void StopThreadStack();
Expand Down Expand Up @@ -243,9 +243,9 @@ inline CHIP_ERROR ThreadStackManager::InitThreadStack()
return static_cast<ImplClass *>(this)->_InitThreadStack();
}

inline void ThreadStackManager::DeinitThreadStack()
inline void ThreadStackManager::ShutdownThreadStack()
{
static_cast<ImplClass *>(this)->_DeinitThreadStack();
static_cast<ImplClass *>(this)->_ShutdownThreadStack();
}

inline void ThreadStackManager::ProcessThreadActivity()
Expand Down
2 changes: 1 addition & 1 deletion src/platform/ESP32/ESP32Utils.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -370,7 +370,7 @@ CHIP_ERROR ESP32Utils::InitWiFiStack(void)
return CHIP_NO_ERROR;
}

CHIP_ERROR ESP32Utils::DeinitWiFiStack(void)
CHIP_ERROR ESP32Utils::ShutdownWiFiStack(void)
{
esp_err_t err = esp_event_handler_unregister(WIFI_EVENT, ESP_EVENT_ANY_ID, PlatformManagerImpl::HandleESPSystemEvent);
if (err != ESP_OK)
Expand Down
2 changes: 1 addition & 1 deletion src/platform/ESP32/ESP32Utils.h
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ class ESP32Utils
static CHIP_ERROR SetWiFiStationProvision(const Internal::DeviceNetworkInfo & netInfo);
static CHIP_ERROR ClearWiFiStationProvision(void);
static CHIP_ERROR InitWiFiStack(void);
static CHIP_ERROR DeinitWiFiStack(void);
static CHIP_ERROR ShutdownWiFiStack(void);

static CHIP_ERROR MapError(esp_err_t error);
static void RegisterESP32ErrorFormatter();
Expand Down
2 changes: 1 addition & 1 deletion src/platform/ESP32/ThreadStackManagerImpl.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ CHIP_ERROR ThreadStackManagerImpl::_InitThreadStack()
return err;
}

void ThreadStackManagerImpl::_DeinitThreadStack()
void ThreadStackManagerImpl::_ShutdownThreadStack()
{
openthread_deinit_stack();
}
Expand Down
2 changes: 1 addition & 1 deletion src/platform/ESP32/ThreadStackManagerImpl.h
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ class ThreadStackManagerImpl final : public ThreadStackManager,

public:
CHIP_ERROR _InitThreadStack();
void _DeinitThreadStack();
void _ShutdownThreadStack();

protected:
CHIP_ERROR _StartThreadTask();
Expand Down
2 changes: 1 addition & 1 deletion src/platform/Infineon/CYW30739/ThreadStackManagerImpl.h
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ class ThreadStackManagerImpl final : public ThreadStackManager,
public:
// ===== Methods that implement the ThreadStackManager abstract interface.
CHIP_ERROR _InitThreadStack();
void _DeinitThreadStack() {}
void _ShutdownThreadStack() {}

void SignalThreadActivityPending();
void SignalThreadActivityPendingFromISR();
Expand Down
2 changes: 1 addition & 1 deletion src/platform/Linux/ThreadStackManagerImpl.h
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ class ThreadStackManagerImpl : public ThreadStackManager
}

CHIP_ERROR _InitThreadStack();
void _DeinitThreadStack() {}
void _ShutdownThreadStack() {}
void _ProcessThreadActivity();

CHIP_ERROR _StartThreadTask() { return CHIP_NO_ERROR; } // Intentionally left blank
Expand Down
2 changes: 1 addition & 1 deletion src/platform/NuttX/ThreadStackManagerImpl.h
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ class ThreadStackManagerImpl : public ThreadStackManager
}

CHIP_ERROR _InitThreadStack();
void _DeinitThreadStack() {}
void _ShutdownThreadStack() {}
void _ProcessThreadActivity();

CHIP_ERROR _StartThreadTask() { return CHIP_NO_ERROR; } // Intentionally left blank
Expand Down
2 changes: 1 addition & 1 deletion src/platform/Tizen/ThreadStackManagerImpl.h
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ class ThreadStackManagerImpl : public ThreadStackManager
ThreadStackManagerImpl();

CHIP_ERROR _InitThreadStack();
void _DeinitThreadStack() {}
void _ShutdownThreadStack() {}
void _ProcessThreadActivity();

CHIP_ERROR _StartThreadTask() { return CHIP_NO_ERROR; } // Intentionally left blank
Expand Down
2 changes: 1 addition & 1 deletion src/platform/Zephyr/ThreadStackManagerImpl.h
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ class ThreadStackManagerImpl final : public ThreadStackManager,
public:
// ===== Methods that implement the ThreadStackManager abstract interface.
CHIP_ERROR _InitThreadStack();
void _DeinitThreadStack() {}
void _ShutdownThreadStack() {}

protected:
// ===== Methods that implement the ThreadStackManager abstract interface.
Expand Down
2 changes: 1 addition & 1 deletion src/platform/bouffalolab/common/ThreadStackManagerImpl.h
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ class ThreadStackManagerImpl final : public ThreadStackManager,
// ===== Methods that implement the ThreadStackManager abstract interface.

CHIP_ERROR _InitThreadStack(void);
void _DeinitThreadStack() {}
void _ShutdownThreadStack() {}
void _StopThreadStack() {}

// ===== Members for internal use by the following friends.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ class ThreadStackManagerImpl final : public ThreadStackManager,
// ===== Methods that implement the ThreadStackManager abstract interface.

CHIP_ERROR _InitThreadStack(void);
void _DeinitThreadStack() {}
void _ShutdownThreadStack() {}
void _StopThreadStack() {}

// ===== Members for internal use by the following friends.
Expand Down
2 changes: 1 addition & 1 deletion src/platform/nxp/common/ThreadStackManagerImpl.h
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ class ThreadStackManagerImpl final : public ThreadStackManager,
protected:
// ===== Methods that implement the ThreadStackManager abstract interface.
CHIP_ERROR _InitThreadStack(void);
void _DeinitThreadStack() {}
void _ShutdownThreadStack() {}
void _StopThreadStack() {}

private:
Expand Down
2 changes: 1 addition & 1 deletion src/platform/nxp/k32w0/ThreadStackManagerImpl.h
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ class ThreadStackManagerImpl final : public ThreadStackManager,
// ===== Methods that implement the ThreadStackManager abstract interface.

CHIP_ERROR _InitThreadStack(void);
void _DeinitThreadStack() {}
void _ShutdownThreadStack() {}
void _StopThreadStack() {}

// ===== Members for internal use by the following friends.
Expand Down
2 changes: 1 addition & 1 deletion src/platform/nxp/mcxw71_k32w1/ThreadStackManagerImpl.h
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ class ThreadStackManagerImpl final : public ThreadStackManager,
// ===== Methods that implement the ThreadStackManager abstract interface.

CHIP_ERROR _InitThreadStack(void);
void _DeinitThreadStack() {}
void _ShutdownThreadStack() {}
void _StopThreadStack() {}

// ===== Members for internal use by the following friends.
Expand Down
2 changes: 1 addition & 1 deletion src/platform/qpg/ThreadStackManagerImpl.h
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ class ThreadStackManagerImpl final : public ThreadStackManager,
// ===== Methods that implement the ThreadStackManager abstract interface.

CHIP_ERROR _InitThreadStack(void);
void _DeinitThreadStack() {}
void _ShutdownThreadStack() {}
void _StopThreadStack() {}

// ===== Members for internal use by the following friends.
Expand Down
2 changes: 1 addition & 1 deletion src/platform/silabs/ThreadStackManagerImpl.h
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@ class ThreadStackManagerImpl final : public ThreadStackManager,
// ===== Methods that implement the ThreadStackManager abstract interface.

CHIP_ERROR _InitThreadStack(void);
void _DeinitThreadStack() {}
void _ShutdownThreadStack() {}
CHIP_ERROR _StartThreadTask(void);
void _StopThreadStack() {}
void _LockThreadStack(void);
Expand Down
2 changes: 1 addition & 1 deletion src/platform/stm32/ThreadStackManagerImpl.h
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ class ThreadStackManagerImpl final : public ThreadStackManager,
// ===== Methods that implement the ThreadStackManager abstract interface.

CHIP_ERROR _InitThreadStack(void);
void _DeinitThreadStack() {}
void _ShutdownThreadStack() {}

// ===== Members for internal use by the following friends.

Expand Down
2 changes: 1 addition & 1 deletion src/platform/telink/ThreadStackManagerImpl.h
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ class ThreadStackManagerImpl final : public ThreadStackManager,
public:
// ===== Methods that implement the ThreadStackManager abstract interface.
CHIP_ERROR _InitThreadStack();
void _DeinitThreadStack() {}
void _ShutdownThreadStack() {}
void SetRadioBlocked(bool state) { mRadioBlocked = state; }
bool IsReadyToAttach(void) const { return mReadyToAttach; }
void Finalize(void);
Expand Down
2 changes: 1 addition & 1 deletion src/platform/webos/ThreadStackManagerImpl.h
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ class ThreadStackManagerImpl : public ThreadStackManager
}

CHIP_ERROR _InitThreadStack();
void _DeinitThreadStack() {}
void _ShutdownThreadStack() {}
void _ProcessThreadActivity();

CHIP_ERROR _StartThreadTask() { return CHIP_NO_ERROR; } // Intentionally left blank
Expand Down

0 comments on commit f150fb9

Please sign in to comment.