sched: fix defined-but-unused warning
PATCH 1/1 sched: fix defined-but-unused warning
Fix this warning, which appears with !CONFIG_SMP:kernel/sched.c:1216: warning: `init_hrtick' defined but not used
Signed-off-by Rabin Vincent <[email protected]>
--- kernel/sched.c | 2 ++ 1 files changed, 2 insertions(+), 0 deletions(-)
kernel/sched.c +2 -0
@@ -1161,6 +1161,7 @@ static enum hrtimer_restart hrtick(struct hrtimer *timer)return HRTIMER_NORESTART ; } +#ifdef CONFIG_SMP static void hotplug_hrtick_disable (int cpu) {struct rq *rq =cpu_rq (cpu);
@@ -1216,6 +1217,7 @@ static void init_hrtick(void) {hotcpu_notifier (hotplug_hrtick,0 ); } +#endif /* CONFIG_SMP */ static void init_rq_hrtick (struct rq *rq) {
Signature · 1 line
1.5.5.1
Ingo Molnar
AppliedQuoted 2 lines · Rabin Vincent
Fix this warning, which appears with !CONFIG_SMP:
kernel/sched.c:1216:
warning: `init_hrtick' defined but not used
applied, thanks Rabin.
Ingo