-/* Copyright (C) 1999, 2000, 2002 Free Software Foundation, Inc.
+/* Copyright (C) 1999-2014 Free Software Foundation, Inc.
This file is part of the GNU C Library.
The GNU C Library is free software; you can redistribute it and/or
Lesser General Public License for more details.
You should have received a copy of the GNU Lesser General Public
- License along with the GNU C Library; if not, write to the Free
- Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
- 02111-1307 USA. */
+ License along with the GNU C Library; if not, see
+ <http://www.gnu.org/licenses/>. */
#include <sysdep.h>
#define _ERRNO_H 1
mov.w .L1, r1
cmp/eq r1, r0
bt 2f
- mov.l .L2, r1
-#ifdef SHARED
- mov r0, r4
- mov.l r12, @-r15
- sts.l pr, @-r15
- mov.l 0f, r12
- mova 0f, r0
- add r0, r12
- mova .L2, r0
- add r0, r1
- jsr @r1
+ bra .Lsyscall_error
nop
- lds.l @r15+, pr
- rts
- mov.l @r15+, r12
- .align 2
-0:
- .long _GLOBAL_OFFSET_TABLE_
-#else
- jmp @r1
- mov r0, r4
-#endif
.L1:
.word -ENOSYS
.L3: .word __NR_vfork
shad r2, r1
not r1, r1 // r1=0 means r0 = -1 to -4095
tst r1, r1 // i.e. error in linux
- bf 1f
- mov.l .L2, r1
-#ifdef SHARED
- mov r0, r4
- mov.l r12, @-r15
- sts.l pr, @-r15
- mov.l 0f, r12
- mova 0f, r0
- add r0, r12
- mova .L2, r0
- add r0, r1
- jsr @r1
- nop
- lds.l @r15+, pr
- rts
- mov.l @r15+, r12
- .align 2
-0:
- .long _GLOBAL_OFFSET_TABLE_
-#else
- jmp @r1
- mov r0, r4
-#endif
- .align 2
-.L2:
- .long PLTJMP(C_SYMBOL_NAME(__syscall_error))
-1:
+ bf .Lpseudo_end
+.Lsyscall_error:
+ SYSCALL_ERROR_HANDLER
+.Lpseudo_end:
rts
nop
PSEUDO_END (__vfork)
-strong_alias (__vfork, __GI___vfork)
+libc_hidden_def (__vfork)
weak_alias (__vfork, vfork)