diff options
author | rbuj <[email protected]> | 2020-07-28 20:04:17 +0200 |
---|---|---|
committer | raveit65 <[email protected]> | 2020-08-28 15:27:55 +0200 |
commit | b6c109c51ea331a20a148f9e715efd2463623d42 (patch) | |
tree | 714947581a582debf07ee9eb519a6b273ebc940b /multiload/linux-proc.c | |
parent | 97cbce5b71f22c5bd435b249a0e9df07880cda7f (diff) | |
download | mate-applets-b6c109c51ea331a20a148f9e715efd2463623d42.tar.bz2 mate-applets-b6c109c51ea331a20a148f9e715efd2463623d42.tar.xz |
multiload: Remove dead function - GetPage
Diffstat (limited to 'multiload/linux-proc.c')
-rw-r--r-- | multiload/linux-proc.c | 48 |
1 files changed, 0 insertions, 48 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], |