Changeset View
Changeset View
Standalone View
Standalone View
sys/compat/linux/linux_fork.c
Show All 39 Lines | |||||
#include <sys/lock.h> | #include <sys/lock.h> | ||||
#include <sys/mutex.h> | #include <sys/mutex.h> | ||||
#include <sys/proc.h> | #include <sys/proc.h> | ||||
#include <sys/ptrace.h> | #include <sys/ptrace.h> | ||||
#include <sys/racct.h> | #include <sys/racct.h> | ||||
#include <sys/sched.h> | #include <sys/sched.h> | ||||
#include <sys/syscallsubr.h> | #include <sys/syscallsubr.h> | ||||
#include <sys/sx.h> | #include <sys/sx.h> | ||||
#include <sys/umtxvar.h> | |||||
#include <sys/unistd.h> | #include <sys/unistd.h> | ||||
#include <sys/wait.h> | #include <sys/wait.h> | ||||
#include <vm/vm.h> | #include <vm/vm.h> | ||||
#include <vm/pmap.h> | #include <vm/pmap.h> | ||||
#include <vm/vm_map.h> | #include <vm/vm_map.h> | ||||
#ifdef COMPAT_LINUX32 | #ifdef COMPAT_LINUX32 | ||||
▲ Show 20 Lines • Show All 375 Lines • ▼ Show 20 Lines | if (child_clear_tid != NULL) { | ||||
error = futex_wake(td, child_clear_tid, 1, false); | error = futex_wake(td, child_clear_tid, 1, false); | ||||
/* | /* | ||||
* this cannot happen at the moment and if this happens it | * this cannot happen at the moment and if this happens it | ||||
* probably means there is a user space bug | * probably means there is a user space bug | ||||
*/ | */ | ||||
if (error != 0) | if (error != 0) | ||||
linux_msg(td, "futex stuff in thread_detach failed."); | linux_msg(td, "futex stuff in thread_detach failed."); | ||||
} | } | ||||
/* | |||||
* Do not rely on the robust list which is maintained by userspace, | |||||
* cleanup remaining pi (if any) after release_futexes anyway. | |||||
*/ | |||||
umtx_thread_exit(td); | |||||
} | } |