• Heiko Carstens's avatar
    stop_machine: use workqueues instead of kernel threads · c9583e55
    Heiko Carstens authored
    Convert stop_machine to a workqueue based approach. Instead of using kernel
    threads for stop_machine we now use a an rt workqueue to synchronize all
    cpus.
    This has the advantage that all needed per cpu threads are already created
    when stop_machine gets called. And therefore a call to stop_machine won't
    fail anymore. This is needed for s390 which needs a mechanism to synchronize
    all cpus without allocating any memory.
    As Rusty pointed out free_module() needs a non-failing stop_machine interface
    as well.
    
    As a side effect the stop_machine code gets simplified.
    Signed-off-by: default avatarHeiko Carstens <heiko.carstens@de.ibm.com>
    Signed-off-by: default avatarRusty Russell <rusty@rustcorp.com.au>
    c9583e55
stop_machine.c 3.68 KB