[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <157950409950.396.10173546303615983871.tip-bot2@tip-bot2>
Date: Mon, 20 Jan 2020 07:08:19 -0000
From: "tip-bot2 for Viresh Kumar" <tip-bot2@...utronix.de>
To: linux-tip-commits@...r.kernel.org
Cc: Stephen Rothwell <sfr@...b.auug.org.au>,
Viresh Kumar <viresh.kumar@...aro.org>,
Ingo Molnar <mingo@...nel.org>,
Juri Lelli <juri.lelli@...hat.com>,
Vincent Guittot <vincent.guittot@...aro.org>,
Dietmar Eggemann <dietmar.eggemann@....com>,
x86 <x86@...nel.org>, LKML <linux-kernel@...r.kernel.org>
Subject: [tip: sched/core] sched/fair: Define sched_idle_cpu() only for SMP
configurations
The following commit has been merged into the sched/core branch of tip:
Commit-ID: afa70d941f663c69c9a64ec1021bbcfa82f0e54a
Gitweb: https://git.kernel.org/tip/afa70d941f663c69c9a64ec1021bbcfa82f0e54a
Author: Viresh Kumar <viresh.kumar@...aro.org>
AuthorDate: Mon, 20 Jan 2020 11:29:05 +05:30
Committer: Ingo Molnar <mingo@...nel.org>
CommitterDate: Mon, 20 Jan 2020 08:03:39 +01:00
sched/fair: Define sched_idle_cpu() only for SMP configurations
sched_idle_cpu() isn't used for non SMP configuration and with a recent
change, we have started getting following warning:
kernel/sched/fair.c:5221:12: warning: ‘sched_idle_cpu’ defined but not used [-Wunused-function]
Fix that by defining sched_idle_cpu() only for SMP configurations.
Fixes: 323af6deaf70 ("sched/fair: Load balance aggressively for SCHED_IDLE CPUs")
Reported-by: Stephen Rothwell <sfr@...b.auug.org.au>
Signed-off-by: Viresh Kumar <viresh.kumar@...aro.org>
Signed-off-by: Ingo Molnar <mingo@...nel.org>
Cc: Juri Lelli <juri.lelli@...hat.com>
Cc: Vincent Guittot <vincent.guittot@...aro.org>
Cc: Dietmar Eggemann <dietmar.eggemann@....com>
Link: https://lore.kernel.org/r/f0554f590687478b33914a4aff9f0e6a62886d44.1579499907.git.viresh.kumar@linaro.org
---
kernel/sched/fair.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/kernel/sched/fair.c b/kernel/sched/fair.c
index ebf5095..fe4e0d7 100644
--- a/kernel/sched/fair.c
+++ b/kernel/sched/fair.c
@@ -5218,10 +5218,12 @@ static int sched_idle_rq(struct rq *rq)
rq->nr_running);
}
+#ifdef CONFIG_SMP
static int sched_idle_cpu(int cpu)
{
return sched_idle_rq(cpu_rq(cpu));
}
+#endif
/*
* The enqueue_task method is called before nr_running is
Powered by blists - more mailing lists