pkey_mprotect on loongarch64

set protection on a region of memory

sys_pkey_mprotect(unsigned long start, size_t len, unsigned long prot, int pkey)
number288 (0x120)
abicommon
familypkeys see the whole family on loongarch64
entry pointsys_pkey_mprotect
sinceLinux 5.19 or earlier (5.19 is the first release scanned for loongarch64)
man pagepkey_mprotect(2)
sourceelixir.bootlin.com

Registers

registervalue
a7288, the syscall number
a0unsigned long start
a1size_t len
a2unsigned long prot
a3int pkey
a0the return value

Then run syscall 0 to enter the kernel.

Same syscall on other architectures

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