[U-Boot] mkimage and XIP vs entry point

Mike Frysinger vapier at gentoo.org
Tue Jan 19 01:55:55 CET 2010


the current mkimage requires XIP images to have their entry point set to the 
load address + 64 bytes.  my question is simply, why ?  why cant the entry 
point be an arbitrary location ?  i cant seem to find any technical reason for 
this restriction.

the Blackfin kernel has long been using an entry point way in the middle of 
the text.  as an example, the typical output of our last release:
$ bfin-uclinux-mkimage -l /tftpboot/uImage
Image Name:   Linux-2.6.28.10-ADI-2009R1.1-svn
Created:      Fri Jan 15 17:45:22 2010
Image Type:   Blackfin Linux Kernel Image (gzip compressed)
Data Size:    6370016 Bytes = 6220.72 kB = 6.07 MB
Load Address: 00001000
Entry Point:  002f3938

this is because we store most of head.S (like __start) in the .init.text 
section.  this code is never going to be returned to, so putting it in .text 
or even the very start of .text is pointless.  when we added ROM kernel 
support, this no longer worked -- mkimage demands that the entry point be 
located right after the load address / uimage header.

so what am i missing ?  or should i submit a patch to delete this check from 
the mkimage tool and let the entry point be arbitrary like non-xip ?
-mike
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 836 bytes
Desc: This is a digitally signed message part.
Url : http://lists.denx.de/pipermail/u-boot/attachments/20100118/462640fd/attachment.pgp 


More information about the U-Boot mailing list