untested
This commit is contained in:
parent
c1daccd194
commit
68542b65bf
|
|
@ -0,0 +1,42 @@
|
|||
brk module
|
||||
|
||||
external
|
||||
_end
|
||||
_cerror
|
||||
|
||||
internal
|
||||
nd
|
||||
word :=2
|
||||
_end
|
||||
|
||||
global
|
||||
brk procedure
|
||||
entry
|
||||
ld r0,r7
|
||||
xor r4,r4
|
||||
sc #17
|
||||
ld r2,r4
|
||||
jp c,cerror
|
||||
ld nd,r0
|
||||
ret
|
||||
end brk
|
||||
|
||||
sbrk procedure
|
||||
entry
|
||||
ld r0,r7
|
||||
ld r2,nd
|
||||
add r0,r2
|
||||
ld r1,r0
|
||||
dec r1,#1
|
||||
dec r2,#2
|
||||
cpb rh1,rh2
|
||||
jr z,t1
|
||||
sc #17
|
||||
ld r2,r4
|
||||
jp c,cerror
|
||||
t1:
|
||||
ld r2,nd
|
||||
ld nd,r0
|
||||
ret
|
||||
end sbrk
|
||||
end brk
|
||||
|
|
@ -1,8 +1,5 @@
|
|||
exit module
|
||||
|
||||
external
|
||||
_cerror
|
||||
|
||||
global
|
||||
exit procedure
|
||||
entry
|
||||
|
|
|
|||
|
|
@ -0,0 +1,18 @@
|
|||
mknod module
|
||||
|
||||
external
|
||||
_cerror
|
||||
|
||||
global
|
||||
mknod procedure
|
||||
entry
|
||||
ld r0,r7
|
||||
ld r1,r6
|
||||
ld r2,r5
|
||||
xor r4,r4
|
||||
sc #14
|
||||
ld r2,r4
|
||||
ret nc
|
||||
jp cerror
|
||||
end mknod
|
||||
end mknod
|
||||
|
|
@ -0,0 +1,18 @@
|
|||
mount module
|
||||
|
||||
external
|
||||
_cerror
|
||||
|
||||
global
|
||||
mount procedure
|
||||
entry
|
||||
ld r0,r7
|
||||
ld r1,r6
|
||||
ld r2,r5
|
||||
xor r4,r4
|
||||
sc #21
|
||||
ld r2,r4
|
||||
ret nc
|
||||
jp cerror
|
||||
end mount
|
||||
end mount
|
||||
|
|
@ -0,0 +1,16 @@
|
|||
nice module
|
||||
|
||||
external
|
||||
_cerror
|
||||
|
||||
global
|
||||
nice procedure
|
||||
entry
|
||||
ld r0,r7
|
||||
xor r4,r4
|
||||
sc #34
|
||||
ld r2,r4
|
||||
ret nc
|
||||
jp cerror
|
||||
end nice
|
||||
end nice
|
||||
|
|
@ -0,0 +1,17 @@
|
|||
open module
|
||||
|
||||
external
|
||||
_cerror
|
||||
|
||||
global
|
||||
open procedure
|
||||
entry
|
||||
ld r0,r7
|
||||
ld r1,r6
|
||||
ld r2,r5
|
||||
sc #5
|
||||
ld r2,r4
|
||||
ret nc
|
||||
jp cerror
|
||||
end open
|
||||
end open
|
||||
|
|
@ -0,0 +1,16 @@
|
|||
pipe module
|
||||
|
||||
external
|
||||
_cerror
|
||||
|
||||
global
|
||||
pipe procedure
|
||||
entry
|
||||
sc #42
|
||||
ld r2,r4
|
||||
jp c,cerror
|
||||
ldl @r7,rr4
|
||||
xor r2,r2
|
||||
ret
|
||||
end pipe
|
||||
end pipe
|
||||
|
|
@ -0,0 +1,17 @@
|
|||
profil module
|
||||
|
||||
external
|
||||
_cerror
|
||||
|
||||
global
|
||||
profil procedure
|
||||
entry
|
||||
ld r0,r7
|
||||
ld r1,r6
|
||||
ld r2,r5
|
||||
ld r3,r4
|
||||
sc #44
|
||||
xor r2,r2
|
||||
ret
|
||||
end profil
|
||||
end profil
|
||||
|
|
@ -0,0 +1,24 @@
|
|||
ptrace module
|
||||
|
||||
internal
|
||||
_errno
|
||||
word :=2
|
||||
|
||||
external
|
||||
_cerror
|
||||
|
||||
global
|
||||
ptrace procedure
|
||||
entry
|
||||
ld r0,r7
|
||||
ld r1,r6
|
||||
ld r2,r5
|
||||
ld r3,r4
|
||||
xor r4,r4
|
||||
ld _errno,r4
|
||||
sc #26
|
||||
ld r2,r4
|
||||
ret nc
|
||||
jp cerror
|
||||
end ptrace
|
||||
end ptrace
|
||||
|
|
@ -0,0 +1,17 @@
|
|||
read module
|
||||
|
||||
external
|
||||
_cerror
|
||||
|
||||
global
|
||||
read procedure
|
||||
entry
|
||||
ld r0,r7
|
||||
ld r1,r6
|
||||
ld r2,r5
|
||||
sc #3
|
||||
ld r2,r4
|
||||
ret nc
|
||||
jp cerror
|
||||
end read
|
||||
end read
|
||||
|
|
@ -0,0 +1,16 @@
|
|||
setgid module
|
||||
|
||||
external
|
||||
_cerror
|
||||
|
||||
global
|
||||
setgid procedure
|
||||
entry
|
||||
ld r0,r7
|
||||
xor r4,r4
|
||||
sc #46
|
||||
ld r2,r4
|
||||
ret nc
|
||||
jp cerror
|
||||
end setgid
|
||||
end setgid
|
||||
|
|
@ -0,0 +1,16 @@
|
|||
setpgrp module
|
||||
|
||||
external
|
||||
_cerror
|
||||
|
||||
global
|
||||
setpgrp procedure
|
||||
entry
|
||||
ld r0,#%0001
|
||||
xor r4,r4
|
||||
sc #39
|
||||
ld r2,r4
|
||||
ret nc
|
||||
jp cerror
|
||||
end setpgrp
|
||||
end setpgrp
|
||||
|
|
@ -0,0 +1,16 @@
|
|||
setuid module
|
||||
|
||||
external
|
||||
_cerror
|
||||
|
||||
global
|
||||
setuid procedure
|
||||
entry
|
||||
ld r0,r7
|
||||
xor r4,r4
|
||||
sc #23
|
||||
ld r2,r4
|
||||
ret nc
|
||||
jp cerror
|
||||
end setuid
|
||||
end setuid
|
||||
|
|
@ -0,0 +1,17 @@
|
|||
stat module
|
||||
|
||||
external
|
||||
_cerror
|
||||
|
||||
global
|
||||
stat procedure
|
||||
entry
|
||||
ld r0,r7
|
||||
ld r1,r6
|
||||
xor r4,r4
|
||||
sc #18
|
||||
ld r2,r4
|
||||
ret nc
|
||||
jp cerror
|
||||
end stat
|
||||
end stat
|
||||
|
|
@ -0,0 +1,16 @@
|
|||
stime module
|
||||
|
||||
external
|
||||
_cerror
|
||||
|
||||
global
|
||||
stime procedure
|
||||
entry
|
||||
ldl rr0,@r7
|
||||
xor r4,r4
|
||||
sc #25
|
||||
ld r2,r4
|
||||
ret nc
|
||||
jp cerror
|
||||
end stime
|
||||
end stime
|
||||
|
|
@ -0,0 +1,9 @@
|
|||
sync module
|
||||
|
||||
global
|
||||
sync procedure
|
||||
entry
|
||||
sc #36
|
||||
ret
|
||||
end sync
|
||||
end sync
|
||||
Loading…
Reference in New Issue