Skip to content

Commit

Permalink
ARM: 7021/1: Check for multiple load addresses before building a uImage
Browse files Browse the repository at this point in the history
uImages need a load address specified. This makes them
incompatible with multiple zreladdrs. Catch this error
before building an uImage so that we do not end up with
broken uImages. The load address can still be specified
with LOADADDR= on the command line.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
  • Loading branch information
Sascha Hauer authored and Russell King committed Oct 17, 2011
1 parent 60aac93 commit cd227fb
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions arch/arm/boot/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,16 @@ endif

$(obj)/uImage: STARTADDR=$(LOADADDR)

check_for_multiple_loadaddr = \
if [ $(words $(LOADADDR)) -gt 1 ]; then \
echo 'multiple load addresses: $(LOADADDR)'; \
echo 'This is incompatible with uImages'; \
echo 'Specify LOADADDR on the commandline to build an uImage'; \
false; \
fi

$(obj)/uImage: $(obj)/zImage FORCE
@$(check_for_multiple_loadaddr)
$(call if_changed,uimage)
@echo ' Image $@ is ready'

Expand Down

0 comments on commit cd227fb

Please sign in to comment.