From 52e25213825024b8bb446eb26b03bedc9d5c2103 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Sun, 28 Apr 2024 11:00:29 +0200 Subject: Adding upstream version 3.2.2. Signed-off-by: Daniel Baumann --- netbsd/NetBSDProcessList.h | 58 ++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 58 insertions(+) create mode 100644 netbsd/NetBSDProcessList.h (limited to 'netbsd/NetBSDProcessList.h') diff --git a/netbsd/NetBSDProcessList.h b/netbsd/NetBSDProcessList.h new file mode 100644 index 0000000..d228f48 --- /dev/null +++ b/netbsd/NetBSDProcessList.h @@ -0,0 +1,58 @@ +#ifndef HEADER_NetBSDProcessList +#define HEADER_NetBSDProcessList +/* +htop - NetBSDProcessList.h +(C) 2014 Hisham H. Muhammad +(C) 2015 Michael McConville +(C) 2021 Santhosh Raju +(C) 2021 htop dev team +Released under the GNU GPLv2+, see the COPYING file +in the source distribution for its full text. +*/ + +#include +#include +#include + +#include "Hashtable.h" +#include "ProcessList.h" +#include "UsersTable.h" + + +typedef struct CPUData_ { + unsigned long long int totalTime; + unsigned long long int userTime; + unsigned long long int niceTime; + unsigned long long int sysTime; + unsigned long long int sysAllTime; + unsigned long long int spinTime; + unsigned long long int intrTime; + unsigned long long int idleTime; + + unsigned long long int totalPeriod; + unsigned long long int userPeriod; + unsigned long long int nicePeriod; + unsigned long long int sysPeriod; + unsigned long long int sysAllPeriod; + unsigned long long int spinPeriod; + unsigned long long int intrPeriod; + unsigned long long int idlePeriod; + + double frequency; +} CPUData; + +typedef struct NetBSDProcessList_ { + ProcessList super; + kvm_t* kd; + + CPUData* cpuData; +} NetBSDProcessList; + + +ProcessList* ProcessList_new(UsersTable* usersTable, Hashtable* dynamicMeters, Hashtable* dynamicColumns, Hashtable* pidMatchList, uid_t userId); + +void ProcessList_delete(ProcessList* this); + +void ProcessList_goThroughEntries(ProcessList* super, bool pauseProcessUpdate); + +#endif -- cgit v1.2.3