Skip to content

Commit 9d9af23

Browse files
committed
sched/smp: Use the SMP version of schedstats
Simplify the scheduler by making CONFIG_SMP=y schedstats debugging output unconditional. Signed-off-by: Ingo Molnar <mingo@kernel.org> Acked-by: Peter Zijlstra <peterz@infradead.org> Cc: Dietmar Eggemann <dietmar.eggemann@arm.com> Cc: Juri Lelli <juri.lelli@redhat.com> Cc: Linus Torvalds <torvalds@linux-foundation.org> Cc: Mel Gorman <mgorman@suse.de> Cc: Sebastian Andrzej Siewior <bigeasy@linutronix.de> Cc: Shrikanth Hegde <sshegde@linux.ibm.com> Cc: Steven Rostedt <rostedt@goodmis.org> Cc: Valentin Schneider <vschneid@redhat.com> Cc: Vincent Guittot <vincent.guittot@linaro.org> Link: https://lore.kernel.org/r/20250528080924.2273858-32-mingo@kernel.org
1 parent 02fb885 commit 9d9af23

1 file changed

Lines changed: 0 additions & 4 deletions

File tree

kernel/sched/stats.c

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -115,10 +115,8 @@ static int show_schedstat(struct seq_file *seq, void *v)
115115
seq_printf(seq, "timestamp %lu\n", jiffies);
116116
} else {
117117
struct rq *rq;
118-
#ifdef CONFIG_SMP
119118
struct sched_domain *sd;
120119
int dcount = 0;
121-
#endif
122120
cpu = (unsigned long)(v - 2);
123121
rq = cpu_rq(cpu);
124122

@@ -133,7 +131,6 @@ static int show_schedstat(struct seq_file *seq, void *v)
133131

134132
seq_printf(seq, "\n");
135133

136-
#ifdef CONFIG_SMP
137134
/* domain-specific stats */
138135
rcu_read_lock();
139136
for_each_domain(cpu, sd) {
@@ -164,7 +161,6 @@ static int show_schedstat(struct seq_file *seq, void *v)
164161
sd->ttwu_move_balance);
165162
}
166163
rcu_read_unlock();
167-
#endif /* CONFIG_SMP */
168164
}
169165
return 0;
170166
}

0 commit comments

Comments
 (0)