syscall.sh / sh / pivot_root
pivot_root
change the root mount
sys_pivot_root(const char *new_root, const char *put_old)
| number | 217 (0xd9) |
|---|---|
| abi | common |
| entry point | sys_pivot_root |
| since | Linux 5.0 |
| man page | pivot_root(2) |
| source | elixir.bootlin.com |
Registers
| register | value |
|---|---|
r3 | 217, the syscall number |
r4 | const char *new_root |
r5 | const char *put_old |
r0 | the return value |
Then run trapa #31 to enter the kernel.
Same syscall on other architectures
- x64 155
- x86 217
- arm64 41
- arm 218
- riscv64 41
- x32 1073741979
- loongarch64 41
- ppc64 203
- ppc 203
- s390x 217
- mips64 5151
- mipsn32 6151
- mipso32 4216
- alpha 374
- arc 41
- csky 41
- hexagon 41
- m68k 217
- microblaze 217
- nios2 41
- openrisc 41
- parisc 67
- sparc 146
- sparc64 146
- xtensa 175
Get this as JSON: https://api.syscall.sh/v2/syscalls/sh/pivot_root