1 // Copyright 2009 The Go Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style
3 // license that can be found in the LICENSE file.
9 // System calls for arm, Linux
12 #define SYS__LLSEEK 140 /* from zsysnum_linux_arm.go */
13 // func seek(fd int, offset int64, whence int) (newoffset int64, errno int)
14 // Implemented in assembly to avoid allocation when
15 // taking the address of the return value newoffset.
16 // Underlying system call is
17 // llseek(int fd, int offhi, int offlo, int64 *result, int whence)
18 TEXT ·seek(SB),NOSPLIT,$0-28
19 BL runtime·entersyscall(SB)
20 MOVW $SYS__LLSEEK, R7 // syscall entry
22 MOVW offset_hi+8(FP), R1
23 MOVW offset_lo+4(FP), R2
24 MOVW $newoffset_lo+16(FP), R3
25 MOVW whence+12(FP), R4
31 MOVW R1, newoffset_lo+16(FP)
32 MOVW R1, newoffset_hi+20(FP)
35 BL runtime·exitsyscall(SB)
38 // system call filled in newoffset already
41 BL runtime·exitsyscall(SB)
44 // func rawVforkSyscall(trap, a1, a2, a3 uintptr) (r1, err uintptr)
45 TEXT ·rawVforkSyscall(SB),NOSPLIT|NOFRAME,$0-24
46 MOVW trap+0(FP), R7 // syscall entry
65 // func rawSyscallNoError(trap uintptr, a1, a2, a3 uintptr) (r1, r2 uintptr);
66 TEXT ·rawSyscallNoError(SB),NOSPLIT,$0-24
67 MOVW trap+0(FP), R7 // syscall entry