diff options
Diffstat (limited to 'mit-pthreads/machdep/syscall-sparc-sunos-5.3.S')
-rw-r--r-- | mit-pthreads/machdep/syscall-sparc-sunos-5.3.S | 65 |
1 files changed, 65 insertions, 0 deletions
diff --git a/mit-pthreads/machdep/syscall-sparc-sunos-5.3.S b/mit-pthreads/machdep/syscall-sparc-sunos-5.3.S new file mode 100644 index 00000000000..822055ad04e --- /dev/null +++ b/mit-pthreads/machdep/syscall-sparc-sunos-5.3.S @@ -0,0 +1,65 @@ +/* ==== syscall.S ============================================================ + * Copyright (c) 1994 Chris Provenzano, proven@mit.edu + * All rights reserved. + * + */ + +#ifndef lint + .text + .asciz "$Id$"; +#endif + +#define _ASM +#include <sys/syscall.h> + +/* + * Initial asm stuff for all functions. + */ + .text + .align 4 + +/* ========================================================================== + * error code for all syscalls. The error value is returned as the negative + * of the errno value. + */ + +1: + sub %r0, %o0, %o0 +2: + retl + nop + +/* ========================================================================== + * machdep_sys_fork() + */ + .globl machdep_sys_fork; + +machdep_sys_fork:; + + mov SYS_fork, %g1; + ta 0; + bcs 1b; + nop; + tst %o1 + bne,a __fork_parent + mov %g0, %o0 +__fork_parent:; + retl + nop; /* Added by monty to keep sparc assembler happy */ + +/* ========================================================================== + * Berkeley socket stuff + * + * ========================================================================== + * machdep_sys_socketcall() + */ + .globl machdep_sys_socketcall; + +machdep_sys_socketcall:; + + mov 83, %g1; + ta 0; + bcs,a 2b; + sub %r0,%o0,%o0; + retl + nop; /* Added by monty to keep sparc assembler happy */ |