syscall.sh / mipso32 / dup2
dup2
duplicate a file descriptor
sys_dup2(unsigned int oldfd, unsigned int newfd)
| number | 4063 (0xfdf) |
|---|---|
| abi | o32 |
| entry point | sys_dup2 |
| since | Linux 5.0 |
| man page | dup2(2) |
| source | elixir.bootlin.com |
Registers
| register | value |
|---|---|
v0 | 4063, the syscall number |
a0 | unsigned int oldfd |
a1 | unsigned int newfd |
v0 | the return value |
Then run syscall to enter the kernel.
Same syscall on other architectures
- x64 33
- x86 63
- arm 63
- x32 1073741857
- ppc64 63
- ppc 63
- s390x 63
- mips64 5032
- mipsn32 6032
- alpha 90
- m68k 63
- microblaze 63
- parisc 63
- sh 63
- sparc 90
- sparc64 90
- xtensa 11
Get this as JSON: https://api.syscall.sh/v2/syscalls/mipso32/dup2