* sysdeps/sparc/sparc32/elf/start.S: Likewise.
* sysdeps/sparc/sparc64/dl-trampoline.S: Likewise.
* sysdeps/sparc/sparc64/elf/start.S: Likewise.
* sysdeps/sparc/sparc32/memchr.S: Rearrange code to reside
within ENTRY/END.
* sysdeps/sparc/sparc32/memcpy.S: Likewise.
* sysdeps/sparc/sparc32/stpcpy.S: Likewise.
* sysdeps/sparc/sparc32/strcat.S: Likewise.
* sysdeps/sparc/sparc32/strchr.S: Likewise.
* sysdeps/sparc/sparc32/strcmp.S: Likewise.
* sysdeps/sparc/sparc32/strcpy.S: Likewise.
* sysdeps/sparc/sparc32/strlen.S: Likewise.
* sysdeps/sparc/sparc64/memcpy.S: Likewise.
* sysdeps/sparc/sparc64/sparcv9v/memset.S: Likewise.
* sysdeps/unix/sysv/linux/sparc/sparc32/clone.S: Add CFI markings
and use __syscall_error.
* sysdeps/unix/sysv/linux/sparc/sparc64/clone.S: Likewise.
* sysdeps/unix/sysv/linux/sparc/sparc64/brk.S: Likewise.
* sysdeps/unix/sysv/linux/sparc/sparc32/pipe.S: Use __syscall_error.
* sysdeps/unix/sysv/linux/sparc/sparc64/pipe.S: Likewise.
* sysdeps/unix/sysv/linux/sparc/sparc32/socket.S: Likewise.
* sysdeps/unix/sysv/linux/sparc/sparc64/socket.S: Likewise.
* sysdeps/unix/sysv/linux/sparc/sparc32/syscall.S: Likewise.
* sysdeps/unix/sysv/linux/sparc/sparc64/syscall.S: Likewise.
* sysdeps/unix/sysv/linux/sparc/sparc32/sysdep.h: Rewrite to use
CFI markings and __syscall_error.
* sysdeps/unix/sysv/linux/sparc/sparc64/sysdep.h: Likewise.
* sysdeps/unix/sysv/linux/sparc/sparc64/setcontext.S: Rearrange
code to reside within ENTRY/END.
* sysdeps/unix/sysv/linux/sparc/sparc64/setjmp.S: Likewise.
* sysdeps/unix/sysv/linux/sparc/sysdep.c: New file.
* sysdeps/unix/sysv/linux/sparc/sysdep.S: File removed.
* sysdeps/unix/sysv/linux/sparc/rt-sysdep.c: New file.
* sysdeps/unix/sysv/linux/sparc/Makefile (librt-routines): Add it.
2006-03-05 David S. Miller <davem@sunset.davemloft.net>
+ * sysdeps/sparc/sparc32/dl-trampoline.S: Add CFI markings.
+ * sysdeps/sparc/sparc32/elf/start.S: Likewise.
+ * sysdeps/sparc/sparc64/dl-trampoline.S: Likewise.
+ * sysdeps/sparc/sparc64/elf/start.S: Likewise.
+ * sysdeps/sparc/sparc32/memchr.S: Rearrange code to reside
+ within ENTRY/END.
+ * sysdeps/sparc/sparc32/memcpy.S: Likewise.
+ * sysdeps/sparc/sparc32/stpcpy.S: Likewise.
+ * sysdeps/sparc/sparc32/strcat.S: Likewise.
+ * sysdeps/sparc/sparc32/strchr.S: Likewise.
+ * sysdeps/sparc/sparc32/strcmp.S: Likewise.
+ * sysdeps/sparc/sparc32/strcpy.S: Likewise.
+ * sysdeps/sparc/sparc32/strlen.S: Likewise.
+ * sysdeps/sparc/sparc64/memcpy.S: Likewise.
+ * sysdeps/sparc/sparc64/sparcv9v/memset.S: Likewise.
+ * sysdeps/unix/sysv/linux/sparc/sparc32/clone.S: Add CFI markings
+ and use __syscall_error.
+ * sysdeps/unix/sysv/linux/sparc/sparc64/clone.S: Likewise.
+ * sysdeps/unix/sysv/linux/sparc/sparc64/brk.S: Likewise.
+ * sysdeps/unix/sysv/linux/sparc/sparc32/pipe.S: Use __syscall_error.
+ * sysdeps/unix/sysv/linux/sparc/sparc64/pipe.S: Likewise.
+ * sysdeps/unix/sysv/linux/sparc/sparc32/socket.S: Likewise.
+ * sysdeps/unix/sysv/linux/sparc/sparc64/socket.S: Likewise.
+ * sysdeps/unix/sysv/linux/sparc/sparc32/syscall.S: Likewise.
+ * sysdeps/unix/sysv/linux/sparc/sparc64/syscall.S: Likewise.
+ * sysdeps/unix/sysv/linux/sparc/sparc32/sysdep.h: Rewrite to use
+ CFI markings and __syscall_error.
+ * sysdeps/unix/sysv/linux/sparc/sparc64/sysdep.h: Likewise.
+ * sysdeps/unix/sysv/linux/sparc/sparc64/setcontext.S: Rearrange
+ code to reside within ENTRY/END.
+ * sysdeps/unix/sysv/linux/sparc/sparc64/setjmp.S: Likewise.
+ * sysdeps/unix/sysv/linux/sparc/sysdep.c: New file.
+ * sysdeps/unix/sysv/linux/sparc/sysdep.S: File removed.
+ * sysdeps/unix/sysv/linux/sparc/rt-sysdep.c: New file.
+ * sysdeps/unix/sysv/linux/sparc/Makefile (librt-routines): Add it.
+
* shlib-versions: Use sparc64.*- for CPU patterns.
2006-03-05 Roland McGrath <roland@frob.com>
+2006-03-05 Roland McGrath <roland@redhat.com>
+
+ * configure (libc_add_on): Disable add-on when $add_ons_automatic = yes
+ and $config_os doesn't match *linux*.
+
2006-03-05 David S. Miller <davem@sunset.davemloft.net>
* sysdeps/unix/sysv/linux/sparc/sparc32/pt-vfork.S:
# as a subdirectory to search for in other add-ons' sysdeps trees.
libc_add_on_canonical=nptl
+
+# Only linux configurations support NPTL.
+if test $add_ons_automatic = yes; then
+ case "$config_os" in
+ *linux*) ;;
+ *) libc_add_on= ;;
+ esac
+fi
--- /dev/null
+# pull in __syscall_error routine
+libpthread-routines += sysdep
#include <tcb-offsets.h>
.text
+ .globl __syscall_error
ENTRY(__vfork)
ld [%g7 + PID], %o5
sub %g0, %o5, %o4
LOADSYSCALL(vfork)
ta 0x10
- bcs,a __syscall_error_handler
- st %o5, [%g7 + PID]
- SYSCALL_ERROR_HANDLER
- sub %o1, 1, %o1
+ bcc 2f
+ mov %o7, %g1
+ st %o5, [%g7 + PID]
+ call __syscall_error
+ mov %g1, %o7
+2: sub %o1, 1, %o1
andcc %o0, %o1, %o0
bne,a 1f
st %o5, [%g7 + PID]
1: retl
nop
+END(__vfork)
-PSEUDO_END (__vfork)
weak_alias (__vfork, vfork)
#if !defined NOT_IN_libc || defined IS_IN_libpthread || defined IS_IN_librt
# undef PSEUDO
-# define PSEUDO(name, syscall_name, args) \
- .text; \
-ENTRY(name) \
- ld [%g7 + MULTIPLE_THREADS_OFFSET], %g1; \
- cmp %g1, 0; \
- bne 1f; \
-.type __##syscall_name##_nocancel,@function; \
-.globl __##syscall_name##_nocancel; \
-__##syscall_name##_nocancel: \
- mov SYS_ify(syscall_name), %g1; \
- ta 0x10; \
- bcs __syscall_error_handler; \
- nop; \
-.size __##syscall_name##_nocancel,.-__##syscall_name##_nocancel; \
- .subsection 2; \
- cfi_startproc; \
-1: save %sp, -96, %sp; \
- cfi_def_cfa_register (%fp); \
- cfi_window_save; \
- cfi_register (%o7, %i7); \
- CENABLE; \
- nop; \
- mov %o0, %l0; \
- COPY_ARGS_##args \
- mov SYS_ify(syscall_name), %g1; \
- ta 0x10; \
- bcs __syscall_error_handler2; \
- mov %o0, %l1; \
- CDISABLE; \
- mov %l0, %o0; \
- jmpl %i7 + 8, %g0; \
- restore %g0, %l1, %o0; \
- cfi_endproc; \
- .previous; \
- SYSCALL_ERROR_HANDLER \
- SYSCALL_ERROR_HANDLER2
+# define PSEUDO(name, syscall_name, args) \
+ .text; \
+ .globl __syscall_error; \
+ENTRY(name) \
+ ld [%g7 + MULTIPLE_THREADS_OFFSET], %g1;\
+ cmp %g1, 0; \
+ bne 1f; \
+.type __##syscall_name##_nocancel,@function; \
+.globl __##syscall_name##_nocancel; \
+__##syscall_name##_nocancel: \
+ mov SYS_ify(syscall_name), %g1; \
+ ta 0x10; \
+ bcc 8f; \
+ mov %o7, %g1; \
+ call __syscall_error; \
+ mov %g1, %o7; \
+8: jmpl %o7 + 8, %g0; \
+ nop; \
+.size __##syscall_name##_nocancel,.-__##syscall_name##_nocancel;\
+1: save %sp, -96, %sp; \
+ cfi_def_cfa_register(%fp); \
+ cfi_window_save; \
+ cfi_register(%o7, %i7); \
+ CENABLE; \
+ nop; \
+ mov %o0, %l0; \
+ COPY_ARGS_##args \
+ mov SYS_ify(syscall_name), %g1; \
+ ta 0x10; \
+ bcc 1f; \
+ mov %o0, %l1; \
+ CDISABLE; \
+ mov %l0, %o0; \
+ call __syscall_error; \
+ mov %l1, %o0; \
+ b 2f; \
+ mov -1, %l1; \
+1: CDISABLE; \
+ mov %l0, %o0; \
+2: jmpl %i7 + 8, %g0; \
+ restore %g0, %l1, %o0;
-#define SYSCALL_ERROR_HANDLER2 \
-SYSCALL_ERROR_HANDLER_ENTRY(__syscall_error_handler2) \
- .global __errno_location; \
- .type __errno_location,@function; \
- CDISABLE; \
- mov %l0, %o0; \
- call __errno_location; \
- nop; \
- st %l1, [%o0]; \
- jmpl %i7 + 8, %g0; \
- restore %g0, -1, %o0; \
- .previous;
# ifdef IS_IN_libpthread
# define CENABLE call __pthread_enable_asynccancel
#include <tcb-offsets.h>
.text
+ .globl __syscall_error
ENTRY(__vfork)
ld [%g7 + PID], %o5
cmp %o5, 0
LOADSYSCALL(vfork)
ta 0x10
- bcs,a __syscall_error_handler
- st %o5, [%g7 + PID]
- SYSCALL_ERROR_HANDLER
- sub %o1, 1, %o1
+ bcc 2f
+ mov %o7, %g1
+ st %o5, [%g7 + PID]
+ call __syscall_error
+ mov %g1, %o7
+2: sub %o1, 1, %o1
andcc %o0, %o1, %o0
bne,a 1f
st %o5, [%g7 + PID]
1: retl
nop
+END(__vfork)
-PSEUDO_END (__vfork)
libc_hidden_def (__vfork)
weak_alias (__vfork, vfork)
#include <tcb-offsets.h>
.text
+ .globl __syscall_error
ENTRY(__vfork)
ld [%g7 + PID], %o5
sub %g0, %o5, %o4
LOADSYSCALL(vfork)
ta 0x6d
- bcs,a,pn %xcc, __syscall_error_handler
- st %o5, [%g7 + PID]
- SYSCALL_ERROR_HANDLER
- sub %o1, 1, %o1
+ bcc,pt %xcc, 2f
+ mov %o7, %g1
+ st %o5, [%g7 + PID]
+ call __syscall_error
+ mov %g1, %o7
+2: sub %o1, 1, %o1
andcc %o0, %o1, %o0
bne,a,pt %icc, 1f
st %o5, [%g7 + PID]
1: retl
nop
+END(__vfork)
-PSEUDO_END (__vfork)
weak_alias (__vfork, vfork)
#if !defined NOT_IN_libc || defined IS_IN_libpthread || defined IS_IN_librt
# undef PSEUDO
-# define PSEUDO(name, syscall_name, args) \
- .text; \
-ENTRY(name) \
- ld [%g7 + MULTIPLE_THREADS_OFFSET], %g1; \
- brnz,pn %g1, 1f; \
-.type __##syscall_name##_nocancel,@function; \
-.globl __##syscall_name##_nocancel; \
-__##syscall_name##_nocancel: \
- mov SYS_ify(syscall_name), %g1; \
- ta 0x6d; \
- bcs,pn %xcc, __syscall_error_handler; \
- nop; \
-.size __##syscall_name##_nocancel,.-__##syscall_name##_nocancel; \
- .subsection 2; \
- cfi_startproc; \
-1: save %sp, -192, %sp; \
- cfi_def_cfa_register (%fp); \
- cfi_window_save; \
- cfi_register (%o7, %i7); \
- CENABLE; \
- nop; \
- mov %o0, %l0; \
- COPY_ARGS_##args \
- mov SYS_ify(syscall_name), %g1; \
- ta 0x6d; \
- bcs,pn %xcc, __syscall_error_handler2; \
- mov %o0, %l1; \
- CDISABLE; \
- mov %l0, %o0; \
- jmpl %i7 + 8, %g0; \
- restore %g0, %l1, %o0; \
- cfi_endproc; \
- .previous; \
- SYSCALL_ERROR_HANDLER \
- SYSCALL_ERROR_HANDLER2
-
-#define SYSCALL_ERROR_HANDLER2 \
-SYSCALL_ERROR_HANDLER_ENTRY(__syscall_error_handler2) \
- .global __errno_location; \
- .type __errno_location,@function; \
- CDISABLE; \
- mov %l0, %o0; \
- call __errno_location; \
- nop; \
- st %l1, [%o0]; \
- jmpl %i7 + 8, %g0; \
- restore %g0, -1, %o0; \
- .previous;
+# define PSEUDO(name, syscall_name, args) \
+ .text; \
+ .globl __syscall_error; \
+ENTRY(name) \
+ ld [%g7 + MULTIPLE_THREADS_OFFSET], %g1;\
+ brnz,pn %g1, 1f; \
+.type __##syscall_name##_nocancel,@function; \
+.globl __##syscall_name##_nocancel; \
+__##syscall_name##_nocancel: \
+ mov SYS_ify(syscall_name), %g1; \
+ ta 0x6d; \
+ bcc,pt %xcc, 8f; \
+ mov %o7, %g1; \
+ call __syscall_error; \
+ mov %g1, %o7; \
+8: jmpl %o7 + 8, %g0; \
+ nop; \
+.size __##syscall_name##_nocancel,.-__##syscall_name##_nocancel;\
+1: save %sp, -192, %sp; \
+ cfi_def_cfa_register(%fp); \
+ cfi_window_save; \
+ cfi_register(%o7, %i7); \
+ CENABLE; \
+ nop; \
+ mov %o0, %l0; \
+ COPY_ARGS_##args \
+ mov SYS_ify(syscall_name), %g1; \
+ ta 0x6d; \
+ bcc,pt %xcc, 1f; \
+ mov %o0, %l1; \
+ CDISABLE; \
+ mov %l0, %o0; \
+ call __syscall_error; \
+ mov %l1, %o0; \
+ ba,pt %xcc, 2f; \
+ mov -1, %l1; \
+1: CDISABLE; \
+ mov %l0, %o0; \
+2: jmpl %i7 + 8, %g0; \
+ restore %g0, %l1, %o0;
# ifdef IS_IN_libpthread
# define CENABLE call __pthread_enable_asynccancel
#include <tcb-offsets.h>
.text
+ .globl __syscall_error
ENTRY(__vfork)
ld [%g7 + PID], %o5
sethi %hi(0x80000000), %o3
LOADSYSCALL(vfork)
ta 0x6d
- bcs,a,pn %xcc, __syscall_error_handler
- st %o5, [%g7 + PID]
- SYSCALL_ERROR_HANDLER
- sub %o1, 1, %o1
+ bcc,pt %xcc, 2f
+ mov %o7, %g1
+ st %o5, [%g7 + PID]
+ call __syscall_error
+ mov %g1, %o7
+2: sub %o1, 1, %o1
andcc %o0, %o1, %o0
bne,a,pt %icc, 1f
st %o5, [%g7 + PID]
1: retl
nop
+END(__vfork)
-PSEUDO_END (__vfork)
libc_hidden_def (__vfork)
weak_alias (__vfork, vfork)