diff options
Diffstat (limited to 'kernel/cpu.c')
-rw-r--r-- | kernel/cpu.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/kernel/cpu.c b/kernel/cpu.c index deff2e69376..9a1ba77d6a5 100644 --- a/kernel/cpu.c +++ b/kernel/cpu.c @@ -692,10 +692,12 @@ void set_cpu_present(unsigned int cpu, bool present) void set_cpu_online(unsigned int cpu, bool online) { - if (online) + if (online) { cpumask_set_cpu(cpu, to_cpumask(cpu_online_bits)); - else + cpumask_set_cpu(cpu, to_cpumask(cpu_active_bits)); + } else { cpumask_clear_cpu(cpu, to_cpumask(cpu_online_bits)); + } } void set_cpu_active(unsigned int cpu, bool active) |