Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 23 Mar 2012 17:54:06 +0000 (UTC)
From:      Oleksandr Tymoshenko <gonzo@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r233378 - head/libexec/rtld-elf/mips
Message-ID:  <201203231754.q2NHs6Zh087295@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: gonzo
Date: Fri Mar 23 17:54:06 2012
New Revision: 233378
URL: http://svn.freebsd.org/changeset/base/233378

Log:
  Before jumping to application's entry point set ra == pc in order
      to let backtracing routine know to go no further.

Modified:
  head/libexec/rtld-elf/mips/rtld_start.S

Modified: head/libexec/rtld-elf/mips/rtld_start.S
==============================================================================
--- head/libexec/rtld-elf/mips/rtld_start.S	Fri Mar 23 17:24:52 2012	(r233377)
+++ head/libexec/rtld-elf/mips/rtld_start.S	Fri Mar 23 17:54:06 2012	(r233378)
@@ -80,7 +80,8 @@ LEAF(rtld_start)
 	move	a0, s0			/* stack pointer */
 	move	t9, v0
 	PTR_SUBU sp, 4*SZREG		/* ABI requires to reserve memory for 4 regs */
-	jr	t9			/* _start(sp, cleanup, obj); */
+	move	ra,t9			/* RA == PC signals backtrace routine to stop */
+	j	t9			/* _start(sp, cleanup, obj); */
 	move	a3, s3			/* restore ps_strings */
 END(rtld_start)
 



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201203231754.q2NHs6Zh087295>