]> git.ipfire.org Git - people/ms/u-boot.git/commitdiff
arc: make sure _start is in the beginning of .text section
authorAlexey Brodkin <abrodkin@synopsys.com>
Fri, 10 Apr 2015 15:41:58 +0000 (18:41 +0300)
committerAlexey Brodkin <abrodkin@synopsys.com>
Fri, 10 Apr 2015 15:45:34 +0000 (18:45 +0300)
This is important to have entry point in the beginning of .text section
because it allows simple loading and execution of U-Boot.

For example pre-bootloader loads U-Boot in memory starting from offset
0x81000000 and then just jumps to the same address.

Otherwise pre-bootloader would need to find-out where entry-point is. In
its turn if it deals with binary image of U-Boot there's no way for
pre-bootloader to get required value.

Signed-off-by: Alexey Brodkin <abrodkin@synopsys.com>
arch/arc/cpu/u-boot.lds
arch/arc/lib/Makefile

index ccddbf7dc9b754997b9ae7abc81d8d3b7351a5d6..693df74061f5c1203f18668a832fb7464abce999 100644 (file)
@@ -13,6 +13,7 @@ SECTIONS
        .text : {
                *(.__text_start)
                *(.__image_copy_start)
+               arch/arc/lib/start.o (.text*)
                *(.text*)
        }
 
index b88790492d2a2805819905a667430a5d807bcc7d..459bba9f6601149998ef3149c59d3c6d453c75aa 100644 (file)
@@ -4,6 +4,7 @@
 # SPDX-License-Identifier:     GPL-2.0+
 #
 
+head-y := start.o
 obj-y += cache.o
 obj-y += cpu.o
 obj-y += interrupts.o
@@ -18,7 +19,6 @@ obj-y += memcpy-700.o
 obj-y += memset.o
 obj-y += reset.o
 obj-y += timer.o
-obj-y += start.o
 obj-y += ints_low.o
 obj-y += init_helpers.o