1 /* ld script to make ARM Linux kernel
2 * taken from the i386 version by Russell King
3 * Written by Martin Mares <mj@atrey.karlin.mff.cuni.cz>
6 #include <asm-generic/vmlinux.lds.h>
7 #include <asm/thread_info.h>
8 #include <asm/memory.h>
16 jiffies = jiffies_64 + 4;
21 #ifdef CONFIG_XIP_KERNEL
22 . = XIP_VIRT_ADDR(CONFIG_XIP_PHYS_ADDR);
24 . = PAGE_OFFSET + TEXT_OFFSET;
26 .init : { /* Init code and data */
31 __proc_info_begin = .;
34 __arch_info_begin = .;
50 __con_initcall_start = .;
52 __con_initcall_end = .;
53 __security_initcall_start = .;
54 *(.security_initcall.init)
55 __security_initcall_end = .;
56 #ifdef CONFIG_BLK_DEV_INITRD
58 __initramfs_start = .;
59 usr/built-in.o(.init.ramfs)
66 #ifndef CONFIG_XIP_KERNEL
67 __init_begin = _stext;
74 /DISCARD/ : { /* Exit code and data */
84 .text : { /* Real text segment */
85 _text = .; /* Text and read-only data */
97 *(.got) /* Global offset table */
102 _etext = .; /* End of text and rodata section */
104 #ifdef CONFIG_XIP_KERNEL
105 __data_loc = ALIGN(4); /* location in binary */
106 . = PAGE_OFFSET + TEXT_OFFSET;
108 . = ALIGN(THREAD_SIZE);
112 .data : AT(__data_loc) {
113 __data_start = .; /* address in memory */
116 * first, the init task union, aligned
117 * to an 8192 byte boundary.
121 #ifdef CONFIG_XIP_KERNEL
136 * then the cacheline aligned data
139 *(.data.cacheline_aligned)
142 * The exception fixup table (might need resorting at runtime)
145 __start___ex_table = .;
149 __stop___ex_table = .;
152 * and the usual data section
159 _edata_loc = __data_loc + SIZEOF(.data);
162 __bss_start = .; /* BSS */
167 /* Stabs debugging sections. */
168 .stab 0 : { *(.stab) }
169 .stabstr 0 : { *(.stabstr) }
170 .stab.excl 0 : { *(.stab.excl) }
171 .stab.exclstr 0 : { *(.stab.exclstr) }
172 .stab.index 0 : { *(.stab.index) }
173 .stab.indexstr 0 : { *(.stab.indexstr) }
174 .comment 0 : { *(.comment) }
178 * These must never be empty
179 * If you have to comment these two assert statements out, your
180 * binutils is too old (for other reasons as well)
182 ASSERT((__proc_info_end - __proc_info_begin), "missing CPU support")
183 ASSERT((__arch_info_end - __arch_info_begin), "no machine record defined")