diff --git a/include/syscall-codes.h b/include/syscall-codes.h index 1b6b66cc3..de2f89793 100644 --- a/include/syscall-codes.h +++ b/include/syscall-codes.h @@ -23,6 +23,7 @@ #define __NR_clone 56 #define __NR_exit 60 #define __NR_wait4 61 +#define __NR_kill 62 #define __NR_flock 73 #define __NR_unlink 87 #define __NR_tgkill 131 diff --git a/include/syscall.h b/include/syscall.h index 0396e7485..0b53a166d 100644 --- a/include/syscall.h +++ b/include/syscall.h @@ -284,6 +284,11 @@ static void always_inline local_sleep(long seconds) sys_nanosleep(&req, &rem); } +static long always_inline sys_kill(long pid, int sig) +{ + return syscall2(__NR_kill, pid, (long)sig); +} + static long always_inline sys_tgkill(long tgid, long pid, int sig) { return syscall3(__NR_tgkill, tgid, pid, (long)sig);