[tip:sched/urgent] sched: Fix warning in kernel/sched/fair.c

From: tip-bot for Arnd Bergmann
Date: Sat Jan 26 2013 - 07:18:22 EST


Commit-ID: 38dc3348e36d6cbe6ad51d771e4db948cda5b0e3
Gitweb: http://git.kernel.org/tip/38dc3348e36d6cbe6ad51d771e4db948cda5b0e3
Author: Arnd Bergmann <arnd@xxxxxxxx>
AuthorDate: Fri, 25 Jan 2013 14:14:22 +0000
Committer: Ingo Molnar <mingo@xxxxxxxxxx>
CommitDate: Fri, 25 Jan 2013 15:23:14 +0100

sched: Fix warning in kernel/sched/fair.c

a4c96ae319 "sched: Unthrottle rt runqueues in
__disable_runtime()" turned the unthrottle_offline_cfs_rqs
function into a static symbol, which now triggers a warning
about it being potentially unused:

kernel/sched/fair.c:2055:13: warning: 'unthrottle_offline_cfs_rqs' defined but not used [-Wunused-function]

Marking it __maybe_unused shuts up the gcc warning and lets the
compiler safely drop the function body when it's not being used.

To reproduce, build the ARM bcm2835_defconfig.

Signed-off-by: Arnd Bergmann <arnd@xxxxxxxx>
Cc: Peter Boonstoppel <pboonstoppel@xxxxxxxxxx>
Cc: Peter Zijlstra <a.p.zijlstra@xxxxxxxxx>
Cc: Paul Turner <pjt@xxxxxxxxxx>
Cc: linux-arm-kernel@xxxxxxxxxxxxxxxxxx
Link: http://lkml.kernel.org/r/1359123276-15833-6-git-send-email-arnd@xxxxxxxx
Signed-off-by: Ingo Molnar <mingo@xxxxxxxxxx>
---
kernel/sched/fair.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/kernel/sched/fair.c b/kernel/sched/fair.c
index 5eea870..81fa536 100644
--- a/kernel/sched/fair.c
+++ b/kernel/sched/fair.c
@@ -2663,7 +2663,7 @@ static void destroy_cfs_bandwidth(struct cfs_bandwidth *cfs_b)
hrtimer_cancel(&cfs_b->slack_timer);
}

-static void unthrottle_offline_cfs_rqs(struct rq *rq)
+static void __maybe_unused unthrottle_offline_cfs_rqs(struct rq *rq)
{
struct cfs_rq *cfs_rq;

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/