summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorDenis Vlasenko2008-09-25 10:48:06 +0000
committerDenis Vlasenko2008-09-25 10:48:06 +0000
commit17e7f04c8d144e0e0598464806dcb111ed5386d7 (patch)
tree002284cda156b2516c1d3a67352288741d7cd2e5 /include
parente0bcba18eb9c185cefbef2ef05b846f735bd133a (diff)
downloadbusybox-17e7f04c8d144e0e0598464806dcb111ed5386d7.zip
busybox-17e7f04c8d144e0e0598464806dcb111ed5386d7.tar.gz
top: optional SMP support by Vineet Gupta (vineetg76 AT gmail.com)
Diffstat (limited to 'include')
-rw-r--r--include/libbb.h15
1 files changed, 11 insertions, 4 deletions
diff --git a/include/libbb.h b/include/libbb.h
index 3b4715e..951ff2f 100644
--- a/include/libbb.h
+++ b/include/libbb.h
@@ -1225,6 +1225,9 @@ typedef struct procps_status_t {
* by link target or interpreter name) */
char comm[COMM_LEN];
/* user/group? - use passwd/group parsing functions */
+#if ENABLE_FEATURE_TOP_SMP_PROCESS
+ int last_seen_on_cpu;
+#endif
} procps_status_t;
enum {
PSSCAN_PID = 1 << 0,
@@ -1246,12 +1249,16 @@ enum {
PSSCAN_ARGVN = (1 << 16) * (ENABLE_PGREP || ENABLE_PKILL || ENABLE_PIDOF),
USE_SELINUX(PSSCAN_CONTEXT = 1 << 17,)
PSSCAN_START_TIME = 1 << 18,
+ PSSCAN_CPU = 1 << 19,
/* These are all retrieved from proc/NN/stat in one go: */
PSSCAN_STAT = PSSCAN_PPID | PSSCAN_PGID | PSSCAN_SID
- | PSSCAN_COMM | PSSCAN_STATE
- | PSSCAN_VSZ | PSSCAN_RSS
- | PSSCAN_STIME | PSSCAN_UTIME | PSSCAN_START_TIME
- | PSSCAN_TTY,
+ /**/ | PSSCAN_COMM | PSSCAN_STATE
+ /**/ | PSSCAN_VSZ | PSSCAN_RSS
+ /**/ | PSSCAN_STIME | PSSCAN_UTIME | PSSCAN_START_TIME
+ /**/ | PSSCAN_TTY
+#if ENABLE_FEATURE_TOP_SMP_PROCESS
+ /**/ | PSSCAN_CPU
+#endif
};
//procps_status_t* alloc_procps_scan(void) FAST_FUNC;
void free_procps_scan(procps_status_t* sp) FAST_FUNC;