ARM: uncompress.c: copy executable to SDRAM if necessary
We used to relocate the executable to the current address. This does
not work when the executable runs from a readonly location like for
example NOR Flash. Test if we run from inside the available memory and
if we do, relocate to the current address as before. Otherwise copy
the executable to the start of memory and relocate to that address.
While at it add some comments to the code.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
1 parent 3ce85ca commit 352ddc86aeabef5aee5d7a78a433dbeb9c1c509f
@Sascha Hauer Sascha Hauer authored on 12 Jun 2014
Showing 2 changed files
View
arch/arm/cpu/setupc.S
View
arch/arm/cpu/uncompress.c