[U-Boot] "arm: keep all sections in ELF file" breaks Arndale
Andre Przywara
andre.przywara at linaro.org
Sat Dec 21 21:57:16 CET 2013
On 12/21/2013 11:46 AM, Albert ARIBAUD wrote:
> Hi Andre,
>
> On Wed, 18 Dec 2013 15:06:04 +0100, Andre Przywara
> <andre.przywara at linaro.org> wrote:
>
>> On 12/17/2013 04:57 PM, Tom Rini wrote:
>>> -----BEGIN PGP SIGNED MESSAGE-----
>>> Hash: SHA1
>>>
>>> On 12/17/2013 10:47 AM, Andre Przywara wrote:
>>>> (CCing Inderpal, Chander and Minkyu)
>>>>
>>>> On 12/17/2013 04:30 PM, Tom Rini wrote:
>>>> On 12/17/2013 10:24 AM, Andre Przywara wrote:
>>>>>>> Hi,
>>>>>>>
>>>>>>> the Arndale board does not work anymore with current master HEAD.
>>>>>>> If I turn on the board, I see exactly nothing.
>>>>>>>
>>>>>>> I bisected it down to:
>>>>>>> 47ed5dd031d7d2c587e6afd386e79ccec1a1b7f7 is the first bad commit
>>>>>>> commit 47ed5dd031d7d2c587e6afd386e79ccec1a1b7f7
>>>>>>> Author: Albert ARIBAUD <albert.u.boot at aribaud.net>
>>>>>>> Date: Thu Nov 7 14:21:46 2013 +0100
>>>>>>>
>>>>>>> arm: keep all sections in ELF file
>>>>>>>
>>>>>>> That patch looks like Chinese to me, does one of you have an idea what's
>>>>>>> wrong here?
>>>>>>> Are we missing a section, maybe for the SPL build?
>>>>
>>>> So on Arndale, what file do you boot exactly? It sounds like not
>>>> u-boot.img but some tool stripping / modifying u-boot (or
>>>> spl/u-boot-spl) and having relied on certain sections being stripped out
>>>> before being run.
>>>>
>>>>> Good point. Indeed I boot u-boot-dtb.bin (the SPL is
>>>>> spl/arndale-spl.bin). So the Makefile does:
>>>>> cat u-boot.bin u-boot.dtb >u-boot-dtb.bin
>>>>
>>>>> I guess the address under which U-boot expects to find the attached dtb
>>>>> changes due to the non-discarding.
>>>>
>>>>> Does any of the Arndale people have an idea how to fix this?
>>>
>>> That's a little confusing as we use objcopy -O binary to make
>>> u-boot.bin/u-boot-spl.bin and that would, I would think, drop these
>>> sections anyhow. But some checking of binary size with the patch in
>>> question locally reverted would help shed some light here.
>>
>> So I did objdump -h on ./u-boot, the diff (sorted by the section name,
>> as the order of the section differed, and the size) is:
>>
>> .ARM.attributes 0000002d
>> -.bss 00048b10
>> +.bss 00048b08
>> .bss_end 00000000
>> .bss_start 00000000
>> .comment 0000001c
>> @@ -14,8 +14,12 @@
>> .debug_loc 00045a4e
>> .debug_ranges 00006f70
>> .debug_str 000123b4
>> +.dynamic 00000080
>> +.dynstr 0000001d
>> +.dynsym 00000060
>> .got.plt 0000000c
>> .hash 0000002c
>> +.interp 00000011
>> .rel.dyn 00006fd8
>> .rodata 0000ae47
>> .text 0002cdf0
>>
>> - works, + is broken.
>> + is HEAD as of yesterday, - is the same with the patch in question
>> reverted. So the patch _adds_ some sections to the file.
>> u-boot-spl is exactly the same, for u-boot-spl.bin the broken version
>> ends earlier (but until then is identical). arndale-spl.bin (which I
>> flash) is different, though.
>> Arndale uses CONFIG_OF_SEPARATE, and .text stays the same AFAICS.
>>
>> I can do some more debugging tomorrow, am grateful for any hints.
>
> Sorry for chiming in late. Did you try this?
>
> http://patchwork.ozlabs.org/patch/300928/
I cannot reach the server. Can you give me a hint what this patch is
about (or a Subject: line to search for on the ML?)
Thanks,
Andre.
More information about the U-Boot
mailing list