diff options
| author | Ingo Molnar <mingo@elte.hu> | 2009-12-14 03:16:49 -0500 |
|---|---|---|
| committer | Ingo Molnar <mingo@elte.hu> | 2009-12-14 03:16:49 -0500 |
| commit | cc0104e877fff32865a67b256d3a9ce52ff15790 (patch) | |
| tree | 18779442274e81607822ecb0905c55ac4ce6a163 /kernel | |
| parent | 16620e0f1990fa6d896a639449c4b3d678458464 (diff) | |
| parent | f40542532e96dda5506eb76badea322f2ae4731c (diff) | |
Merge branch 'linus' into tracing/urgent
Conflicts:
kernel/trace/trace_kprobe.c
Merge reason: resolve the conflict.
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'kernel')
| -rw-r--r-- | kernel/cpu.c | 18 | ||||
| -rw-r--r-- | kernel/cpuset.c | 18 | ||||
| -rw-r--r-- | kernel/exit.c | 2 | ||||
| -rw-r--r-- | kernel/futex.c | 10 | ||||
| -rw-r--r-- | kernel/hrtimer.c | 121 | ||||
| -rw-r--r-- | kernel/hw_breakpoint.c | 146 | ||||
| -rw-r--r-- | kernel/irq/spurious.c | 2 | ||||
| -rw-r--r-- | kernel/kgdb.c | 56 | ||||
| -rw-r--r-- | kernel/lockdep.c | 16 | ||||
| -rw-r--r-- | kernel/perf_event.c | 79 | ||||
| -rw-r--r-- | kernel/pm_qos_params.c | 20 | ||||
| -rw-r--r-- | kernel/resource.c | 26 | ||||
| -rw-r--r-- | kernel/sched.c | 218 | ||||
| -rw-r--r-- | kernel/sched_debug.c | 13 | ||||
| -rw-r--r-- | kernel/sched_fair.c | 155 | ||||
| -rw-r--r-- | kernel/sched_features.h | 5 | ||||
| -rw-r--r-- | kernel/sched_idletask.c | 2 | ||||
| -rw-r--r-- | kernel/sched_rt.c | 2 | ||||
| -rw-r--r-- | kernel/sys.c | 14 | ||||
| -rw-r--r-- | kernel/sysctl.c | 30 | ||||
| -rw-r--r-- | kernel/time/clocksource.c | 2 | ||||
| -rw-r--r-- | kernel/time/timer_list.c | 5 | ||||
| -rw-r--r-- | kernel/trace/trace_kprobe.c | 37 | ||||
| -rw-r--r-- | kernel/trace/trace_ksym.c | 5 | ||||
| -rw-r--r-- | kernel/workqueue.c | 131 |
25 files changed, 716 insertions, 417 deletions
diff --git a/kernel/cpu.c b/kernel/cpu.c index 7c4e2713df0a..291ac586f37f 100644 --- a/kernel/cpu.c +++ b/kernel/cpu.c | |||
| @@ -212,6 +212,8 @@ static int __ref _cpu_down(unsigned int cpu, int tasks_frozen) | |||
| 212 | err = __raw_notifier_call_chain(&cpu_chain, CPU_DOWN_PREPARE | mod, | 212 | err = __raw_notifier_call_chain(&cpu_chain, CPU_DOWN_PREPARE | mod, |
| 213 | hcpu, -1, &nr_calls); | 213 | hcpu, -1, &nr_calls); |
| 214 | if (err == NOTIFY_BAD) { | 214 | if (err == NOTIFY_BAD) { |
| 215 | set_cpu_active(cpu, true); | ||
| 216 | |||
| 215 | nr_calls--; | 217 | nr_calls--; |
| 216 | __raw_notifier_call_chain(&cpu_chain, CPU_DOWN_FAILED | mod, | 218 | __raw_notifier_call_chain(&cpu_chain, CPU_DOWN_FAILED | mod, |
| 217 | hcpu, nr_calls, NULL); | 219 | hcpu, nr_calls, NULL); |
| @@ -223,11 +225,11 @@ static int __ref _cpu_down(unsigned int cpu, int tasks_frozen) | |||
| 223 | 225 | ||
| 224 | /* Ensure that we are not runnable on dying cpu */ | 226 | /* Ensure that we are not runnable on dying cpu */ |
| 225 | cpumask_copy(old_allowed, ¤t->cpus_allowed); | 227 | cpumask_copy(old_allowed, ¤t->cpus_allowed); |
| 226 | set_cpus_allowed_ptr(current, | 228 | set_cpus_allowed_ptr(current, cpu_active_mask); |
| 227 | cpumask_of(cpumask_any_but(cpu_online_mask, cpu))); | ||
| 228 | 229 | ||
| 229 | err = __stop_machine(take_cpu_down, &tcd_param, cpumask_of(cpu)); | 230 | err = __stop_machine(take_cpu_down, &tcd_param, cpumask_of(cpu)); |
| 230 | if (err) { | 231 | if (err) { |
| 232 | set_cpu_active(cpu, true); | ||
| 231 | /* CPU didn't die: tell everyone. Can't complain. */ | 233 | /* CPU didn't die: tell everyone. Can't complain. */ |
| 232 | if (raw_notifier_call_chain(&cpu_chain, CPU_DOWN_FAILED | mod, | 234 | if (raw_notifier_call_chain(&cpu_chain, CPU_DOWN_FAILED | mod, |
| 233 | hcpu) == NOTIFY_BAD) | 235 | hcpu) == NOTIFY_BAD) |
| @@ -292,9 +294,6 @@ int __ref cpu_down(unsigned int cpu) | |||
| 292 | 294 | ||
| 293 | err = _cpu_down(cpu, 0); | 295 | err = _cpu_down(cpu, 0); |
| 294 | 296 | ||
| 295 | if (cpu_online(cpu)) | ||
| 296 | set_cpu_active(cpu, true); | ||
| 297 | |||
| 298 | out: | 297 | out: |
| 299 | cpu_maps_update_done(); | 298 | cpu_maps_update_done(); |
| 300 | stop_machine_destroy(); | 299 | stop_machine_destroy(); |
| @@ -387,6 +386,15 @@ int disable_nonboot_cpus(void) | |||
| 387 | * with the userspace trying to use the CPU hotplug at the same time | 386 | * with the userspace trying to use the CPU hotplug at the same time |
| 388 | */ | 387 | */ |
| 389 | cpumask_clear(frozen_cpus); | 388 | cpumask_clear(frozen_cpus); |
| 389 | |||
| 390 | for_each_online_cpu(cpu) { | ||
| 391 | if (cpu == first_cpu) | ||
| 392 | continue; | ||
| 393 | set_cpu_active(cpu, false); | ||
| 394 | } | ||
| 395 | |||
| 396 | synchronize_sched(); | ||
| 397 | |||
| 390 | printk("Disabling non-boot CPUs ...\n"); | 398 | printk("Disabling non-boot CPUs ...\n"); |
| 391 | for_each_online_cpu(cpu) { | 399 | for_each_online_cpu(cpu) { |
| 392 | if (cpu == first_cpu) | 400 | if (cpu == first_cpu) |
diff --git a/kernel/cpuset.c b/kernel/cpuset.c index 3cf2183b472d..ba401fab459f 100644 --- a/kernel/cpuset.c +++ b/kernel/cpuset.c | |||
| @@ -737,7 +737,7 @@ static void do_rebuild_sched_domains(struct work_struct *unused) | |||
| 737 | { | 737 | { |
| 738 | } | 738 | } |
| 739 | 739 | ||
| 740 | static int generate_sched_domains(struct cpumask **domains, | 740 | static int generate_sched_domains(cpumask_var_t **domains, |
| 741 | struct sched_domain_attr **attributes) | 741 | struct sched_domain_attr **attributes) |
| 742 | { | 742 | { |
| 743 | *domains = NULL; | 743 | *domains = NULL; |
| @@ -872,7 +872,7 @@ static int update_cpumask(struct cpuset *cs, struct cpuset *trialcs, | |||
| 872 | if (retval < 0) | 872 | if (retval < 0) |
| 873 | return retval; | 873 | return retval; |
| 874 | 874 | ||
| 875 | if (!cpumask_subset(trialcs->cpus_allowed, cpu_online_mask)) | 875 | if (!cpumask_subset(trialcs->cpus_allowed, cpu_active_mask)) |
| 876 | return -EINVAL; | 876 | return -EINVAL; |
| 877 | } | 877 | } |
| 878 | retval = validate_change(cs, trialcs); | 878 | retval = validate_change(cs, trialcs); |
| @@ -2010,7 +2010,7 @@ static void scan_for_empty_cpusets(struct cpuset *root) | |||
| 2010 | } | 2010 | } |
| 2011 | 2011 | ||
| 2012 | /* Continue past cpusets with all cpus, mems online */ | 2012 | /* Continue past cpusets with all cpus, mems online */ |
| 2013 | if (cpumask_subset(cp->cpus_allowed, cpu_online_mask) && | 2013 | if (cpumask_subset(cp->cpus_allowed, cpu_active_mask) && |
| 2014 | nodes_subset(cp->mems_allowed, node_states[N_HIGH_MEMORY])) | 2014 | nodes_subset(cp->mems_allowed, node_states[N_HIGH_MEMORY])) |
| 2015 | continue; | 2015 | continue; |
| 2016 | 2016 | ||
| @@ -2019,7 +2019,7 @@ static void scan_for_empty_cpusets(struct cpuset *root) | |||
| 2019 | /* Remove offline cpus and mems from this cpuset. */ | 2019 | /* Remove offline cpus and mems from this cpuset. */ |
| 2020 | mutex_lock(&callback_mutex); | 2020 | mutex_lock(&callback_mutex); |
| 2021 | cpumask_and(cp->cpus_allowed, cp->cpus_allowed, | 2021 | cpumask_and(cp->cpus_allowed, cp->cpus_allowed, |
| 2022 | cpu_online_mask); | 2022 | cpu_active_mask); |
| 2023 | nodes_and(cp->mems_allowed, cp->mems_allowed, | 2023 | nodes_and(cp->mems_allowed, cp->mems_allowed, |
| 2024 | node_states[N_HIGH_MEMORY]); | 2024 | node_states[N_HIGH_MEMORY]); |
| 2025 | mutex_unlock(&callback_mutex); | 2025 | mutex_unlock(&callback_mutex); |
| @@ -2057,8 +2057,10 @@ static int cpuset_track_online_cpus(struct notifier_block *unused_nb, | |||
| 2057 | switch (phase) { | 2057 | switch (phase) { |
| 2058 | case CPU_ONLINE: | 2058 | case CPU_ONLINE: |
| 2059 | case CPU_ONLINE_FROZEN: | 2059 | case CPU_ONLINE_FROZEN: |
| 2060 | case CPU_DEAD: | 2060 | case CPU_DOWN_PREPARE: |
| 2061 | case CPU_DEAD_FROZEN: | 2061 | case CPU_DOWN_PREPARE_FROZEN: |
| 2062 | case CPU_DOWN_FAILED: | ||
| 2063 | case CPU_DOWN_FAILED_FROZEN: | ||
| 2062 | break; | 2064 | break; |
| 2063 | 2065 | ||
| 2064 | default: | 2066 | default: |
| @@ -2067,7 +2069,7 @@ static int cpuset_track_online_cpus(struct notifier_block *unused_nb, | |||
| 2067 | 2069 | ||
| 2068 | cgroup_lock(); | 2070 | cgroup_lock(); |
| 2069 | mutex_lock(&callback_mutex); | 2071 | mutex_lock(&callback_mutex); |
| 2070 | cpumask_copy(top_cpuset.cpus_allowed, cpu_online_mask); | 2072 | cpumask_copy(top_cpuset.cpus_allowed, cpu_active_mask); |
| 2071 | mutex_unlock(&callback_mutex); | 2073 | mutex_unlock(&callback_mutex); |
| 2072 | scan_for_empty_cpusets(&top_cpuset); | 2074 | scan_for_empty_cpusets(&top_cpuset); |
| 2073 | ndoms = generate_sched_domains(&doms, &attr); | 2075 | ndoms = generate_sched_domains(&doms, &attr); |
| @@ -2114,7 +2116,7 @@ static int cpuset_track_online_nodes(struct notifier_block *self, | |||
| 2114 | 2116 | ||
| 2115 | void __init cpuset_init_smp(void) | 2117 | void __init cpuset_init_smp(void) |
| 2116 | { | 2118 | { |
| 2117 | cpumask_copy(top_cpuset.cpus_allowed, cpu_online_mask); | 2119 | cpumask_copy(top_cpuset.cpus_allowed, cpu_active_mask); |
| 2118 | top_cpuset.mems_allowed = node_states[N_HIGH_MEMORY]; | 2120 | top_cpuset.mems_allowed = node_states[N_HIGH_MEMORY]; |
| 2119 | 2121 | ||
| 2120 | hotcpu_notifier(cpuset_track_online_cpus, 0); | 2122 | hotcpu_notifier(cpuset_track_online_cpus, 0); |
diff --git a/kernel/exit.c b/kernel/exit.c index 1143012951e9..6f50ef55a6f3 100644 --- a/kernel/exit.c +++ b/kernel/exit.c | |||
| @@ -971,7 +971,7 @@ NORET_TYPE void do_exit(long code) | |||
| 971 | exit_thread(); | 971 | exit_thread(); |
| 972 | cgroup_exit(tsk, 1); | 972 | cgroup_exit(tsk, 1); |
| 973 | 973 | ||
| 974 | if (group_dead && tsk->signal->leader) | 974 | if (group_dead) |
| 975 | disassociate_ctty(1); | 975 | disassociate_ctty(1); |
| 976 | 976 | ||
| 977 | module_put(task_thread_info(tsk)->exec_domain->module); | ||
