Skip to content

Commit

Permalink
Remove unused functions in DiagnosticDataProviderImpl (#18574)
Browse files Browse the repository at this point in the history
  • Loading branch information
yufengwangca authored and pull[bot] committed Nov 8, 2023
1 parent e26750a commit e14e16f
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 15 deletions.
6 changes: 0 additions & 6 deletions src/include/platform/DiagnosticDataProvider.h
Original file line number Diff line number Diff line change
Expand Up @@ -179,7 +179,6 @@ class DiagnosticDataProvider
virtual CHIP_ERROR GetCurrentHeapFree(uint64_t & currentHeapFree);
virtual CHIP_ERROR GetCurrentHeapUsed(uint64_t & currentHeapUsed);
virtual CHIP_ERROR GetCurrentHeapHighWatermark(uint64_t & currentHeapHighWatermark);
virtual CHIP_ERROR SetCurrentHeapHighWatermark(uint64_t heapHighWatermark);
virtual CHIP_ERROR ResetWatermarks();

/*
Expand Down Expand Up @@ -268,11 +267,6 @@ inline CHIP_ERROR DiagnosticDataProvider::GetCurrentHeapHighWatermark(uint64_t &
return CHIP_ERROR_UNSUPPORTED_CHIP_FEATURE;
}

inline CHIP_ERROR DiagnosticDataProvider::SetCurrentHeapHighWatermark(uint64_t heapHighWatermark)
{
return CHIP_ERROR_UNSUPPORTED_CHIP_FEATURE;
}

inline CHIP_ERROR DiagnosticDataProvider::ResetWatermarks()
{
return CHIP_ERROR_UNSUPPORTED_CHIP_FEATURE;
Expand Down
8 changes: 0 additions & 8 deletions src/platform/Linux/DiagnosticDataProviderImpl.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -266,14 +266,6 @@ CHIP_ERROR DiagnosticDataProviderImpl::GetCurrentHeapHighWatermark(uint64_t & cu
#endif
}

CHIP_ERROR DiagnosticDataProviderImpl::SetCurrentHeapHighWatermark(uint64_t heapHighWatermark)
{
// On Linux, the write operation is non-op since we always rely on the mallinfo system
// function to get the current heap memory.

return CHIP_NO_ERROR;
}

CHIP_ERROR DiagnosticDataProviderImpl::ResetWatermarks()
{
// If implemented, the server SHALL set the value of the CurrentHeapHighWatermark attribute to the
Expand Down
1 change: 0 additions & 1 deletion src/platform/Linux/DiagnosticDataProviderImpl.h
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,6 @@ class DiagnosticDataProviderImpl : public DiagnosticDataProvider
CHIP_ERROR GetCurrentHeapUsed(uint64_t & currentHeapUsed) override;
CHIP_ERROR GetCurrentHeapHighWatermark(uint64_t & currentHeapHighWatermark) override;
CHIP_ERROR GetThreadMetrics(ThreadMetrics ** threadMetricsOut) override;
CHIP_ERROR SetCurrentHeapHighWatermark(uint64_t heapHighWatermark) override;
CHIP_ERROR ResetWatermarks() override;
void ReleaseThreadMetrics(ThreadMetrics * threadMetrics) override;

Expand Down

0 comments on commit e14e16f

Please sign in to comment.