[PATCH] alpha: Fix clone exit syscall argument passing (BZ#21512)

Adhemerval Zanella adhemerval.zanella@linaro.org
Wed Jul 19 14:49:00 GMT 2017


This patch fixes the argument passing for exit syscall after
the clone function returns on hppa.  This fixes misc/tst-clone2
on alpha-linux-gnu.

Checked misc/tst-clone2 on alpha-linux-gnu.  I will commit this shortly if
no one opposes.

	[BZ #21512]
	* sysdeps/unix/sysv/linux/alpha/clone.S (__clone): Fix argument
	passing to syscall exit.
---
 ChangeLog                             | 5 +++++
 sysdeps/unix/sysv/linux/alpha/clone.S | 1 +
 2 files changed, 6 insertions(+)

diff --git a/sysdeps/unix/sysv/linux/alpha/clone.S b/sysdeps/unix/sysv/linux/alpha/clone.S
index 550461f..e7ee0af 100644
--- a/sysdeps/unix/sysv/linux/alpha/clone.S
+++ b/sysdeps/unix/sysv/linux/alpha/clone.S
@@ -98,6 +98,7 @@ thread_start:
 	jsr	ra, (pv)
 	ldgp	gp, 0(ra)
 
+	mov     v0, a0
 	ldiq	v0, __NR_exit
 	call_pal PAL_callsys
 
-- 
2.7.4



More information about the Libc-alpha mailing list