Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
G
golang
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
go
golang
Commits
55ba9d6a
Commit
55ba9d6a
authored
Nov 05, 2009
by
Kai Backman
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fixing (badly) linux_arm syscall.
R=rsc
http://go/go-review/1017037
parent
601ee480
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
47 additions
and
23 deletions
+47
-23
syscall_linux_arm.go
src/pkg/syscall/syscall_linux_arm.go
+2
-0
zerrors_linux_arm.go
src/pkg/syscall/zerrors_linux_arm.go
+1
-0
zsyscall_linux_arm.go
src/pkg/syscall/zsyscall_linux_arm.go
+21
-0
ztypes_linux_arm.go
src/pkg/syscall/ztypes_linux_arm.go
+23
-23
No files found.
src/pkg/syscall/syscall_linux_arm.go
View file @
55ba9d6a
...
...
@@ -34,6 +34,8 @@ func NsecToTimeval(nsec int64) (tv Timeval) {
//sys socket(domain int, typ int, proto int) (fd int, errno int)
//sys getpeername(fd int, rsa *RawSockaddrAny, addrlen *_Socklen) (errno int)
//sys getsockname(fd int, rsa *RawSockaddrAny, addrlen *_Socklen) (errno int)
//sys recvfrom(fd int, p []byte, flags int, from *RawSockaddrAny, fromlen *_Socklen) (n int, errno int)
//sys sendto(s int, buf []byte, flags int, to uintptr, addrlen _Socklen) (errno int)
//sys Chown(path string, uid int, gid int) (errno int)
//sys Fchown(fd int, uid int, gid int) (errno int)
...
...
src/pkg/syscall/zerrors_linux_arm.go
View file @
55ba9d6a
...
...
@@ -176,6 +176,7 @@ const (
SIGINT
=
0x2
;
SIGIOT
=
0x6
;
SIGTERM
=
0xf
;
O_EXCL
=
0x80
;
)
// Types
...
...
src/pkg/syscall/zsyscall_linux_arm.go
View file @
55ba9d6a
...
...
@@ -775,3 +775,24 @@ func Statfs(path string, buf *Statfs_t) (errno int) {
errno
=
int
(
e1
);
return
;
}
func
recvfrom
(
fd
int
,
p
[]
byte
,
flags
int
,
from
*
RawSockaddrAny
,
fromlen
*
_Socklen
)
(
n
int
,
errno
int
)
{
var
_p0
*
byte
;
if
len
(
p
)
>
0
{
_p0
=
&
p
[
0
];
}
r0
,
_
,
e1
:=
Syscall6
(
SYS_RECVFROM
,
uintptr
(
fd
),
uintptr
(
unsafe
.
Pointer
(
_p0
)),
uintptr
(
len
(
p
)),
uintptr
(
flags
),
uintptr
(
unsafe
.
Pointer
(
from
)),
uintptr
(
unsafe
.
Pointer
(
fromlen
)));
n
=
int
(
r0
);
errno
=
int
(
e1
);
return
;
}
func
sendto
(
s
int
,
buf
[]
byte
,
flags
int
,
to
uintptr
,
addrlen
_Socklen
)
(
errno
int
)
{
var
_p0
*
byte
;
if
len
(
buf
)
>
0
{
_p0
=
&
buf
[
0
];
}
_
,
_
,
e1
:=
Syscall6
(
SYS_SENDTO
,
uintptr
(
s
),
uintptr
(
unsafe
.
Pointer
(
_p0
)),
uintptr
(
len
(
buf
)),
uintptr
(
flags
),
uintptr
(
to
),
uintptr
(
addrlen
));
errno
=
int
(
e1
);
return
;
}
src/pkg/syscall/ztypes_linux_arm.go
View file @
55ba9d6a
...
...
@@ -77,29 +77,29 @@ const (
SizeofSockaddrInet6
=
0x1c
;
SizeofSockaddrAny
=
0x1c
;
SizeofSockaddrUnix
=
0x6e
;
_
PTRACE_TRACEME
=
0
;
_
PTRACE_PEEKTEXT
=
0x1
;
_
PTRACE_PEEKDATA
=
0x2
;
_
PTRACE_PEEKUSER
=
0x3
;
_
PTRACE_POKETEXT
=
0x4
;
_
PTRACE_POKEDATA
=
0x5
;
_
PTRACE_POKEUSER
=
0x6
;
_
PTRACE_CONT
=
0x7
;
_
PTRACE_KILL
=
0x8
;
_
PTRACE_SINGLESTEP
=
0x9
;
_
PTRACE_GETREGS
=
0xc
;
_
PTRACE_SETREGS
=
0xd
;
_
PTRACE_GETFPREGS
=
0xe
;
_
PTRACE_SETFPREGS
=
0xf
;
_
PTRACE_ATTACH
=
0x10
;
_
PTRACE_DETACH
=
0x11
;
_
PTRACE_GETFPXREGS
=
0x12
;
_
PTRACE_SETFPXREGS
=
0x13
;
_
PTRACE_SYSCALL
=
0x18
;
_
PTRACE_SETOPTIONS
=
0x4200
;
_
PTRACE_GETEVENTMSG
=
0x4201
;
_
PTRACE_GETSIGINFO
=
0x4202
;
_
PTRACE_SETSIGINFO
=
0x4203
;
PTRACE_TRACEME
=
0
;
PTRACE_PEEKTEXT
=
0x1
;
PTRACE_PEEKDATA
=
0x2
;
PTRACE_PEEKUSER
=
0x3
;
PTRACE_POKETEXT
=
0x4
;
PTRACE_POKEDATA
=
0x5
;
PTRACE_POKEUSER
=
0x6
;
PTRACE_CONT
=
0x7
;
PTRACE_KILL
=
0x8
;
PTRACE_SINGLESTEP
=
0x9
;
PTRACE_GETREGS
=
0xc
;
PTRACE_SETREGS
=
0xd
;
PTRACE_GETFPREGS
=
0xe
;
PTRACE_SETFPREGS
=
0xf
;
PTRACE_ATTACH
=
0x10
;
PTRACE_DETACH
=
0x11
;
PTRACE_GETFPXREGS
=
0x12
;
PTRACE_SETFPXREGS
=
0x13
;
PTRACE_SYSCALL
=
0x18
;
PTRACE_SETOPTIONS
=
0x4200
;
PTRACE_GETEVENTMSG
=
0x4201
;
PTRACE_GETSIGINFO
=
0x4202
;
PTRACE_SETSIGINFO
=
0x4203
;
PTRACE_O_TRACESYSGOOD
=
0x1
;
PTRACE_O_TRACEFORK
=
0x2
;
PTRACE_O_TRACEVFORK
=
0x4
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment