From: Stephen Warren <swarren@nvidia.com>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH v2 3/3] image: Allow images to indicate they're loadable at any address
Date: Mon, 07 Nov 2011 10:09:57 -0700 [thread overview]
Message-ID: <4EB810E5.6040604@nvidia.com> (raw)
In-Reply-To: <4EB80DC7.1050800@nvidia.com>
On 11/07/2011 09:56 AM, Stephen Warren wrote:
> [Resending in an attempt to avoid base64 encoding]
>
> On 11/05/2011 04:20 PM, Wolfgang Denk wrote:
>> Dear Stephen Warren,
>>
>> In message <1320164902-24190-3-git-send-email-swarren@nvidia.com> you wrote:
>>> The legacy uImage format includes an absolute load and entry-
>>> point address. When presented with a uImage in memory that
>>> isn't loaded at the address in the image's load address,
>>> U-Boot will relocate the image to its address in the header.
>>>
>>> Some payloads can actually be loaded and used at any arbitrary
>>> address. An example is an ARM Linux kernel zImage file. This
>>> is useful when sharing a single zImage across multiple boards
>>> with different memory layouts, or U-Boot builds with different
>>> ${load_addr} since sharing a single absolute load address may
>>> not be possible.
>>>
>>> With this config option enabled, an image header may contain a
>>> load address of -1/0xffffffff. This indicates the image can
>>> operate at any load address, and U-Boot will avoid automtically
>>> copying it anywhere. In this case, the entry-point field is
>>> specified relative to the start of the image payload.
>>
>> Please don't invent a new solution. This has been discussed before,
>> and the agreement was to introduce a new image format where the load
>> and entry point addresses are not absolute, but interpreted as offsets
>> relative to the respectice start of system RAM address.
>>
>> Your own IH_TYPE_*_REL patches are queued and will be merged soon.
>
> Oh. I kept pushing and pushing on these and kept meeting resistance. I
> had absolutely no idea at all that there was agreement over those
> patches; the reviews just stopped happening after you refused to look at
> them unless I provided U-Boot size information with every possible
> combination of ifdef locations present/removed.
>
> Anyway, I have withdrawn my support for those patches; please don't
> apply them. In my opinion, this new solution is far superior because:
>
> a) There's no need to revise mkimage to support this new scheme. Hence,
> it can be rolled out with just target-size changes, not host-side tool
> changes (well, a host-side script change is needed, but that's probably
> far easier than rolling out new mkimage binaries)
>
> b) The implementation of this new scheme is far simpler, and less
> invasive to the U-Boot code-base, and hence probably far more maintainable.
>
> c) I've validated that the new scheme handles kernel, initrd, and FDT. I
> never got around to testing a separate FDT image with the old patches
Sorry, and I forgot:
d) This new solution is much more flexible. With IH_TYPE_*_REL, you have
to pick some SDRAM-relative address for the uImage load address that's
valid across all SoCs the image will be used on. This is easy enough for
Tegra20 and Tegra30, but I have no idea what the memory layout is for
U-Boot on OMAP, MSM, Exynos, ... I foresee potential difficulty here.
With the new scheme, all you say is "this image works /anywhere/; don't
copy it." Given the way Linux zImage works, I know
this works fine on all those SoCs, and even if it didn't, the U-Boot
scripts for those SoCs could arrange for the uImage to be loaded to a
SoC-specific address that the zImage /would/ work at.
--
nvpublic
next prev parent reply other threads:[~2011-11-07 17:09 UTC|newest]
Thread overview: 81+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-11-01 16:28 [U-Boot] [PATCH v2 1/3] image: Make image_get_fdt work like image_get_{ram_disk, kernel} Stephen Warren
2011-11-01 16:28 ` [U-Boot] [PATCH v2 2/3] image: Support FDTs already loaded at their load address Stephen Warren
2012-03-06 21:18 ` Wolfgang Denk
2011-11-01 16:28 ` [U-Boot] [PATCH v2 3/3] image: Allow images to indicate they're loadable at any address Stephen Warren
2011-11-05 22:20 ` Wolfgang Denk
2011-11-07 16:56 ` Stephen Warren
2011-11-07 17:09 ` Stephen Warren [this message]
2011-11-07 19:47 ` Simon Glass
2011-11-07 20:29 ` Wolfgang Denk
2011-11-07 21:17 ` Stephen Warren
2011-11-07 22:11 ` Wolfgang Denk
2011-11-07 22:30 ` Stephen Warren
2011-11-07 23:08 ` Wolfgang Denk
2011-11-08 0:00 ` Stephen Warren
2011-11-08 0:27 ` Wolfgang Denk
[not found] ` <74CDBE0F657A3D45AFBB94109FB122FF173F9A5035@HQMAIL01.nvidia.com>
2011-11-07 20:26 ` Wolfgang Denk
2011-11-07 21:04 ` Marek Vasut
2011-11-07 21:38 ` Stephen Warren
2011-11-07 21:59 ` Marek Vasut
2011-11-07 22:08 ` Stephen Warren
2011-11-07 22:27 ` Wolfgang Denk
2011-11-07 22:41 ` Stephen Warren
2011-11-07 23:10 ` Wolfgang Denk
2011-11-07 23:43 ` Stephen Warren
2011-11-07 22:57 ` Nicolas Pitre
2011-11-07 23:25 ` Wolfgang Denk
2011-11-08 0:10 ` Stephen Warren
2011-11-08 0:29 ` Wolfgang Denk
2011-11-08 0:48 ` Nicolas Pitre
2011-11-08 8:38 ` Wolfgang Denk
2011-11-08 11:35 ` Marek Vasut
2011-11-08 11:50 ` Wolfgang Denk
2011-11-08 11:52 ` Marek Vasut
2011-11-08 18:17 ` Stephen Warren
[not found] ` <74CDBE0F657A3D45AFBB94109FB122FF173F9A5424@HQMAIL01.nvidia.com>
2011-11-08 19:44 ` Wolfgang Denk
2011-11-08 21:17 ` Wolfgang Denk
2011-11-08 22:27 ` Stephen Warren
2011-11-08 22:46 ` Wolfgang Denk
2011-11-08 0:35 ` Nicolas Pitre
2011-11-08 1:10 ` Simon Glass
2011-11-08 3:51 ` Nicolas Pitre
2011-11-08 5:37 ` Simon Glass
2011-11-08 8:45 ` Wolfgang Denk
2011-11-08 14:22 ` Loïc Minier
2011-11-08 14:52 ` Jason
2011-11-08 20:18 ` Nicolas Pitre
2011-12-10 22:42 ` Linus Walleij
2011-12-10 22:53 ` Wolfgang Denk
2011-12-10 23:21 ` Linus Walleij
2011-12-12 16:25 ` Stephen Warren
2011-11-08 8:33 ` Wolfgang Denk
2011-11-08 14:26 ` Nicolas Pitre
2011-11-08 15:01 ` Marek Vasut
2011-11-08 15:59 ` Wolfgang Denk
2011-11-08 16:57 ` Detlev Zundel
2011-11-08 20:05 ` Nicolas Pitre
2011-11-07 21:27 ` Stephen Warren
2011-11-07 21:41 ` Nicolas Pitre
2011-11-07 22:42 ` Wolfgang Denk
2011-11-05 18:41 ` [U-Boot] [PATCH v2 1/3] image: Make image_get_fdt work like image_get_{ram_disk, kernel} Marek Vasut
2011-11-05 19:21 ` Simon Glass
2011-11-05 19:39 ` Marek Vasut
2011-11-05 20:38 ` Simon Glass
2011-11-05 20:41 ` Marek Vasut
2011-11-05 20:49 ` Simon Glass
2011-11-05 22:15 ` Wolfgang Denk
2011-11-05 22:18 ` Marek Vasut
2011-11-05 22:06 ` Wolfgang Denk
2011-11-05 21:53 ` Wolfgang Denk
2011-11-05 22:06 ` Marek Vasut
2011-11-05 22:22 ` Wolfgang Denk
2011-11-06 4:52 ` Simon Glass
2011-11-06 8:57 ` Wolfgang Denk
2011-11-05 21:40 ` Wolfgang Denk
2011-11-05 22:06 ` Marek Vasut
2011-11-05 22:24 ` Wolfgang Denk
2011-11-05 22:38 ` Marek Vasut
2011-11-08 14:24 ` Loïc Minier
2011-11-08 16:06 ` Wolfgang Denk
2011-11-08 18:15 ` Stephen Warren
[not found] ` <74CDBE0F657A3D45AFBB94109FB122FF173F9A5415@HQMAIL01.nvidia.com>
2011-11-08 19:33 ` Wolfgang Denk
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4EB810E5.6040604@nvidia.com \
--to=swarren@nvidia.com \
--cc=u-boot@lists.denx.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox