summaryrefslogtreecommitdiffstats
path: root/arch
diff options
context:
space:
mode:
authorKirill Tkhai <tkhai@yandex.ru>2013-12-12 17:41:01 +0400
committerMax Filippov <jcmvbkbc@gmail.com>2014-01-15 00:12:41 +0400
commitabf0ea65e0adede5f40a836e6af7f62e7c850546 (patch)
tree9728cc65de7b9b0954533ce06440ea960dfc7348 /arch
parent306ab5448fe1d002db8ca96c7d885e9f633b9121 (diff)
downloadlinux-stable-abf0ea65e0adede5f40a836e6af7f62e7c850546.tar.gz
linux-stable-abf0ea65e0adede5f40a836e6af7f62e7c850546.tar.bz2
linux-stable-abf0ea65e0adede5f40a836e6af7f62e7c850546.zip
xtensa: Enable irqs after cpu is set online
there is a small possibility that wake_up of softirq thread happens between local_irq_enable() and set_cpu_online(). In this case affinity of the thread changes to fallback affinity (i.e. CPU0). This may be a source of problems. The patch kills that possibility. Signed-off-by: Kirill Tkhai <tkhai@yandex.ru> Signed-off-by: Max Filippov <jcmvbkbc@gmail.com>
Diffstat (limited to 'arch')
-rw-r--r--arch/xtensa/kernel/smp.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/arch/xtensa/kernel/smp.c b/arch/xtensa/kernel/smp.c
index 1c7a209795e8..aa8bd8717927 100644
--- a/arch/xtensa/kernel/smp.c
+++ b/arch/xtensa/kernel/smp.c
@@ -151,9 +151,10 @@ void secondary_start_kernel(void)
secondary_init_irq();
local_timer_setup(cpu);
+ set_cpu_online(cpu, true);
+
local_irq_enable();
- set_cpu_online(cpu, true);
complete(&cpu_running);
cpu_startup_entry(CPUHP_ONLINE);