diff options
Diffstat (limited to 'kernel/sched_debug.c')
-rw-r--r-- | kernel/sched_debug.c | 37 |
1 files changed, 36 insertions, 1 deletions
diff --git a/kernel/sched_debug.c b/kernel/sched_debug.c index d25cefe3f0eb..3625a6598699 100644 --- a/kernel/sched_debug.c +++ b/kernel/sched_debug.c | |||
@@ -53,6 +53,40 @@ static unsigned long nsec_low(unsigned long long nsec) | |||
53 | 53 | ||
54 | #define SPLIT_NS(x) nsec_high(x), nsec_low(x) | 54 | #define SPLIT_NS(x) nsec_high(x), nsec_low(x) |
55 | 55 | ||
56 | #ifdef CONFIG_FAIR_GROUP_SCHED | ||
57 | static void print_cfs_group_stats(struct seq_file *m, int cpu, | ||
58 | struct task_group *tg) | ||
59 | { | ||
60 | struct sched_entity *se = tg->se[cpu]; | ||
61 | if (!se) | ||
62 | return; | ||
63 | |||
64 | #define P(F) \ | ||
65 | SEQ_printf(m, " .%-30s: %lld\n", #F, (long long)F) | ||
66 | #define PN(F) \ | ||
67 | SEQ_printf(m, " .%-30s: %lld.%06ld\n", #F, SPLIT_NS((long long)F)) | ||
68 | |||
69 | PN(se->exec_start); | ||
70 | PN(se->vruntime); | ||
71 | PN(se->sum_exec_runtime); | ||
72 | #ifdef CONFIG_SCHEDSTATS | ||
73 | PN(se->wait_start); | ||
74 | PN(se->sleep_start); | ||
75 | PN(se->block_start); | ||
76 | PN(se->sleep_max); | ||
77 | PN(se->block_max); | ||
78 | PN(se->exec_max); | ||
79 | PN(se->slice_max); | ||
80 | PN(se->wait_max); | ||
81 | PN(se->wait_sum); | ||
82 | P(se->wait_count); | ||
83 | #endif | ||
84 | P(se->load.weight); | ||
85 | #undef PN | ||
86 | #undef P | ||
87 | } | ||
88 | #endif | ||
89 | |||
56 | static void | 90 | static void |
57 | print_task(struct seq_file *m, struct rq *rq, struct task_struct *p) | 91 | print_task(struct seq_file *m, struct rq *rq, struct task_struct *p) |
58 | { | 92 | { |
@@ -181,6 +215,7 @@ void print_cfs_rq(struct seq_file *m, int cpu, struct cfs_rq *cfs_rq) | |||
181 | #ifdef CONFIG_SMP | 215 | #ifdef CONFIG_SMP |
182 | SEQ_printf(m, " .%-30s: %lu\n", "shares", cfs_rq->shares); | 216 | SEQ_printf(m, " .%-30s: %lu\n", "shares", cfs_rq->shares); |
183 | #endif | 217 | #endif |
218 | print_cfs_group_stats(m, cpu, cfs_rq->tg); | ||
184 | #endif | 219 | #endif |
185 | } | 220 | } |
186 | 221 | ||
@@ -261,7 +296,7 @@ static int sched_debug_show(struct seq_file *m, void *v) | |||
261 | u64 now = ktime_to_ns(ktime_get()); | 296 | u64 now = ktime_to_ns(ktime_get()); |
262 | int cpu; | 297 | int cpu; |
263 | 298 | ||
264 | SEQ_printf(m, "Sched Debug Version: v0.07, %s %.*s\n", | 299 | SEQ_printf(m, "Sched Debug Version: v0.08, %s %.*s\n", |
265 | init_utsname()->release, | 300 | init_utsname()->release, |
266 | (int)strcspn(init_utsname()->version, " "), | 301 | (int)strcspn(init_utsname()->version, " "), |
267 | init_utsname()->version); | 302 | init_utsname()->version); |