syscall.sh / nios2 / gettimeofday
gettimeofday
get / set time
sys_gettimeofday(struct __kernel_old_timeval *tv, struct timezone *tz)
| number | 169 (0xa9) |
|---|---|
| abi | time32 |
| entry point | sys_gettimeofday |
| since | Linux 3.19 |
| man page | gettimeofday(2) |
| source | elixir.bootlin.com |
Registers
| register | value |
|---|---|
r2 | 169, the syscall number |
r4 | struct __kernel_old_timeval *tv |
r5 | struct timezone *tz |
r2 | the return value |
Then run trap to enter the kernel.
Same syscall on other architectures
- x64 96
- x86 78
- arm64 169
- arm 78
- riscv64 169
- x32 1073741920
- loongarch64 169
- ppc64 78
- ppc 78
- s390x 78
- mips64 5094
- mipsn32 6094
- mipso32 4078
- alpha 359
- arc 169
- csky 169
- hexagon 169
- m68k 78
- microblaze 78
- openrisc 169
- parisc 78
- sh 78
- sparc 116
- sparc64 116
- xtensa 192
Get this as JSON: https://api.syscall.sh/v2/syscalls/nios2/gettimeofday