Merge tag 'pm+acpi-4.6-rc1-1' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael...
[linux-2.6-block.git] / kernel / smp.c
index 5099db15c5fb283ac7c305d8e82d266a98abf61d..74165443c240147cd701489298d2b552c8f46adf 100644 (file)
@@ -107,8 +107,7 @@ void __init call_function_init(void)
  */
 static __always_inline void csd_lock_wait(struct call_single_data *csd)
 {
-       while (smp_load_acquire(&csd->flags) & CSD_FLAG_LOCK)
-               cpu_relax();
+       smp_cond_acquire(!(csd->flags & CSD_FLAG_LOCK));
 }
 
 static __always_inline void csd_lock(struct call_single_data *csd)
@@ -569,6 +568,7 @@ void __init smp_init(void)
        unsigned int cpu;
 
        idle_threads_init();
+       cpuhp_threads_init();
 
        /* FIXME: This should be done in userspace --RR */
        for_each_present_cpu(cpu) {