diff options
author | Peng Hao <peng.hao2@zte.com.cn> | 2018-10-09 11:43:35 -0400 |
---|---|---|
committer | Thomas Gleixner <tglx@linutronix.de> | 2018-10-10 11:47:20 +0200 |
commit | d59e0ba19481c0046d2ea2bd0e5344eeaf45aace (patch) | |
tree | 98351cd32bc4160eff3da32503e57cddb67c09eb /kernel/time | |
parent | 2f6affe35c1d79e3524a6475ea2267535a252258 (diff) |
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: Peng Hao <peng.hao2@zte.com.cn>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Cc: fweisbec@gmail.com
Link: https://lkml.kernel.org/r/1539099815-2943-1-git-send-email-penghao122@sina.com.cn
Diffstat (limited to 'kernel/time')
-rw-r--r-- | kernel/time/tick-sched.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/kernel/time/tick-sched.c b/kernel/time/tick-sched.c index 5b33e2f5c0ed..69e673b88474 100644 --- a/kernel/time/tick-sched.c +++ b/kernel/time/tick-sched.c @@ -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 && |