aboutsummaryrefslogtreecommitdiffstats
path: root/kernel/sched_stats.h
diff options
context:
space:
mode:
Diffstat (limited to 'kernel/sched_stats.h')
-rw-r--r--kernel/sched_stats.h36
1 files changed, 17 insertions, 19 deletions
diff --git a/kernel/sched_stats.h b/kernel/sched_stats.h
index c20a94dda61e..ef1a7df80ea2 100644
--- a/kernel/sched_stats.h
+++ b/kernel/sched_stats.h
@@ -16,18 +16,18 @@ static int show_schedstat(struct seq_file *seq, void *v)
16 struct rq *rq = cpu_rq(cpu); 16 struct rq *rq = cpu_rq(cpu);
17#ifdef CONFIG_SMP 17#ifdef CONFIG_SMP
18 struct sched_domain *sd; 18 struct sched_domain *sd;
19 int dcnt = 0; 19 int dcount = 0;
20#endif 20#endif
21 21
22 /* runqueue-specific stats */ 22 /* runqueue-specific stats */
23 seq_printf(seq, 23 seq_printf(seq,
24 "cpu%d %lu %lu %lu %lu %lu %lu %lu %lu %lu %llu %llu %lu", 24 "cpu%d %u %u %u %u %u %u %u %u %u %llu %llu %lu",
25 cpu, rq->yld_both_empty, 25 cpu, rq->yld_both_empty,
26 rq->yld_act_empty, rq->yld_exp_empty, rq->yld_cnt, 26 rq->yld_act_empty, rq->yld_exp_empty, rq->yld_count,
27 rq->sched_switch, rq->sched_cnt, rq->sched_goidle, 27 rq->sched_switch, rq->sched_count, rq->sched_goidle,
28 rq->ttwu_cnt, rq->ttwu_local, 28 rq->ttwu_count, rq->ttwu_local,
29 rq->rq_sched_info.cpu_time, 29 rq->rq_sched_info.cpu_time,
30 rq->rq_sched_info.run_delay, rq->rq_sched_info.pcnt); 30 rq->rq_sched_info.run_delay, rq->rq_sched_info.pcount);
31 31
32 seq_printf(seq, "\n"); 32 seq_printf(seq, "\n");
33 33
@@ -39,12 +39,11 @@ static int show_schedstat(struct seq_file *seq, void *v)
39 char mask_str[NR_CPUS]; 39 char mask_str[NR_CPUS];
40 40
41 cpumask_scnprintf(mask_str, NR_CPUS, sd->span); 41 cpumask_scnprintf(mask_str, NR_CPUS, sd->span);
42 seq_printf(seq, "domain%d %s", dcnt++, mask_str); 42 seq_printf(seq, "domain%d %s", dcount++, mask_str);
43 for (itype = CPU_IDLE; itype < CPU_MAX_IDLE_TYPES; 43 for (itype = CPU_IDLE; itype < CPU_MAX_IDLE_TYPES;
44 itype++) { 44 itype++) {
45 seq_printf(seq, " %lu %lu %lu %lu %lu %lu %lu " 45 seq_printf(seq, " %u %u %u %u %u %u %u %u",
46 "%lu", 46 sd->lb_count[itype],
47 sd->lb_cnt[itype],
48 sd->lb_balanced[itype], 47 sd->lb_balanced[itype],
49 sd->lb_failed[itype], 48 sd->lb_failed[itype],
50 sd->lb_imbalance[itype], 49 sd->lb_imbalance[itype],
@@ -53,11 +52,10 @@ static int show_schedstat(struct seq_file *seq, void *v)
53 sd->lb_nobusyq[itype], 52 sd->lb_nobusyq[itype],
54 sd->lb_nobusyg[itype]); 53 sd->lb_nobusyg[itype]);
55 } 54 }
56 seq_printf(seq, " %lu %lu %lu %lu %lu %lu %lu %lu %lu" 55 seq_printf(seq, " %u %u %u %u %u %u %u %u %u %u %u %u\n",
57 " %lu %lu %lu\n", 56 sd->alb_count, sd->alb_failed, sd->alb_pushed,
58 sd->alb_cnt, sd->alb_failed, sd->alb_pushed, 57 sd->sbe_count, sd->sbe_balanced, sd->sbe_pushed,
59 sd->sbe_cnt, sd->sbe_balanced, sd->sbe_pushed, 58 sd->sbf_count, sd->sbf_balanced, sd->sbf_pushed,
60 sd->sbf_cnt, sd->sbf_balanced, sd->sbf_pushed,
61 sd->ttwu_wake_remote, sd->ttwu_move_affine, 59 sd->ttwu_wake_remote, sd->ttwu_move_affine,
62 sd->ttwu_move_balance); 60 sd->ttwu_move_balance);
63 } 61 }
@@ -101,7 +99,7 @@ rq_sched_info_arrive(struct rq *rq, unsigned long long delta)
101{ 99{
102 if (rq) { 100 if (rq) {
103 rq->rq_sched_info.run_delay += delta; 101 rq->rq_sched_info.run_delay += delta;
104 rq->rq_sched_info.pcnt++; 102 rq->rq_sched_info.pcount++;
105 } 103 }
106} 104}
107 105
@@ -129,7 +127,7 @@ rq_sched_info_depart(struct rq *rq, unsigned long long delta)
129# define schedstat_set(var, val) do { } while (0) 127# define schedstat_set(var, val) do { } while (0)
130#endif 128#endif
131 129
132#if defined(CONFIG_SCHEDSTATS) || defined(CONFIG_TASK_DELAY_ACCT) 130#ifdef CONFIG_SCHEDSTATS
133/* 131/*
134 * Called when a process is dequeued from the active array and given 132 * Called when a process is dequeued from the active array and given
135 * the cpu. We should note that with the exception of interactive 133 * the cpu. We should note that with the exception of interactive
@@ -164,7 +162,7 @@ static void sched_info_arrive(struct task_struct *t)
164 sched_info_dequeued(t); 162 sched_info_dequeued(t);
165 t->sched_info.run_delay += delta; 163 t->sched_info.run_delay += delta;
166 t->sched_info.last_arrival = now; 164 t->sched_info.last_arrival = now;
167 t->sched_info.pcnt++; 165 t->sched_info.pcount++;
168 166
169 rq_sched_info_arrive(task_rq(t), delta); 167 rq_sched_info_arrive(task_rq(t), delta);
170} 168}
@@ -233,5 +231,5 @@ sched_info_switch(struct task_struct *prev, struct task_struct *next)
233#else 231#else
234#define sched_info_queued(t) do { } while (0) 232#define sched_info_queued(t) do { } while (0)
235#define sched_info_switch(t, next) do { } while (0) 233#define sched_info_switch(t, next) do { } while (0)
236#endif /* CONFIG_SCHEDSTATS || CONFIG_TASK_DELAY_ACCT */ 234#endif /* CONFIG_SCHEDSTATS */
237 235