close on loongarch64
close a file descriptor
sys_close(unsigned int fd)
| number | 57 (0x39) |
|---|---|
| abi | common |
| entry point | sys_close |
| since | Linux 5.19 or earlier (5.19 is the first release scanned for loongarch64) |
| man page | close(2) |
| source | elixir.bootlin.com |
Registers
| register | value |
|---|---|
a7 | 57, the syscall number |
a0 | unsigned int fd |
a0 | the return value |
Then run syscall 0 to enter the kernel.
Same syscall on other architectures
- x64 3
- x86 6
- arm64 57
- arm 6
- riscv64 57
- ia32 6
- x32 1073741827
- ppc64 6
- ppc 6
- s390x 6
- mips64 5003
- mipsn32 6003
- mipso32 4006
- alpha 6
- arc 57
- blackfin 6, removed in 4.17
- cris 6, removed in 4.17
- csky 57
- frv 6, removed in 4.17
- hexagon 57
- ia64 1029, removed in 6.7
- m32r 6, removed in 4.17
- m68k 6
- metag 57, removed in 4.17
- microblaze 6
- mn10300 6, removed in 4.17
- nds32 57, removed in 5.18
- nios2 57
- openrisc 57
- parisc 6
- score 57, removed in 4.17
- sh 6
- sparc 6
- sparc64 6
- tilegx 57, removed in 4.17
- tilepro 57, removed in 4.17
- xtensa 9
Get this as JSON: https://api.syscall.sh/v2/syscalls/loongarch64/close