aboutsummaryrefslogtreecommitdiff
path: root/lib/libc/i386/sys/sigprocmask.S
diff options
context:
space:
mode:
authorPeter Wemm <peter@FreeBSD.org>1996-05-05 07:56:21 +0000
committerPeter Wemm <peter@FreeBSD.org>1996-05-05 07:56:21 +0000
commitf1703dfbaa221da46f40b698359be2b048e5d6ad (patch)
treebea8a07c70223c0e39939063c6dbbdf8eb9d0f17 /lib/libc/i386/sys/sigprocmask.S
parent257d5892a386439d8e2a59815d6b68e4f71e14ed (diff)
downloadsrc-f1703dfbaa221da46f40b698359be2b048e5d6ad.tar.gz
src-f1703dfbaa221da46f40b698359be2b048e5d6ad.zip
Add support to enable libc to be compiled in ELF format. (#ifdef __ELF__)
In a nutshell, this macroizes the local/global symbol scoping rules that are different in a.out and ELF. It also makes the i386 assembler stubs conform to i386 PIC calling conventions - the a.out ld.so didn't object, but the ELF one needs it as it implements PIC jumps via PLT's as well as calls. The a.out rtld only worked because it was accidently snooping the grandparent calling function's return address off the stack.. This also affects the libc_r code a little, because of cpp macro nesting.
Notes
Notes: svn path=/head/; revision=15634
Diffstat (limited to 'lib/libc/i386/sys/sigprocmask.S')
-rw-r--r--lib/libc/i386/sys/sigprocmask.S11
1 files changed, 6 insertions, 5 deletions
diff --git a/lib/libc/i386/sys/sigprocmask.S b/lib/libc/i386/sys/sigprocmask.S
index 69c50a407472..1f48c6b7c022 100644
--- a/lib/libc/i386/sys/sigprocmask.S
+++ b/lib/libc/i386/sys/sigprocmask.S
@@ -33,18 +33,19 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $Id: sigprocmask.S,v 1.2 1995/01/23 01:30:11 davidg Exp $
+ * $Id: sigprocmask.S,v 1.3 1996/01/22 00:00:59 julian Exp $
*/
#if defined(SYSLIBC_RCS) && !defined(lint)
.text
- .asciz "$Id: sigprocmask.S,v 1.2 1995/01/23 01:30:11 davidg Exp $"
+ .asciz "$Id: sigprocmask.S,v 1.3 1996/01/22 00:00:59 julian Exp $"
#endif /* SYSLIBC_RCS and not lint */
#include "SYS.h"
err:
- jmp cerror
+ PIC_PROLOGUE
+ jmp PIC_PLT(HIDENAME(cerror))
#ifdef _THREAD_SAFE
ENTRY(_thread_sys_sigprocmask)
@@ -59,8 +60,8 @@ ENTRY(sigprocmask)
jmp 2f
1: movl (%ecx),%ecx # fetch indirect ...
movl %ecx,8(%esp) # to new mask arg
-2: movl $ SYS_sigprocmask , %eax
- LCALL(0x7,0)
+2: lea SYS_sigprocmask,%eax
+ KERNCALL
jb err
movl 12(%esp),%ecx # fetch old mask requested
cmpl $0,%ecx # test if old mask requested