pidfd_send_signal on x64
send a signal to a process specified by a file descriptor
sys_pidfd_send_signal(int pidfd, int sig, siginfo_t *info, unsigned int flags)
| number | 424 (0x1a8) |
|---|---|
| abi | common |
| entry point | sys_pidfd_send_signal |
| since | Linux 5.1 |
| man page | pidfd_send_signal(2) |
| source | elixir.bootlin.com |
Registers
| register | value |
|---|---|
rax | 424, the syscall number |
rdi | int pidfd |
rsi | int sig |
rdx | siginfo_t *info |
r10 | unsigned int flags |
rax | the return value |
Then run syscall to enter the kernel.
The syscall instruction clobbers rcx (the return address lands in rcx) and r11 (the flags land in r11).
Since Linux 5.14 the kernel reads the syscall number from eax and ignores the upper 32 bits of rax. Older kernels fail with ENOSYS when those bits are not zero, and mov eax, N clears them, so it works on both.
Same syscall on other architectures
- x86 424
- arm64 424
- arm 424
- riscv64 424
- ia32 424
- x32 1073742248
- loongarch64 424
- ppc64 424
- ppc 424
- s390x 424
- mips64 5424
- mipsn32 6424
- mipso32 4424
- alpha 534
- arc 424
- csky 424
- hexagon 424
- ia64 1448, removed in 6.7
- m68k 424
- microblaze 424
- nds32 424, removed in 5.18
- nios2 424
- openrisc 424
- parisc 424
- sh 424
- sparc 424
- sparc64 424
- xtensa 424
Get this as JSON: https://api.syscall.sh/v2/syscalls/x64/pidfd_send_signal