diff --git a/arch/arm/src/Makefile b/arch/arm/src/Makefile index 44c4174093..098b69ed1a 100644 --- a/arch/arm/src/Makefile +++ b/arch/arm/src/Makefile @@ -82,7 +82,12 @@ board/libboard$(LIBEXT): nuttx: $(HEAD_AOBJ) board/libboard$(LIBEXT) @echo "LD: nuttx" @$(LD) --entry=__start $(LDFLAGS) $(LDPATHES) -L$(BOARDDIR) -o $(TOPDIR)/$@ $(HEAD_AOBJ) \ - --start-group $(LDLIBS) -lboard --end-group $(EXTRA_LIBS) $(LIBGCC) + --start-group $(LDLIBS) -lboard --end-group $(EXTRA_LIBS) $(LIBGCC) +ifeq ($(CONFIG_BOOT_FROM_FLASH),y) + @export flashloc=`$(OBJDUMP) --all-headers $(TOPDIR)/$@ | grep _eronly | cut -d' ' -f1`; \ + $(OBJCOPY) --adjust-section-vma=.data=0x$$flashloc $(TOPDIR)/$@ $(TOPDIR)/$@.flashimage + @mv $(TOPDIR)/$@.flashimage $(TOPDIR)/$@ +endif @$(NM) $(TOPDIR)/$@ | \ grep -v '\(compiled\)\|\(\$(OBJEXT)$$\)\|\( [aUw] \)\|\(\.\.ng$$\)\|\(LASH[RL]DI\)' | \ sort > $(TOPDIR)/System.map diff --git a/arch/arm/src/lpc214x/lpc214x_head.S b/arch/arm/src/lpc214x/lpc214x_head.S index 15939a3ad1..b3c2a9ee69 100644 --- a/arch/arm/src/lpc214x/lpc214x_head.S +++ b/arch/arm/src/lpc214x/lpc214x_head.S @@ -415,7 +415,7 @@ __start: /* Configure VPBDIV */ configvpbdiv r0, r1 - + /* Configure the PLL */ configpll r0, r1, r2, r3 @@ -471,12 +471,9 @@ __start: mov fp, #0 bl up_earlyserialinit -#ifdef CONFIG_DEBUG - mov r0, #'C' - bl up_putc - mov r0, #'\n' - bl up_putc -#endif + showprogress 'C' + showprogress '\n' + /* Initialize onboard LEDs */ #ifdef CONFIG_ARCH_LEDS