syscall.sh / x86 / mmap2
mmap2
map files or devices into memory
sys_mmap_pgoff(unsigned long addr, unsigned long len, unsigned long prot, unsigned long flags, unsigned long fd, unsigned long pgoff)
| number | 192 (0xc0) |
|---|---|
| abi | i386 |
| entry point | sys_mmap_pgoff |
| since | Linux 3.3 |
| man page | mmap2(2) |
| source | elixir.bootlin.com |
Registers
| register | value |
|---|---|
eax | 192, the syscall number |
ebx | unsigned long addr |
ecx | unsigned long len |
edx | unsigned long prot |
esi | unsigned long flags |
edi | unsigned long fd |
ebp | unsigned long pgoff |
eax | the return value |
Then run int 0x80 to enter the kernel.
Same syscall on other architectures
- arm 192
- ppc 192
- mipso32 4210
- arc 222
- csky 222
- hexagon 222
- m68k 192
- microblaze 192
- nios2 222
- openrisc 222
- parisc 89
- sh 192
- sparc 56
- xtensa 80
Get this as JSON: https://api.syscall.sh/v2/syscalls/x86/mmap2