1/* SPDX-License-Identifier: GPL-2.0+ */
2/*
3 * Copyright (c) 2004-2008 Texas Instruments
4 *
5 * (C) Copyright 2002
6 * Gary Jennejohn, DENX Software Engineering, <garyj@denx.de>
7 */
8
9OUTPUT_FORMAT("elf32-littlearm", "elf32-littlearm", "elf32-littlearm")
10OUTPUT_ARCH(arm)
11ENTRY(_start)
12SECTIONS
13{
14	. = 0x00000000;
15
16	. = ALIGN(4);
17	__image_copy_start = ADDR(.text);
18	.text :
19	{
20		*(.vectors)
21		CPUDIR/start.o (.text*)
22		*(.text*)
23		*(.glue*)
24	}
25
26	. = ALIGN(4);
27	.rodata : { *(SORT_BY_ALIGNMENT(SORT_BY_NAME(.rodata*))) }
28
29	. = ALIGN(4);
30	.data : {
31		*(.data*)
32	}
33
34	. = ALIGN(4);
35	__u_boot_list : {
36		KEEP(*(SORT(__u_boot_list*)));
37	}
38
39	. = ALIGN(4);
40	.binman_sym_table : {
41		__binman_sym_start = .;
42		KEEP(*(SORT(.binman_sym*)));
43		__binman_sym_end = .;
44	}
45
46	. = ALIGN(4);
47
48	__image_copy_end = .;
49
50	.rel.dyn : {
51		__rel_dyn_start = .;
52		*(.rel*)
53		__rel_dyn_end = .;
54	}
55
56	. = ALIGN(8);
57	_image_binary_end = .;
58	_end = .;
59
60	.bss __rel_dyn_start (OVERLAY) : {
61		__bss_start = .;
62		*(.bss*)
63		 . = ALIGN(8);
64		__bss_end = .;
65	}
66	__bss_size = __bss_end - __bss_start;
67	.dynsym _image_binary_end : { *(.dynsym) }
68	.dynbss : { *(.dynbss) }
69	.dynstr : { *(.dynstr*) }
70	.dynamic : { *(.dynamic*) }
71	.hash : { *(.hash*) }
72	.plt : { *(.plt*) }
73	.interp : { *(.interp*) }
74	.gnu : { *(.gnu*) }
75	.ARM.exidx : { *(.ARM.exidx*) }
76}
77
78#if defined(IMAGE_MAX_SIZE)
79ASSERT(__image_copy_end - __image_copy_start <= (IMAGE_MAX_SIZE), \
80	"SPL image too big");
81#endif
82
83#if defined(CONFIG_SPL_BSS_MAX_SIZE)
84ASSERT(__bss_end - __bss_start <= (CONFIG_SPL_BSS_MAX_SIZE), \
85	"SPL image BSS too big");
86#endif
87
88#if defined(CONFIG_SPL_MAX_FOOTPRINT)
89ASSERT(__bss_end - _start <= (CONFIG_SPL_MAX_FOOTPRINT), \
90	"SPL image plus BSS too big");
91#endif
92