aboutsummaryrefslogtreecommitdiff
path: root/sysdeps
diff options
context:
space:
mode:
authorSzabolcs Nagy <szabolcs.nagy@arm.com>2021-06-25 19:58:59 +0100
committerSzabolcs Nagy <szabolcs.nagy@arm.com>2021-06-28 11:35:44 +0100
commit3101b967874fb7d54a23f75fe93c310143e64af6 (patch)
treef53cb054992f3e1703f74b0626d8ccb4534861df /sysdeps
parent30639e79d3370243ee5ef3a029204a4c71e15856 (diff)
downloadglibc-3101b967874fb7d54a23f75fe93c310143e64af6.zip
glibc-3101b967874fb7d54a23f75fe93c310143e64af6.tar.gz
glibc-3101b967874fb7d54a23f75fe93c310143e64af6.tar.bz2
arm: align stack in clone [BZ 28020]
The arm PCS requires 8 byte aligned stack at function entry. Previously unaligned stack could crash the clone child. Fixes bug 28020.
Diffstat (limited to 'sysdeps')
-rw-r--r--sysdeps/unix/sysv/linux/arm/clone.S2
1 files changed, 2 insertions, 0 deletions
diff --git a/sysdeps/unix/sysv/linux/arm/clone.S b/sysdeps/unix/sysv/linux/arm/clone.S
index 44eefee..05596cb 100644
--- a/sysdeps/unix/sysv/linux/arm/clone.S
+++ b/sysdeps/unix/sysv/linux/arm/clone.S
@@ -31,6 +31,8 @@
ENTRY(__clone)
@ sanity check args
cmp r0, #0
+ @ align sp
+ and r1, r1, #-8
ite ne
cmpne r1, #0
moveq r0, #-EINVAL