diff options
author | Eugene V. Lyubimkin <jackyf@debian.org> | 2011-11-26 15:58:33 +0200 |
---|---|---|
committer | Daniel Lange <DLange@git.local> | 2016-04-11 13:00:30 +0200 |
commit | c65eb8be811f59b55d64d9e7654c33708de79ad9 (patch) | |
tree | ee6e542b988263c49f0e1200d6aa5aa635667fe8 /Process.h | |
parent | 38174fffd79f54a8be7642bf170a2320b29e8063 (diff) | |
parent | eaf11cc12a1aa4b050a8a1e7ea3770d3d9c81e95 (diff) | |
download | debian_htop-debian/1.0-1.tar.gz debian_htop-debian/1.0-1.tar.bz2 debian_htop-debian/1.0-1.zip |
Imported Debian patch 1.0-1debian/1.0-1
Diffstat (limited to 'Process.h')
-rw-r--r-- | Process.h | 33 |
1 files changed, 22 insertions, 11 deletions
@@ -4,17 +4,17 @@ #define HEADER_Process /* htop - Process.h -(C) 2004-2010 Hisham H. Muhammad +(C) 2004-2011 Hisham H. Muhammad Released under the GNU GPL, see the COPYING file in the source distribution for its full text. */ -#define _GNU_SOURCE #include "ProcessList.h" #include "Object.h" #include "CRT.h" #include "String.h" #include "RichString.h" +#include "Affinity.h" #include "debug.h" @@ -32,8 +32,8 @@ in the source distribution for its full text. #include <sched.h> #include <time.h> -#ifdef HAVE_PLPA -#include <plpa.h> +#ifdef HAVE_LIBHWLOC +#include <hwloc/linux.h> #endif // This works only with glibc 2.1+. On earlier versions @@ -105,10 +105,10 @@ typedef struct Process_ { unsigned long int majflt; unsigned long int cmajflt; #endif - unsigned long int utime; - unsigned long int stime; - long int cutime; - long int cstime; + unsigned long long int utime; + unsigned long long int stime; + unsigned long long int cutime; + unsigned long long int cstime; long int priority; long int nice; long int nlwp; @@ -181,6 +181,9 @@ extern const char *Process_fieldNames[]; extern const char *Process_fieldTitles[]; + +void Process_getMaxPid(); + #define ONE_K 1024 #define ONE_M (ONE_K * ONE_K) #define ONE_G (ONE_M * ONE_K) @@ -193,10 +196,18 @@ void Process_toggleTag(Process* this); bool Process_setPriority(Process* this, int priority); -#ifdef HAVE_PLPA -unsigned long Process_getAffinity(Process* this); +#ifdef HAVE_LIBHWLOC + +Affinity* Process_getAffinity(Process* this); + +bool Process_setAffinity(Process* this, Affinity* affinity); + +#elif HAVE_NATIVE_AFFINITY + +Affinity* Process_getAffinity(Process* this); + +bool Process_setAffinity(Process* this, Affinity* affinity); -bool Process_setAffinity(Process* this, unsigned long mask); #endif void Process_sendSignal(Process* this, int sgn); |