scheduler fixes
Subsystems (5)
Linus,
Please pull the latest sched-fixes-for-linus git tree from:
git://git.kernel.org/pub/scm/linux/kernel/git/tip/linux-2.6-tip.git sched-fixes-for-linus
This also includes a commit to fix the function-local statics you noticed yesterday.
Thanks,
Ingo
------------------>
Hillf Danton (1):
sched: Fix strncmp operation
Mike Galbraith (2):
sched: Fix struct autogroup memory leak
sched: Move sched_autogroup_exit() to free_signal_struct()
Peter Zijlstra (1):
sched: Constify function scope static struct sched_param usage
Yong Zhang (2):
sched: Consolidate the name of root_task_group and init_task_group
sched: Mark autogroup_init() __init
include/linux/sched.h | 2 +- kernel/fork.c | 7 ++--- kernel/irq/manage.c | 2 +- kernel/kthread.c | 2 +- kernel/sched.c | 45 ++++++++++++++++++++--------------------- kernel/sched_autogroup.c | 8 +++--- kernel/softirq.c | 2 +- kernel/trace/trace_selftest.c | 2 +- 8 files changed, 34 insertions(+), 36 deletions(-)
include/linux/sched.h +1 -1
@@ -2511,7 +2511,7 @@ extern void normalize_rt_tasks(void);#ifdef CONFIG_CGROUP_SCHED -extern struct task_group init_task_group; +extern struct task_group root_task_group;extern struct task_group *sched_create_group (struct task_group *parent);extern void sched_destroy_group (struct task_group *tg);
kernel/fork.c +3 -4
@@ -169,15 +169,14 @@ EXPORT_SYMBOL(free_task);static inline void free_signal_struct (struct signal_struct *sig) {taskstats_tgid_free (sig); +sched_autogroup_exit (sig);kmem_cache_free (signal_cachep, sig); }static inline void put_signal_struct (struct signal_struct *sig) { -if (atomic_dec_and_test (&sig->sigcnt)) { -sched_autogroup_exit (sig); +if (atomic_dec_and_test (&sig->sigcnt))free_signal_struct (sig); - } }void __put_task_struct (struct task_struct *tsk)
@@ -1318,7 +1317,7 @@ bad_fork_cleanup_mm: } bad_fork_cleanup_signal:if (!(clone_flags &CLONE_THREAD )) -put_signal_struct (p->signal); +free_signal_struct (p->signal); bad_fork_cleanup_sighand:__cleanup_sighand (p->sighand); bad_fork_cleanup_fs:
kernel/irq/manage.c +1 -1
@@ -577,7 +577,7 @@ irq_thread_check_affinity(struct irq_desc *desc, struct irqaction *action) { }*/ static int irq_thread (void *data) { -static struct sched_param param = { +static const struct sched_param param = { .sched_priority =MAX_USER_RT_PRIO /2 , };struct irqaction *action = data;
kernel/kthread.c +1 -1
@@ -148,7 +148,7 @@ struct task_struct *kthread_create(int (*threadfn)(void *data),wait_for_completion (&create.done);if (!IS_ERR (create.result)) { -static struct sched_param param = { .sched_priority =0 }; +static const struct sched_param param = { .sched_priority =0 };va_list args;va_start (args, namefmt);
kernel/sched.c +22 -23
141 lines not on this page · raw message
kernel/sched_autogroup.c +4 -4
@@ -9,10 +9,10 @@ unsigned int __read_mostly sysctl_sched_autogroup_enabled = 1;static struct autogroup autogroup_default;static atomic_t autogroup_seq_nr; -static void autogroup_init (struct task_struct *init_task) +static void __init autogroup_init (struct task_struct *init_task) { - autogroup_default.tg = &init_task_group; - init_task_group.autogroup = &autogroup_default; + autogroup_default.tg = &root_task_group; + root_task_group.autogroup = &autogroup_default;kref_init (&autogroup_default.kref);init_rwsem (&autogroup_default.lock); init_task->signal->autogroup = &autogroup_default;
@@ -63,7 +63,7 @@ static inline struct autogroup *autogroup_create(void)if (!ag) goto out_fail; - tg =sched_create_group (&init_task_group); + tg =sched_create_group (&root_task_group);if (IS_ERR (tg)) goto out_free;
kernel/softirq.c +1 -1
@@ -853,7 +853,7 @@ static int __cpuinit cpu_callback(struct notifier_block *nfb, cpumask_any(cpu_online_mask));case CPU_DEAD :case CPU_DEAD_FROZEN : { -static struct sched_param param = { +static const struct sched_param param = { .sched_priority =MAX_RT_PRIO -1 };
kernel/trace/trace_selftest.c +1 -1
@@ -558,7 +558,7 @@ trace_selftest_startup_nop(struct tracer *trace, struct trace_array *tr)static int trace_wakeup_test_thread (void *data) {/* Make this a RT thread, doesn't need to be too high */ -static struct sched_param param = { .sched_priority =5 }; +static const struct sched_param param = { .sched_priority =5 };struct completion *x = data;sched_setscheduler (current,SCHED_FIFO , ¶m);