summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorJuri Lelli <juri.lelli@arm.com>2015-11-09 12:07:48 +0000
committerLeo Yan <leo.yan@linaro.org>2016-05-10 16:53:25 +0800
commite5a25996d3a3f46f3abee77f868b922903f5f60e (patch)
treef6c513ed741f030f05b9691899493ee5430e6466 /include
parent8017fd7418dc34d55d0e8bfc83e6c0ec10909c58 (diff)
DEBUG: sched: add tracepoint for CPU load/util signals
Signed-off-by: Juri Lelli <juri.lelli@arm.com>
Diffstat (limited to 'include')
-rw-r--r--include/trace/events/sched.h25
1 files changed, 25 insertions, 0 deletions
diff --git a/include/trace/events/sched.h b/include/trace/events/sched.h
index 99f3e648c197..f58760c2f712 100644
--- a/include/trace/events/sched.h
+++ b/include/trace/events/sched.h
@@ -629,6 +629,31 @@ TRACE_EVENT(sched_load_avg_task,
(u32)__entry->util_sum,
(u32)__entry->period_contrib)
);
+
+/*
+ * Tracepoint for accounting sched averages for cpus.
+ */
+TRACE_EVENT(sched_load_avg_cpu,
+
+ TP_PROTO(int cpu, struct cfs_rq *cfs_rq),
+
+ TP_ARGS(cpu, cfs_rq),
+
+ TP_STRUCT__entry(
+ __field( int, cpu )
+ __field( unsigned long, load_avg )
+ __field( unsigned long, util_avg )
+ ),
+
+ TP_fast_assign(
+ __entry->cpu = cpu;
+ __entry->load_avg = cfs_rq->avg.load_avg;
+ __entry->util_avg = cfs_rq->avg.util_avg;
+ ),
+
+ TP_printk("cpu=%d load_avg=%lu util_avg=%lu",
+ __entry->cpu, __entry->load_avg, __entry->util_avg)
+);
#endif /* _TRACE_SCHED_H */
/* This part must be outside protection */