#include "asm/unistd_64.h" // for __NR_tkill #include "errno.h" // for EINVAL #include // for _NSIG #include // for __syscall_2, syscall #include // for __thread_self typedef struct __thread_self *pthread_t; int pthread_kill(pthread_t thread, int sig) { if (sig < 0 || sig > _NSIG) { return EINVAL; } if (thread->tid == 0) { return 0; } return syscall(tkill, thread->tid, sig); }