C6x: Fix another problem with rela. and rel. sections
Joseph S. Myers
joseph@codesourcery.com
Fri Oct 1 13:47:00 GMT 2010
On Thu, 23 Sep 2010, Bernd Schmidt wrote:
> TI's compiler for C6x produces both rel. and rela. sections. When compiling
> the kernel with it, we end up with rela.init.text and rel.init.text, and when
> we then try to use GNU ld to link these objects together using "-r", the
> linker aborts with
>
> ld: init/mounts.o: relocation size mismatch in init/do_mounts.o section .text
> ld: final link failed: File in wrong format
>
> That's because in the output we've only made one of the two sections. I
> looked around in other targets for ways to fix it, and came across a
> definition of elf_fake_sections in elf32-m32r.c. Adding such a function to
> elf32-tic6x.c seems to fix the problem.
>
> Ok?
This appears to have caused:
FAIL: ld-elf/64ksec-r
regexp "^There are 680.. section headers.*:$"
line "There are 102011 section headers, starting at offset 0x13e594:"
(Testing for cross to c6x-elf from i686-pc-linux-gnu. 2010-09-23 16:00:00
passes, 2010-09-23 17:00:00, this is the only commit in that interval.)
Please fix. When reviewing C6X patches I am presuming that they have been
tested not to cause regressions for a relevant target - did this failure
result from an interaction with another commit between when you tested the
patch and when you committed it?
--
Joseph S. Myers
joseph@codesourcery.com
More information about the Binutils
mailing list