linux-uconsole/include/linux/sched
Matthias Kaehlcke a9903f04e0 sched/sysctl: Fix attributes of some extern declarations
The definition of sysctl_sched_migration_cost, sysctl_sched_nr_migrate
and sysctl_sched_time_avg includes the attribute const_debug. This
attribute is not part of the extern declaration of these variables in
include/linux/sched/sysctl.h, while it is in kernel/sched/sched.h,
and as a result Clang generates warnings like this:

  kernel/sched/sched.h:1618:33: warning: section attribute is specified on redeclared variable [-Wsection]
  extern const_debug unsigned int sysctl_sched_time_avg;
                                ^
  ./include/linux/sched/sysctl.h:42:21: note: previous declaration is here
  extern unsigned int sysctl_sched_time_avg;

The header only declares the variables when CONFIG_SCHED_DEBUG is defined,
therefore it is not necessary to duplicate the definition of const_debug.
Instead we can use the attribute __read_mostly, which is the expansion of
const_debug when CONFIG_SCHED_DEBUG=y is set.

Signed-off-by: Matthias Kaehlcke <mka@chromium.org>
Reviewed-by: Nick Desaulniers <nick.desaulniers@gmail.com>
Cc: Douglas Anderson <dianders@chromium.org>
Cc: Guenter Roeck <groeck@chromium.org>
Cc: Linus Torvalds <torvalds@linux-foundation.org>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Shile Zhang <shile.zhang@nokia.com>
Cc: Thomas Gleixner <tglx@linutronix.de>
Link: http://lkml.kernel.org/r/20171030180816.170850-1-mka@chromium.org
Signed-off-by: Ingo Molnar <mingo@kernel.org>
2017-11-01 09:36:17 +01:00
..
autogroup.h
clock.h sched/clock: Use late_initcall() instead of sched_init_smp() 2017-05-15 10:15:21 +02:00
coredump.h mm: make PR_SET_THP_DISABLE immediately active 2017-07-10 16:32:31 -07:00
cpufreq.h
cputime.h
deadline.h
debug.h sched/debug: Use task_pid_nr_ns in /proc/$pid/sched 2017-08-10 12:18:19 +02:00
hotplug.h
idle.h
init.h sched/headers: Remove <linux/sched.h> from <linux/sched/init.h> 2017-03-03 01:45:38 +01:00
isolation.h sched/isolation: Move isolcpus= handling to the housekeeping code 2017-10-27 09:55:30 +02:00
jobctl.h
loadavg.h
mm.h android: binder: drop lru lock in isolate callback 2017-10-03 17:54:24 -07:00
nohz.h MAINTAINERS: Add Frederic Weisbecker as nohz/dyntics maintainer 2017-07-05 16:26:37 +02:00
numa_balancing.h
prio.h
rt.h sched/rt: Add a helper to test for a RT task 2017-10-10 11:45:38 +02:00
signal.h randstruct: Mark various structs for randomization 2017-06-30 12:00:51 -07:00
stat.h
sysctl.h sched/sysctl: Fix attributes of some extern declarations 2017-11-01 09:36:17 +01:00
task.h sched/core: Remove unnecessary initialization init_idle_bootup_task() 2017-08-10 12:18:18 +02:00
task_stack.h
topology.h sched/core: Fix wake_affine() performance regression 2017-10-10 10:14:02 +02:00
user.h sock: ulimit on MSG_ZEROCOPY pages 2017-08-03 21:37:30 -07:00
wake_q.h
xacct.h