summaryrefslogtreecommitdiff
path: root/lib/libc/arch/mips/sys
diff options
context:
space:
mode:
Diffstat (limited to 'lib/libc/arch/mips/sys')
-rw-r--r--lib/libc/arch/mips/sys/Ovfork.S10
-rw-r--r--lib/libc/arch/mips/sys/brk.S24
-rw-r--r--lib/libc/arch/mips/sys/cerror.S6
-rw-r--r--lib/libc/arch/mips/sys/exect.S11
-rw-r--r--lib/libc/arch/mips/sys/fork.S10
-rw-r--r--lib/libc/arch/mips/sys/pipe.S10
-rw-r--r--lib/libc/arch/mips/sys/ptrace.S11
-rw-r--r--lib/libc/arch/mips/sys/reboot.S10
-rw-r--r--lib/libc/arch/mips/sys/sbrk.S12
-rw-r--r--lib/libc/arch/mips/sys/setlogin.S11
-rw-r--r--lib/libc/arch/mips/sys/sigpending.S10
-rw-r--r--lib/libc/arch/mips/sys/sigprocmask.S10
-rw-r--r--lib/libc/arch/mips/sys/sigreturn.S7
-rw-r--r--lib/libc/arch/mips/sys/sigsuspend.S10
-rw-r--r--lib/libc/arch/mips/sys/syscall.S6
15 files changed, 46 insertions, 112 deletions
diff --git a/lib/libc/arch/mips/sys/Ovfork.S b/lib/libc/arch/mips/sys/Ovfork.S
index 5ea5d2d6827..e8e4d4aa689 100644
--- a/lib/libc/arch/mips/sys/Ovfork.S
+++ b/lib/libc/arch/mips/sys/Ovfork.S
@@ -1,3 +1,4 @@
+/* $OpenBSD: Ovfork.S,v 1.3 1996/07/30 20:27:57 pefo Exp $ */
/*-
* Copyright (c) 1991, 1993
* The Regents of the University of California. All rights reserved.
@@ -38,12 +39,9 @@
#if defined(LIBC_SCCS) && !defined(lint)
ASMSTR("from: @(#)Ovfork.s 8.1 (Berkeley) 6/4/93")
- ASMSTR("$Id: Ovfork.S,v 1.2 1996/05/16 11:16:07 pefo Exp $")
+ ASMSTR("$Id: Ovfork.S,v 1.3 1996/07/30 20:27:57 pefo Exp $")
#endif /* LIBC_SCCS and not lint */
-#ifdef ABICALLS
- .abicalls
-#endif
/*
* pid = vfork();
@@ -53,11 +51,7 @@
*/
LEAF(vfork)
-#ifdef ABICALLS
- .set noreorder
- .cpload t9
.set reorder
-#endif
li v0, SYS_vfork # system call number for vfork
syscall
beq a3, zero, 1f # jump if no errors
diff --git a/lib/libc/arch/mips/sys/brk.S b/lib/libc/arch/mips/sys/brk.S
index 797a798c7ae..357baaacc98 100644
--- a/lib/libc/arch/mips/sys/brk.S
+++ b/lib/libc/arch/mips/sys/brk.S
@@ -1,3 +1,4 @@
+/* $OpenBSD: brk.S,v 1.3 1996/07/30 20:27:57 pefo Exp $ */
/*-
* Copyright (c) 1991, 1993
* The Regents of the University of California. All rights reserved.
@@ -38,12 +39,9 @@
#if defined(LIBC_SCCS) && !defined(lint)
ASMSTR("from: @(#)brk.s 8.1 (Berkeley) 6/4/93")
- ASMSTR("$Id: brk.S,v 1.2 1996/05/16 11:16:08 pefo Exp $")
+ ASMSTR("$Id: brk.S,v 1.3 1996/07/30 20:27:57 pefo Exp $")
#endif /* LIBC_SCCS and not lint */
-#ifdef ABICALLS
- .abicalls
-#endif
.globl minbrk
.globl curbrk
@@ -53,15 +51,23 @@ minbrk: .word _C_LABEL(end)
.text
LEAF(brk)
-#ifdef ABICALLS
- .set noreorder
- .cpload t9
.set reorder
-#endif
lw v0, minbrk
bgeu a0, v0, _C_LABEL(_brk)
move a0, v0 # dont allow break < minbrk
-ALEAF(_brk)
+ li v0, SYS_break
+ syscall
+ bne a3, zero, 1f
+ sw a0, curbrk
+ move v0, zero
+ j ra
+1:
+ la t9, _C_LABEL(cerror)
+ jr t9
+END(brk)
+
+LEAF(_brk)
+ .set reorder
li v0, SYS_break
syscall
bne a3, zero, 1f
diff --git a/lib/libc/arch/mips/sys/cerror.S b/lib/libc/arch/mips/sys/cerror.S
index c74a2449b83..d0f237fb8c6 100644
--- a/lib/libc/arch/mips/sys/cerror.S
+++ b/lib/libc/arch/mips/sys/cerror.S
@@ -1,3 +1,4 @@
+/* $OpenBSD: cerror.S,v 1.3 1996/07/30 20:27:57 pefo Exp $ */
/*-
* Copyright (c) 1991, 1993
* The Regents of the University of California. All rights reserved.
@@ -38,12 +39,9 @@
#if defined(LIBC_SCCS) && !defined(lint)
ASMSTR("from: @(#)cerror.s 8.1 (Berkeley) 6/16/93")
- ASMSTR("$Id: cerror.S,v 1.2 1996/05/16 11:16:08 pefo Exp $")
+ ASMSTR("$Id: cerror.S,v 1.3 1996/07/30 20:27:57 pefo Exp $")
#endif /* LIBC_SCCS and not lint */
-#ifdef ABICALLS
- .abicalls
-#endif
.globl _C_LABEL(errno)
LEAF(cerror)
diff --git a/lib/libc/arch/mips/sys/exect.S b/lib/libc/arch/mips/sys/exect.S
index 6b5f30f8db0..d02177f87c9 100644
--- a/lib/libc/arch/mips/sys/exect.S
+++ b/lib/libc/arch/mips/sys/exect.S
@@ -1,3 +1,4 @@
+/* $OpenBSD: exect.S,v 1.3 1996/07/30 20:27:58 pefo Exp $ */
/*-
* Copyright (c) 1991, 1993
* The Regents of the University of California. All rights reserved.
@@ -38,19 +39,11 @@
#if defined(LIBC_SCCS) && !defined(lint)
ASMSTR("from: @(#)exect.s 8.1 (Berkeley) 6/4/93")
- ASMSTR("$Id: exect.S,v 1.2 1996/05/16 11:16:09 pefo Exp $")
+ ASMSTR("$Id: exect.S,v 1.3 1996/07/30 20:27:58 pefo Exp $")
#endif /* LIBC_SCCS and not lint */
-#ifdef ABICALLS
- .abicalls
-#endif
-
LEAF(exect)
-#ifdef ABICALLS
- .set noreorder
- .cpload t9
.set reorder
-#endif
li v0, SYS_execve
syscall
bne a3, zero, 1f
diff --git a/lib/libc/arch/mips/sys/fork.S b/lib/libc/arch/mips/sys/fork.S
index aa41a5918bb..4a41b33a9ee 100644
--- a/lib/libc/arch/mips/sys/fork.S
+++ b/lib/libc/arch/mips/sys/fork.S
@@ -1,3 +1,4 @@
+/* $OpenBSD: fork.S,v 1.3 1996/07/30 20:27:58 pefo Exp $ */
/*-
* Copyright (c) 1991, 1993
* The Regents of the University of California. All rights reserved.
@@ -38,19 +39,12 @@
#if defined(LIBC_SCCS) && !defined(lint)
ASMSTR("from: @(#)fork.s 8.1 (Berkeley) 6/4/93")
- ASMSTR("$Id: fork.S,v 1.2 1996/05/16 11:16:09 pefo Exp $")
+ ASMSTR("$Id: fork.S,v 1.3 1996/07/30 20:27:58 pefo Exp $")
#endif /* LIBC_SCCS and not lint */
-#ifdef ABICALLS
- .abicalls
-#endif
LEAF(fork)
-#ifdef ABICALLS
- .set noreorder
- .cpload t9
.set reorder
-#endif
li v0, SYS_fork # pid = fork()
syscall
bne a3, zero, 2f
diff --git a/lib/libc/arch/mips/sys/pipe.S b/lib/libc/arch/mips/sys/pipe.S
index 9a8e549cf95..1cacf5b1399 100644
--- a/lib/libc/arch/mips/sys/pipe.S
+++ b/lib/libc/arch/mips/sys/pipe.S
@@ -1,3 +1,4 @@
+/* $OpenBSD: pipe.S,v 1.3 1996/07/30 20:27:58 pefo Exp $ */
/*-
* Copyright (c) 1991, 1993
* The Regents of the University of California. All rights reserved.
@@ -38,19 +39,12 @@
#if defined(LIBC_SCCS) && !defined(lint)
ASMSTR("from: @(#)pipe.s 8.1 (Berkeley) 6/4/93")
- ASMSTR("$Id: pipe.S,v 1.2 1996/05/16 11:16:09 pefo Exp $")
+ ASMSTR("$Id: pipe.S,v 1.3 1996/07/30 20:27:58 pefo Exp $")
#endif /* LIBC_SCCS and not lint */
-#ifdef ABICALLS
- .abicalls
-#endif
LEAF(pipe)
-#ifdef ABICALLS
- .set noreorder
- .cpload t9
.set reorder
-#endif
li v0, SYS_pipe # pipe(fildes) int fildes[2];
syscall
bne a3, zero, 1f
diff --git a/lib/libc/arch/mips/sys/ptrace.S b/lib/libc/arch/mips/sys/ptrace.S
index 4f174b4e621..a8fad40d45d 100644
--- a/lib/libc/arch/mips/sys/ptrace.S
+++ b/lib/libc/arch/mips/sys/ptrace.S
@@ -1,3 +1,4 @@
+/* $OpenBSD: ptrace.S,v 1.3 1996/07/30 20:27:59 pefo Exp $ */
/*-
* Copyright (c) 1991, 1993
* The Regents of the University of California. All rights reserved.
@@ -38,19 +39,11 @@
#if defined(LIBC_SCCS) && !defined(lint)
ASMSTR("from: @(#)ptrace.s 8.1 (Berkeley) 6/4/93")
- ASMSTR("$Id: ptrace.S,v 1.2 1996/05/16 11:16:10 pefo Exp $")
+ ASMSTR("$Id: ptrace.S,v 1.3 1996/07/30 20:27:59 pefo Exp $")
#endif /* LIBC_SCCS and not lint */
-#ifdef ABICALLS
- .abicalls
-#endif
-
LEAF(ptrace)
-#ifdef ABICALLS
- .set noreorder
- .cpload t9
.set reorder
-#endif
sw zero, _C_LABEL(errno)
li v0, SYS_ptrace
syscall
diff --git a/lib/libc/arch/mips/sys/reboot.S b/lib/libc/arch/mips/sys/reboot.S
index 638f2fab47d..4a9cebe76ff 100644
--- a/lib/libc/arch/mips/sys/reboot.S
+++ b/lib/libc/arch/mips/sys/reboot.S
@@ -1,3 +1,4 @@
+/* $OpenBSD: reboot.S,v 1.3 1996/07/30 20:27:59 pefo Exp $ */
/*-
* Copyright (c) 1991, 1993
* The Regents of the University of California. All rights reserved.
@@ -38,21 +39,16 @@
#if defined(LIBC_SCCS) && !defined(lint)
ASMSTR("from: @(#)reboot.s 8.1 (Berkeley) 6/4/93")
- ASMSTR("$Id: reboot.S,v 1.2 1996/05/16 11:16:10 pefo Exp $")
+ ASMSTR("$Id: reboot.S,v 1.3 1996/07/30 20:27:59 pefo Exp $")
#endif /* LIBC_SCCS and not lint */
-#ifdef ABICALLS
- .abicalls
-#endif
LEAF(reboot)
#ifdef ABICALLS
- .set noreorder
- .cpload t9
- .set reorder
subu sp, sp, 32
.cprestore 16
#endif
+ .set reorder
li v0, SYS_reboot
syscall
bne a3, zero, 1f
diff --git a/lib/libc/arch/mips/sys/sbrk.S b/lib/libc/arch/mips/sys/sbrk.S
index 5d5ac98fe62..4f4bfaeef23 100644
--- a/lib/libc/arch/mips/sys/sbrk.S
+++ b/lib/libc/arch/mips/sys/sbrk.S
@@ -1,3 +1,4 @@
+/* $OpenBSD: sbrk.S,v 1.3 1996/07/30 20:27:59 pefo Exp $ */
/*-
* Copyright (c) 1991, 1993
* The Regents of the University of California. All rights reserved.
@@ -38,13 +39,9 @@
#if defined(LIBC_SCCS) && !defined(lint)
ASMSTR("from: @(#)sbrk.s 8.1 (Berkeley) 6/4/93")
- ASMSTR("$Id: sbrk.S,v 1.2 1996/05/16 11:16:11 pefo Exp $")
+ ASMSTR("$Id: sbrk.S,v 1.3 1996/07/30 20:27:59 pefo Exp $")
#endif /* LIBC_SCCS and not lint */
-#ifdef ABICALLS
- .abicalls
-#endif
-
.globl curbrk
.data
@@ -52,15 +49,12 @@ curbrk: .word _C_LABEL(end)
.text
LEAF(sbrk)
-#ifdef ABICALLS
- .set noreorder
- .cpload t9
.set reorder
-#endif
lw v1, curbrk
li v0, SYS_break
addu a0, a0, v1 # compute current break
syscall
+
bne a3, zero, 1f
move v0, v1 # return old val of curbrk from above
sw a0, curbrk # save current val of curbrk from above
diff --git a/lib/libc/arch/mips/sys/setlogin.S b/lib/libc/arch/mips/sys/setlogin.S
index 4b2b66a50b0..8e3297ccad8 100644
--- a/lib/libc/arch/mips/sys/setlogin.S
+++ b/lib/libc/arch/mips/sys/setlogin.S
@@ -1,3 +1,4 @@
+/* $OpenBSD: setlogin.S,v 1.3 1996/07/30 20:28:00 pefo Exp $ */
/*-
* Copyright (c) 1991, 1993
* The Regents of the University of California. All rights reserved.
@@ -38,21 +39,15 @@
#if defined(LIBC_SCCS) && !defined(lint)
ASMSTR("from: @(#)setlogin.s 8.1 (Berkeley) 6/4/93")
- ASMSTR("$Id: setlogin.S,v 1.2 1996/05/16 11:16:11 pefo Exp $")
+ ASMSTR("$Id: setlogin.S,v 1.3 1996/07/30 20:28:00 pefo Exp $")
#endif /* LIBC_SCCS and not lint */
-#ifdef ABICALLS
- .abicalls
-#endif
LEAF(setlogin)
-#ifdef ABICALLS
- .set noreorder
- .cpload t9
.set reorder
-#endif
li v0, SYS_setlogin # setlogin(name)
syscall
+
bne a3, zero, 1f
sw zero, _C_LABEL(__logname_valid) # in getlogin()
j ra
diff --git a/lib/libc/arch/mips/sys/sigpending.S b/lib/libc/arch/mips/sys/sigpending.S
index 1e23b009206..8c6729bb806 100644
--- a/lib/libc/arch/mips/sys/sigpending.S
+++ b/lib/libc/arch/mips/sys/sigpending.S
@@ -1,3 +1,4 @@
+/* $OpenBSD: sigpending.S,v 1.3 1996/07/30 20:28:00 pefo Exp $ */
/*-
* Copyright (c) 1991, 1993
* The Regents of the University of California. All rights reserved.
@@ -38,19 +39,12 @@
#if defined(LIBC_SCCS) && !defined(lint)
ASMSTR("from: @(#)sigpending.s 8.1 (Berkeley) 6/4/93")
- ASMSTR("$Id: sigpending.S,v 1.2 1996/05/16 11:16:12 pefo Exp $")
+ ASMSTR("$Id: sigpending.S,v 1.3 1996/07/30 20:28:00 pefo Exp $")
#endif /* LIBC_SCCS and not lint */
-#ifdef ABICALLS
- .abicalls
-#endif
LEAF(sigpending)
-#ifdef ABICALLS
- .set noreorder
- .cpload t9
.set reorder
-#endif
li v0, SYS_sigpending # setlogin(name)
syscall
bne a3, zero, 1f
diff --git a/lib/libc/arch/mips/sys/sigprocmask.S b/lib/libc/arch/mips/sys/sigprocmask.S
index 2b2b51d4463..52e083b4ade 100644
--- a/lib/libc/arch/mips/sys/sigprocmask.S
+++ b/lib/libc/arch/mips/sys/sigprocmask.S
@@ -1,3 +1,4 @@
+/* $OpenBSD: sigprocmask.S,v 1.3 1996/07/30 20:28:01 pefo Exp $ */
/*-
* Copyright (c) 1991, 1993
* The Regents of the University of California. All rights reserved.
@@ -38,19 +39,12 @@
#if defined(LIBC_SCCS) && !defined(lint)
ASMSTR("from: @(#)sigprocmask.s 8.1 (Berkeley) 6/4/93")
- ASMSTR("$Id: sigprocmask.S,v 1.2 1996/05/16 11:16:12 pefo Exp $")
+ ASMSTR("$Id: sigprocmask.S,v 1.3 1996/07/30 20:28:01 pefo Exp $")
#endif /* LIBC_SCCS and not lint */
-#ifdef ABICALLS
- .abicalls
-#endif
LEAF(sigprocmask) # sigprocmask(how, new, old) sigset_t *new, *old;
-#ifdef ABICALLS
- .set noreorder
- .cpload t9
.set reorder
-#endif
bne a1, zero, gotptr # if new sigset pointer not null
li a0, 1 # how = SIG_BLOCK
b doit # mask = zero
diff --git a/lib/libc/arch/mips/sys/sigreturn.S b/lib/libc/arch/mips/sys/sigreturn.S
index 7af4c5be2ce..5b0513cf462 100644
--- a/lib/libc/arch/mips/sys/sigreturn.S
+++ b/lib/libc/arch/mips/sys/sigreturn.S
@@ -1,3 +1,4 @@
+/* $OpenBSD: sigreturn.S,v 1.3 1996/07/30 20:28:01 pefo Exp $ */
/*-
* Copyright (c) 1991, 1993
* The Regents of the University of California. All rights reserved.
@@ -38,13 +39,9 @@
#if defined(LIBC_SCCS) && !defined(lint)
ASMSTR("from: @(#)sigreturn.s 8.1 (Berkeley) 6/4/93")
- ASMSTR("$Id: sigreturn.S,v 1.2 1996/05/16 11:16:13 pefo Exp $")
+ ASMSTR("$Id: sigreturn.S,v 1.3 1996/07/30 20:28:01 pefo Exp $")
#endif /* LIBC_SCCS and not lint */
-#ifdef ABICALLS
- .abicalls
-#endif
-
/*
* We must preserve the state of the registers as the user has set them up.
*/
diff --git a/lib/libc/arch/mips/sys/sigsuspend.S b/lib/libc/arch/mips/sys/sigsuspend.S
index d7edf2a3077..062c490df1c 100644
--- a/lib/libc/arch/mips/sys/sigsuspend.S
+++ b/lib/libc/arch/mips/sys/sigsuspend.S
@@ -1,3 +1,4 @@
+/* $OpenBSD: sigsuspend.S,v 1.3 1996/07/30 20:28:01 pefo Exp $ */
/*-
* Copyright (c) 1991, 1993
* The Regents of the University of California. All rights reserved.
@@ -38,19 +39,12 @@
#if defined(LIBC_SCCS) && !defined(lint)
ASMSTR("from: @(#)sigsuspend.s 8.1 (Berkeley) 6/4/93")
- ASMSTR("$Id: sigsuspend.S,v 1.2 1996/05/16 11:16:13 pefo Exp $")
+ ASMSTR("$Id: sigsuspend.S,v 1.3 1996/07/30 20:28:01 pefo Exp $")
#endif /* LIBC_SCCS and not lint */
-#ifdef ABICALLS
- .abicalls
-#endif
LEAF(sigsuspend)
-#ifdef ABICALLS
- .set noreorder
- .cpload t9
.set reorder
-#endif
lw a0, 0(a0) # indirect to mask arg
li v0, SYS_sigsuspend
syscall
diff --git a/lib/libc/arch/mips/sys/syscall.S b/lib/libc/arch/mips/sys/syscall.S
index 8ea3e16d6cb..76363245cbb 100644
--- a/lib/libc/arch/mips/sys/syscall.S
+++ b/lib/libc/arch/mips/sys/syscall.S
@@ -1,3 +1,4 @@
+/* $OpenBSD: syscall.S,v 1.3 1996/07/30 20:28:02 pefo Exp $ */
/*-
* Copyright (c) 1991, 1993
* The Regents of the University of California. All rights reserved.
@@ -38,13 +39,10 @@
#if defined(LIBC_SCCS) && !defined(lint)
ASMSTR("from: @(#)syscall.s 8.1 (Berkeley) 6/4/93")
- ASMSTR("$Id: syscall.S,v 1.2 1996/05/16 11:16:13 pefo Exp $")
+ ASMSTR("$Id: syscall.S,v 1.3 1996/07/30 20:28:02 pefo Exp $")
#endif /* LIBC_SCCS and not lint */
#define SYS_syscall 0
-#ifdef ABICALLS
- .abicalls
-#endif
RSYSCALL(syscall)