diff options
author | Glauber de Oliveira Costa <gcosta@redhat.com> | 2008-03-19 13:25:41 -0400 |
---|---|---|
committer | Ingo Molnar <mingo@elte.hu> | 2008-04-17 11:41:02 -0400 |
commit | 802b8133b4f78c30a2668d142d78861e27c0c6a7 (patch) | |
tree | 19d7e0a9ae8046a22e4cb0ce0585299ebb66e7ed /arch/x86/kernel/smpboot_32.c | |
parent | e7f8b14e028f7a2f9e5c83c17164aeeeb9c61f17 (diff) |
x86: schedule work only if keventd is already running
Only call schedule_work if keventd is already running.
This is already the way x86_64 does
Signed-off-by: Glauber Costa <gcosta@redhat.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'arch/x86/kernel/smpboot_32.c')
-rw-r--r-- | arch/x86/kernel/smpboot_32.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/arch/x86/kernel/smpboot_32.c b/arch/x86/kernel/smpboot_32.c index 5cae17f3eb75..255c6f761480 100644 --- a/arch/x86/kernel/smpboot_32.c +++ b/arch/x86/kernel/smpboot_32.c | |||
@@ -708,8 +708,12 @@ static void __cpuinit __smp_prepare_cpu(int cpu) | |||
708 | clone_pgd_range(swapper_pg_dir, swapper_pg_dir + USER_PGD_PTRS, | 708 | clone_pgd_range(swapper_pg_dir, swapper_pg_dir + USER_PGD_PTRS, |
709 | min_t(unsigned long, KERNEL_PGD_PTRS, USER_PGD_PTRS)); | 709 | min_t(unsigned long, KERNEL_PGD_PTRS, USER_PGD_PTRS)); |
710 | flush_tlb_all(); | 710 | flush_tlb_all(); |
711 | schedule_work(&info.task); | 711 | if (!keventd_up() || current_is_keventd()) |
712 | wait_for_completion(&done); | 712 | info.task.func(&info.task); |
713 | else { | ||
714 | schedule_work(&info.task); | ||
715 | wait_for_completion(&done); | ||
716 | } | ||
713 | 717 | ||
714 | zap_low_mappings(); | 718 | zap_low_mappings(); |
715 | } | 719 | } |