--- zzzz-none-000/linux-3.10.107/arch/um/kernel/reboot.c 2017-06-27 09:49:32.000000000 +0000 +++ scorpion-7490-727/linux-3.10.107/arch/um/kernel/reboot.c 2021-02-04 17:41:59.000000000 +0000 @@ -15,28 +15,21 @@ static void kill_off_processes(void) { - if (proc_mm) - /* - * FIXME: need to loop over userspace_pids - */ - os_kill_ptraced_process(userspace_pid[0], 1); - else { - struct task_struct *p; - int pid; + struct task_struct *p; + int pid; - read_lock(&tasklist_lock); - for_each_process(p) { - struct task_struct *t; + read_lock(&tasklist_lock); + for_each_process(p) { + struct task_struct *t; - t = find_lock_task_mm(p); - if (!t) - continue; - pid = t->mm->context.id.u.pid; - task_unlock(t); - os_kill_ptraced_process(pid, 1); - } - read_unlock(&tasklist_lock); + t = find_lock_task_mm(p); + if (!t) + continue; + pid = t->mm->context.id.u.pid; + task_unlock(t); + os_kill_ptraced_process(pid, 1); } + read_unlock(&tasklist_lock); } void uml_cleanup(void)