From 11d2206f40dd1680923ccae6e421a494c2af0992 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Christian=20G=C3=B6ttsche?= Date: Sat, 12 Jun 2021 22:04:37 +0200 Subject: Add ProcessList_isCPUonline --- pcp/PCPProcessList.c | 9 +++++++++ pcp/PCPProcessList.h | 2 ++ 2 files changed, 11 insertions(+) (limited to 'pcp') diff --git a/pcp/PCPProcessList.c b/pcp/PCPProcessList.c index a27bd474..be91ca47 100644 --- a/pcp/PCPProcessList.c +++ b/pcp/PCPProcessList.c @@ -675,3 +675,12 @@ void ProcessList_goThroughEntries(ProcessList* super, bool pauseProcessUpdate) { double period = (this->timestamp - sample) * 100; PCPProcessList_updateProcesses(this, period, ×tamp); } + +bool ProcessList_isCPUonline(const ProcessList* super, unsigned int id) { + assert(id < super->existingCPUs); + + // TODO: support offline CPUs and hot swapping + (void) super; (void) id; + + return true; +} diff --git a/pcp/PCPProcessList.h b/pcp/PCPProcessList.h index f1784904..7f0f6fe4 100644 --- a/pcp/PCPProcessList.h +++ b/pcp/PCPProcessList.h @@ -69,4 +69,6 @@ void ProcessList_delete(ProcessList* pl); void ProcessList_goThroughEntries(ProcessList* super, bool pauseProcessUpdate); +bool ProcessList_isCPUonline(const ProcessList* super, unsigned int id); + #endif -- cgit v1.2.3