From: Chris Packham Date: Wed, 10 Sep 2014 16:03:10 +1200 Subject: [U-Boot] [RFC PATCH v1] powerpc: add --bss-plt to LDFLAGS In-Reply-To: References: Message-ID: <1410321790-12914-1-git-send-email-judge.packham@gmail.com> List-Id: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit To: u-boot@lists.denx.de With some versions of gcc (that we know of 4.6.3 and 4.8.2 are affected) it is necessary to specify --bss-plt to get the final blrl in the _GOT2_TABLE_. Without this the last symbol does not get it's address relocated. For the P2041RDB board this ended up being NetArpWaitTimerStart which caused the ARP packets to timeout immediately. Helped-by: Joakim Tjernlund Signed-off-by: Chris Packham --- Technically this is v2 of http://lists.denx.de/pipermail/u-boot/2014-September/188365.html but the solution is so different that I'm treating it as a new patch series. arch/powerpc/config.mk | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/powerpc/config.mk b/arch/powerpc/config.mk index 6329b6c..fec02f2 100644 --- a/arch/powerpc/config.mk +++ b/arch/powerpc/config.mk @@ -11,6 +11,7 @@ endif CONFIG_STANDALONE_LOAD_ADDR ?= 0x40000 LDFLAGS_FINAL += --gc-sections +LDFLAGS_FINAL += --bss-plt PLATFORM_RELFLAGS += -fpic -mrelocatable -ffunction-sections -fdata-sections \ -meabi PLATFORM_CPPFLAGS += -D__powerpc__ -ffixed-r2 -- 1.7.9.5