syscall.sh / sh / getpid

getpid

get process identification

sys_getpid(void)
number20 (0x14)
abicommon
entry pointsys_getpid
sinceLinux 5.0
man pagegetpid(2)
sourceelixir.bootlin.com

Registers

registervalue
r320, the syscall number
r0the return value

Then run trapa #31 to enter the kernel.

Same syscall on other architectures

Get this as JSON: https://api.syscall.sh/v2/syscalls/sh/getpid