summaryrefslogtreecommitdiff
path: root/multiload
diff options
context:
space:
mode:
Diffstat (limited to 'multiload')
-rw-r--r--multiload/linux-proc.c48
-rw-r--r--multiload/linux-proc.h3
2 files changed, 0 insertions, 51 deletions
diff --git a/multiload/linux-proc.c b/multiload/linux-proc.c
index ea417421..0a011971 100644
--- a/multiload/linux-proc.c
+++ b/multiload/linux-proc.c
@@ -208,54 +208,6 @@ GetDiskLoad (int Maximum,
data [diskload_free] = Maximum - (data [0] + data[1]);
}
-#if 0
-void
-GetPage (int Maximum, int data [3], LoadGraph *g)
-{
- static int max = 100; /* guess at maximum page rate (= in + out) */
- static u_int64_t lastin = 0;
- static u_int64_t lastout = 0;
- int in, out, idle;
-
- glibtop_swap swap;
-
- glibtop_get_swap (&swap);
-
- assert ((swap.flags & needed_page_flags) == needed_page_flags);
-
- if ((lastin > 0) && (lastin < swap.pagein)) {
- in = swap.pagein - lastin;
- }
- else {
- in = 0;
- }
- lastin = swap.pagein;
-
- if ((lastout > 0) && (lastout < swap.pageout)) {
- out = swap.pageout - lastout;
- }
- else {
- out = 0;
- }
- lastout = swap.pageout;
-
- if ((in + out) > max) {
- /* Maximum page rate has increased. Change the scale without
- any indication whatsoever to the user (not a nice thing to
- do). */
- max = in + out;
- }
-
- in = rint (Maximum * ((float)in / max));
- out = rint (Maximum * ((float)out / max));
- idle = Maximum - in - out;
-
- data [0] = in;
- data [1] = out;
- data [2] = idle;
-}
-#endif /* 0 */
-
void
GetMemory (int Maximum,
int data [memload_n],
diff --git a/multiload/linux-proc.h b/multiload/linux-proc.h
index b64a7e8a..0aba1a0e 100644
--- a/multiload/linux-proc.h
+++ b/multiload/linux-proc.h
@@ -5,9 +5,6 @@
G_GNUC_INTERNAL void GetLoad (int Maximum, int data [cpuload_n], LoadGraph *g);
G_GNUC_INTERNAL void GetDiskLoad (int Maximum, int data [diskload_n], LoadGraph *g);
-#if 0
-G_GNUC_INTERNAL void GetPage (int Maximum, int data [3], LoadGraph *g);
-#endif /* 0 */
G_GNUC_INTERNAL void GetMemory (int Maximum, int data [memload_n], LoadGraph *g);
G_GNUC_INTERNAL void GetSwap (int Maximum, int data [swapload_n], LoadGraph *g);
G_GNUC_INTERNAL void GetLoadAvg (int Maximum, int data [2], LoadGraph *g);