diff options
author | Jaswinder Singh Rajput <jaswinder@infradead.org> | 2008-12-29 13:09:17 -0500 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2008-12-30 01:42:34 -0500 |
commit | 47fea2adfc9e16846bc57c2f64ff233b354fef39 (patch) | |
tree | 00e72585e260dd84f4933d6894168c497d9fb1e6 /include | |
parent | 3c92ec8ae91ecf59d88c798301833d7cf83f2179 (diff) |
sched: sched.c declare variables before they get used
Impact: cleanup, avoid sparse warnings
In linux/sched.h moved out sysctl_sched_latency, sysctl_sched_min_granularity,
sysctl_sched_wakeup_granularity, sysctl_sched_shares_ratelimit and
sysctl_sched_shares_thresh from #ifdef CONFIG_SCHED_DEBUG as these variables
are common for both.
Fixes these sparse warnings:
kernel/sched.c:825:14: warning: symbol 'sysctl_sched_shares_ratelimit' was not declared. Should it be static?
kernel/sched.c:832:14: warning: symbol 'sysctl_sched_shares_thresh' was not declared. Should it be static?
kernel/sched_fair.c:37:14: warning: symbol 'sysctl_sched_latency' was not declared. Should it be static?
kernel/sched_fair.c:43:14: warning: symbol 'sysctl_sched_min_granularity' was not declared. Should it be static?
kernel/sched_fair.c:72:14: warning: symbol 'sysctl_sched_wakeup_granularity' was not declared. Should it be static?
Signed-off-by: Jaswinder Singh Rajput <jaswinderrajput@gmail.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'include')
-rw-r--r-- | include/linux/sched.h | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/include/linux/sched.h b/include/linux/sched.h index 8395e715809d..01d9fd268eb0 100644 --- a/include/linux/sched.h +++ b/include/linux/sched.h | |||
@@ -1651,16 +1651,16 @@ extern void wake_up_idle_cpu(int cpu); | |||
1651 | static inline void wake_up_idle_cpu(int cpu) { } | 1651 | static inline void wake_up_idle_cpu(int cpu) { } |
1652 | #endif | 1652 | #endif |
1653 | 1653 | ||
1654 | #ifdef CONFIG_SCHED_DEBUG | ||
1655 | extern unsigned int sysctl_sched_latency; | 1654 | extern unsigned int sysctl_sched_latency; |
1656 | extern unsigned int sysctl_sched_min_granularity; | 1655 | extern unsigned int sysctl_sched_min_granularity; |
1657 | extern unsigned int sysctl_sched_wakeup_granularity; | 1656 | extern unsigned int sysctl_sched_wakeup_granularity; |
1657 | extern unsigned int sysctl_sched_shares_ratelimit; | ||
1658 | extern unsigned int sysctl_sched_shares_thresh; | ||
1659 | #ifdef CONFIG_SCHED_DEBUG | ||
1658 | extern unsigned int sysctl_sched_child_runs_first; | 1660 | extern unsigned int sysctl_sched_child_runs_first; |
1659 | extern unsigned int sysctl_sched_features; | 1661 | extern unsigned int sysctl_sched_features; |
1660 | extern unsigned int sysctl_sched_migration_cost; | 1662 | extern unsigned int sysctl_sched_migration_cost; |
1661 | extern unsigned int sysctl_sched_nr_migrate; | 1663 | extern unsigned int sysctl_sched_nr_migrate; |
1662 | extern unsigned int sysctl_sched_shares_ratelimit; | ||
1663 | extern unsigned int sysctl_sched_shares_thresh; | ||
1664 | 1664 | ||
1665 | int sched_nr_latency_handler(struct ctl_table *table, int write, | 1665 | int sched_nr_latency_handler(struct ctl_table *table, int write, |
1666 | struct file *file, void __user *buffer, size_t *length, | 1666 | struct file *file, void __user *buffer, size_t *length, |