• P
    kthread: Simplify kthread_park() completion · f83ee19b
    Peter Zijlstra 提交于
    Oleg explains the reason we could hit park+park is that
    smpboot_update_cpumask_percpu_thread()'s
    
      for_each_cpu_and(cpu, &tmp, cpu_online_mask)
    	smpboot_park_kthread();
    
    turns into:
    
      for ((cpu) = 0; (cpu) < 1; (cpu)++, (void)mask, (void)and)
    	smpboot_park_kthread();
    
    on UP, ignoring the mask. But since we just completely removed that
    function, this is no longer relevant.
    
    So revert commit:
    
      b1f5b378 ("kthread: Allow kthread_park() on a parked kthread")
    Suggested-by: NOleg Nesterov <oleg@redhat.com>
    Signed-off-by: NPeter Zijlstra (Intel) <peterz@infradead.org>
    Cc: Linus Torvalds <torvalds@linux-foundation.org>
    Cc: Peter Zijlstra <peterz@infradead.org>
    Cc: Thomas Gleixner <tglx@linutronix.de>
    Cc: linux-kernel@vger.kernel.org
    Signed-off-by: NIngo Molnar <mingo@kernel.org>
    f83ee19b
kthread.c 33.6 KB