Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 17 Feb 2011 19:31:21 +0000 (UTC)
From:      Marcel Moolenaar <marcel@FreeBSD.org>
To:        src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   svn commit: r218780 - head/sys/arm/arm
Message-ID:  <201102171931.p1HJVL6k026798@svn.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: marcel
Date: Thu Feb 17 19:31:21 2011
New Revision: 218780
URL: http://svn.freebsd.org/changeset/base/218780

Log:
  Fix the R_ARM_ABS32 relocation implementation. The memory address
  contains the addend that we need to include.
  
  Obtained from: Juniper Networks.
  Fixed by: Santhanakrishnan Balraj <sbalraj@juniper.net>

Modified:
  head/sys/arm/arm/elf_machdep.c

Modified: head/sys/arm/arm/elf_machdep.c
==============================================================================
--- head/sys/arm/arm/elf_machdep.c	Thu Feb 17 17:35:09 2011	(r218779)
+++ head/sys/arm/arm/elf_machdep.c	Thu Feb 17 19:31:21 2011	(r218780)
@@ -169,9 +169,7 @@ elf_reloc_internal(linker_file_t lf, Elf
 			addr = lookup(lf, symidx, 1);
 			if (addr == 0)
 				return -1;
-			if (*where != addr)
-				*where = addr;
-
+			*where += addr;
 			break;
 
 		case R_ARM_COPY:	/* none */



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