summaryrefslogtreecommitdiff
path: root/overlay/cpu-top.h
diff options
context:
space:
mode:
authorChris Wilson <chris@chris-wilson.co.uk>2013-08-18 15:56:22 +0100
committerChris Wilson <chris@chris-wilson.co.uk>2013-08-18 15:57:47 +0100
commit6a64ee938b90a2d27342aa42ba1d2d90da40dc7b (patch)
tree6394cf98a9b9701805d11415e96facbca5a9287a /overlay/cpu-top.h
parent98572f0446e62eb889f28efe39fc1501e96093c1 (diff)
overlay: Include CPU usage in the overview chart
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Diffstat (limited to 'overlay/cpu-top.h')
-rw-r--r--overlay/cpu-top.h13
1 files changed, 13 insertions, 0 deletions
diff --git a/overlay/cpu-top.h b/overlay/cpu-top.h
new file mode 100644
index 00000000..4687f902
--- /dev/null
+++ b/overlay/cpu-top.h
@@ -0,0 +1,13 @@
+#include <stdint.h>
+
+struct cpu_top {
+ uint8_t busy;
+
+ int count;
+ struct cpu_stat {
+ uint64_t user, nice, sys, idle;
+ uint64_t total;
+ } stat[2];
+};
+
+int cpu_top_update(struct cpu_top *cpu);