[U-Boot] uImage load address and entry point with Minnowboard

Simon Glass sjg at chromium.org
Tue Jun 28 16:57:47 CEST 2016


Hi,

On 27 June 2016 at 01:13, vinoth eswaran <evinoth1206 at gmail.com> wrote:
> On Fri, Jun 24, 2016 at 1:57 PM, Wolfgang Denk <wd at denx.de> wrote:
>> Dear Vinoth,
>>
>> In message <CAJst-kFZjA_Nq7K25CEPri9Aq7r=-mmtGyeNYwwg-P2CrN4dbA at mail.gmail.com> you wrote:
>>>
>>> I am using the following command to create uImage. Here in the architecture
>>> argument I am not seeing any option corresponding to the Intel-x86_64. So I
>>> had used x86, which I am not sure is valid or not. The kernel is 64 bit.
>>>
>>> mkimage -A x86 -O linux -T kernel -C none -a 0x100000 -e 0x00000 -n Linux
>>> -d vmlinux-4.4.6-ina uImage
>>> Image Name:   Linux
>>> Created:      Fri Jun 24 10:35:40 2016
>>> Image Type:   Intel x86 Linux Kernel Image (uncompressed)
>>> Data Size:    21966248 Bytes = 21451.41 kB = 20.95 MB
>>> Load Address: 00100000
>>> Entry Point:  00000000
>>
>> This makes no sense to me.  When the kernel image is loaded to RAM
>> starting at address 0x00100000, then ther eis no valid code at address
>> 0x00000000.  So 0x00000000 cannot be a valid entry oint address.  The
>> entry point address must be somewhare in the range between "load
>> address" and "load address + size of uncompressed kernel image".
>
> Dear Mr.Simon Glass,
>
>  Could you please explain how the load address and entry address work
> in x86. I am using the same address as defined in image.its and still
> could run the Linux kernel.
>
> Defined in image.its file:
>         kernel at 1 {
>             description = "Vanilla Linux kernel";
>             data = /incbin/("./vmlinux.bin");
>             type = "kernel";
>             arch = "x86_64";
>             os = "linux";
>             compression = "none";
>             load = <0x01000000>;
>             entry = <0x00000000>;
> }
>
> As pointed out by Mr.Wolfgang it doesn't make sense, as the kernel is
> loaded at the address '0x01000000' and entry is '0x0000000'. Or in
> x86_64 arch these addresses are stored in setup.bin files and loaded
> at run time?

The kernel is loaded to the load address and executed starting from
its load address. The entry address is not used in this case, so it
can be 0. The kernel requires that it be entered from the start
address. The setup.bin information is passed to the kernel for it to
use. It contains configuration info that dates back to the ark, but I
believe it is essential.

>
> Regards,
> Vinothkumar
>
>>> Error: Invalid Boot Flag (found 0x0000, expected 0xaa55)
>>> Setup at 0x000000
>>> Magic signature not found
>>>
>>> Is is I need to load setup.bin also?
>>
>> I have no idea.  I didn't know that you were asking for x86...  I'm
>> not an expert in this area.  I added Simon and Bin to cc: who might be
>> in a much better position to answer such a question.
>>
>>
>> Best regards,
>>
>> Wolfgang Denk
>>

Regards,
Simon


More information about the U-Boot mailing list