syscall.sh / riscv64 / kexec_file_load
kexec_file_load
load a new kernel for later execution
sys_kexec_file_load(int kernel_fd, int initrd_fd, unsigned long cmdline_len, const char *cmdline_ptr, unsigned long flags)
| number | 294 (0x126) |
|---|---|
| abi | common |
| entry point | sys_kexec_file_load |
| since | Linux 5.0 |
| man page | kexec_file_load(2) |
| source | elixir.bootlin.com |
Registers
| register | value |
|---|---|
a7 | 294, the syscall number |
a0 | int kernel_fd |
a1 | int initrd_fd |
a2 | unsigned long cmdline_len |
a3 | const char *cmdline_ptr |
a4 | unsigned long flags |
a0 | the return value |
Then run ecall to enter the kernel.
Same syscall on other architectures
- x64 320
- arm64 294
- arm 401
- x32 1073742144
- loongarch64 294
- ppc64 382
- ppc 382
- s390x 381
- arc 294
- csky 294
- hexagon 294
- nios2 294
- openrisc 294
- parisc 355
Get this as JSON: https://api.syscall.sh/v2/syscalls/riscv64/kexec_file_load