diff options
-rw-r--r-- | kernel/cpu.c | 6 | ||||
-rw-r--r-- | kernel/sched/core.c | 1 |
2 files changed, 4 insertions, 3 deletions
diff --git a/kernel/cpu.c b/kernel/cpu.c index a9e710eef0e2..247979a1b815 100644 --- a/kernel/cpu.c +++ b/kernel/cpu.c | |||
@@ -726,10 +726,12 @@ void set_cpu_present(unsigned int cpu, bool present) | |||
726 | 726 | ||
727 | void set_cpu_online(unsigned int cpu, bool online) | 727 | void set_cpu_online(unsigned int cpu, bool online) |
728 | { | 728 | { |
729 | if (online) | 729 | if (online) { |
730 | cpumask_set_cpu(cpu, to_cpumask(cpu_online_bits)); | 730 | cpumask_set_cpu(cpu, to_cpumask(cpu_online_bits)); |
731 | else | 731 | cpumask_set_cpu(cpu, to_cpumask(cpu_active_bits)); |
732 | } else { | ||
732 | cpumask_clear_cpu(cpu, to_cpumask(cpu_online_bits)); | 733 | cpumask_clear_cpu(cpu, to_cpumask(cpu_online_bits)); |
734 | } | ||
733 | } | 735 | } |
734 | 736 | ||
735 | void set_cpu_active(unsigned int cpu, bool active) | 737 | void set_cpu_active(unsigned int cpu, bool active) |
diff --git a/kernel/sched/core.c b/kernel/sched/core.c index 44e00abece09..86f3890c3d08 100644 --- a/kernel/sched/core.c +++ b/kernel/sched/core.c | |||
@@ -5076,7 +5076,6 @@ static int sched_cpu_active(struct notifier_block *nfb, | |||
5076 | unsigned long action, void *hcpu) | 5076 | unsigned long action, void *hcpu) |
5077 | { | 5077 | { |
5078 | switch (action & ~CPU_TASKS_FROZEN) { | 5078 | switch (action & ~CPU_TASKS_FROZEN) { |
5079 | case CPU_STARTING: | ||
5080 | case CPU_DOWN_FAILED: | 5079 | case CPU_DOWN_FAILED: |
5081 | set_cpu_active((long)hcpu, true); | 5080 | set_cpu_active((long)hcpu, true); |
5082 | return NOTIFY_OK; | 5081 | return NOTIFY_OK; |