summaryrefslogtreecommitdiffstats
path: root/libc/arch-arm/syscalls/sigpending.S
diff options
context:
space:
mode:
authorMatthieu Castet <matthieu.castet@gmail.com>2013-01-16 14:02:50 +0100
committerMatthieu Castet <matthieu.castet@gmail.com>2013-01-16 14:53:37 +0100
commitfaa0fdb1194172f578f973097d61e580bce528dc (patch)
treed4202960694635613c2bcebb69c198e0345d603a /libc/arch-arm/syscalls/sigpending.S
parent791e26d9598a72376b8a16a5ccfb5d1ae0010965 (diff)
downloadbionic-faa0fdb1194172f578f973097d61e580bce528dc.zip
bionic-faa0fdb1194172f578f973097d61e580bce528dc.tar.gz
bionic-faa0fdb1194172f578f973097d61e580bce528dc.tar.bz2
arm syscall : for eabi call_default don't use stack
In the default case, we don't need to use the stack, we can save r7 with ip register (that what does eglibc). This allow to fix vfork data corruption (see 3884bfe9661955543ce203c60f9225bbdf33f6bb), because vfork now don't use the stack.
Diffstat (limited to 'libc/arch-arm/syscalls/sigpending.S')
-rw-r--r--libc/arch-arm/syscalls/sigpending.S5
1 files changed, 2 insertions, 3 deletions
diff --git a/libc/arch-arm/syscalls/sigpending.S b/libc/arch-arm/syscalls/sigpending.S
index 4c7d919..b541288 100644
--- a/libc/arch-arm/syscalls/sigpending.S
+++ b/libc/arch-arm/syscalls/sigpending.S
@@ -3,11 +3,10 @@
#include <sys/linux-syscalls.h>
ENTRY(sigpending)
- .save {r4, r7}
- stmfd sp!, {r4, r7}
+ mov ip, r7
ldr r7, =__NR_sigpending
swi #0
- ldmfd sp!, {r4, r7}
+ mov r7, ip
movs r0, r0
bxpl lr
b __set_syscall_errno