minix/lib/libc/arch/i386/sys-minix/__sigreturn.S
Antoine Leca 3a0aa55040 libc: make MINIX assembly code position-independent
While here, simplify ucontext.S

	. makes libc link without the messy DT_TEXTREL warning.

Change-Id: I4656d9068eab5ed2fa1e391242883d5dd9d93644
2013-08-09 11:09:51 +02:00

16 lines
489 B
ArmAsm

/* This routine is the low-level code for returning from signals. */
/* It calls _sigreturn, which is the normal "system call" routine. */
/* Both __sigreturn and _sigreturn are needed. */
#include <machine/asm.h>
IMPORT(_sigreturn)
ENTRY(__sigreturn)
addl $16, %esp
#ifndef PIC
jmp _C_LABEL(_sigreturn)
#else
PIC_PROLOGUE /* push %ebx, but we do not care */
pop %eax /* special knowledge of how PIC works: discard pushed EBX */
jmp PIC_PLT(_C_LABEL(_sigreturn))
#endif /* PIC */