3 #include "globalconfig.h"
6 _boot_sys_start = 0x300000;
7 _kernel_image = FIASCO_IMAGE_VIRT_START; /* kernel link address */
8 _load = FIASCO_IMAGE_PHYS_START & 0x1fffff;
10 _load = 0x1000; /* skip page 0 to preserve BIOS data and
11 * page 1 to reserve space for the KIP */
13 /*_fiasco_image_offset = 0xf0000000;*/
14 _fiasco_image_offset = FIASCO_IMAGE_PHYS_OFFSET;
16 OUTPUT_FORMAT("elf64-x86-64")
17 OUTPUT_ARCH(i386:x86-64)
18 ENTRY(bootstrap__boot_start)
33 . = FIASCO_MP_TRAMP_PAGE;
40 .text_boot : ALIGN(0x1000) {
42 *(.bootstrap.text .bootstrap.text.* .bootstrap.gnu.linkonce.t.*)
45 *(.bootstrap.rodata .bootstrap.rodata.* .bootstrap.gnu.linkonce.r.*)
46 *(.bootstrap.data .bootstrap.data.* .bootstrap.gnu.linkonce.d.*)
53 *(.bootstrap.bss .bootstrap.gnu.linkonce.b.*)
55 PROVIDE(_boot_sys_end = .);
58 . = _kernel_image + _load;
60 .kip : AT(ADDR(.kip) - _fiasco_image_offset) {
61 _kernel_image_start = .;
64 KEEP(*(.initkip.version))
65 KEEP(*(.initkip.features))
66 KEEP(*(.initkip.features.fini))
71 .koptions : AT (ADDR(.koptions) - _fiasco_image_offset) {
75 #ifdef CONFIG_ALLOW_RO_TEXT
78 .text : AT (ADDR(.text) - _fiasco_image_offset) {
79 PROVIDE ( _kernel_text_start = . );
82 *(.text SORT(.text.*) .gnu.linkonce.t.*)
87 *(.rodata .rodata.* .gnu.linkonce.r.*)
90 PROVIDE (_log_table = .);
92 * The section must start with ".debug" because else the linker
93 * complains about references to discarded sections
95 KEEP(*(SORT(.debug.jdb.log_table)))
96 PROVIDE (_log_table_end = .);
100 PROVIDE (_etext = .);
101 } : ktext = 0x90909090
103 #ifdef CONFIG_ALLOW_RO_TEXT
108 .data : AT (ADDR(.data) - _fiasco_image_offset) {
109 PROVIDE (_kernel_data_start = .);
110 *(.data .data.* .gnu.linkonce.d.*)
113 /* Constructor and destructor lists, ordered by priority. The lists
114 are traversed from end to start, therefore the *_END__ symbols
115 precede the *_LIST__ symbols. */
117 __PER_CPU_CTORS_END__ = .;
118 KEEP (*(.ctors.00010))
119 KEEP (*(.ctors.00009))
120 KEEP (*(.ctors.00008))
121 KEEP (*(.ctors.00007))
122 KEEP (*(.ctors.00006))
123 KEEP (*(.ctors.00005))
124 KEEP (*(.ctors.00004))
125 KEEP (*(.ctors.00003))
126 KEEP (*(.ctors.00002))
127 KEEP (*(.ctors.00001))
128 __PER_CPU_CTORS_LIST__ = .;
130 __PER_CPU_LATE_CTORS_END__ = .;
131 KEEP (*(.ctors.00020))
132 KEEP (*(.ctors.00019))
133 KEEP (*(.ctors.00018))
134 KEEP (*(.ctors.00017))
135 KEEP (*(.ctors.00016))
136 KEEP (*(.ctors.00015))
137 KEEP (*(.ctors.00014))
138 KEEP (*(.ctors.00013))
139 KEEP (*(.ctors.00012))
140 KEEP (*(.ctors.00011))
141 __PER_CPU_LATE_CTORS_LIST__ = .;
146 KEEP (*(SORT (.ctors.*)))
150 KEEP (*(SORT (.dtors.*)))
154 PROVIDE (_edata = .);
158 .per_cpu_data : AT (ADDR(.per_cpu_data) - _fiasco_image_offset) {
159 PROVIDE (_per_cpu_data_start = .);
162 PROVIDE (_per_cpu_data_end = .);
166 .bss : AT (ADDR(.bss) - _fiasco_image_offset) {
167 PROVIDE (_bss_start = .);
168 *(.bss .bss.* .gnu.linkonce.b.* COMMON)
169 PROVIDE (_bss_end = .);
175 PROVIDE (_initcall_start = .);
176 .initcall.text : AT (ADDR(.initcall.text) - _fiasco_image_offset) {
179 } : kitext = 0x90909090
181 .initcall.data : AT (ADDR(.initcall.data) - _fiasco_image_offset) {
184 PROVIDE (_initcall_end = .);