Commit d59e0ba1 authored by Peng Hao's avatar Peng Hao Committed by Thomas Gleixner
Browse files

tick/sched : Remove redundant cpu_online() check



can_stop_idle_tick() checks cpu_online() twice. The first check leaves the
function when the CPU is not online, so the second check it
redundant. Remove it.

Signed-off-by: default avatarPeng Hao <peng.hao2@zte.com.cn>
Signed-off-by: default avatarThomas Gleixner <tglx@linutronix.de>
Cc: fweisbec@gmail.com
Link: https://lkml.kernel.org/r/1539099815-2943-1-git-send-email-penghao122@sina.com.cn
parent 2f6affe3
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -885,7 +885,7 @@ static bool can_stop_idle_tick(int cpu, struct tick_sched *ts)
	if (need_resched())
		return false;

	if (unlikely(local_softirq_pending() && cpu_online(cpu))) {
	if (unlikely(local_softirq_pending())) {
		static int ratelimit;

		if (ratelimit < 10 &&